Hey I need to search for variable data in a console from a page source
The data will be shown like this:
"data":[13,17]
It will vary a lot with the amount of units inside the table. I have tried out several RE expressions, but the closest I have come to a result, is with a fixed amount of units.
self.driver.get("website.com")
apidata = self.driver.page_source
print(apidata)
datasetbasic = re.search('"data":[[0-99,0-99]+', apidata)
print(datasetbasic)
Instead of having it as a fixed amount, how do I capture anything that is inside the data table?
Before you ask, I cannot use xpath or any other selenium calls to capture this data directly from the webpage (I think), because the element is from a graph, where the data is only visible in the actual console.
Any help is appreciated