I'm having some difficulty in scraping data from a table derived from an applied filter. I have tried using "holder_url" but no luck. I also tried "burn_url" while applying the security id of the webpage but to avail. Any help will be greatly appreciated. Thanks in advance!
from parsel import Selector
import re
burnAmt = []
headers = {"User-Agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.94 Safari/537.36"}
holder_url = f"https://bscscan.com/token/{token1}?a=0x000000000000000000000000000000000000dead"
home_url = f"https://bscscan.com/address/{token1}"
sid_resp = requests.get(home_url, headers=headers)
security_id = re.findall("sid = '(.+?)'", sid_resp.text)[0]
burn_url = f"https://bscscan.com/token/generic-tokentxns2?m=normal&contractAddress={token1}&a=0x000000000000000000000000000000000000dead&sid={security_id}&p=1"
response = requests.get(burn_url, headers=headers)
sel = Selector(response.text)
for row in sel.css('tr'):
burnAmount = row.xpath('td[8]/text()').get()
burnAmt.append(burnAmount)
totBurnAmt = sum(burnAmt)
print(totBurnAmt)