url_list = ['{}&pageNum={}'.format(base_url, str(page)) for page in range(1,
    num_pages + 1)]
with open('results.txt', 'wb') as acct:
    for url_ in url_list:
        print('Processing {}...'.format(url_))
r_new = rq.get(url_)
soup_new = bsoup(r_new.text)
for tr in soup_new.find_all('tr', align='center'):
    stack = []
for td in tr.findAll('td'):
    stack.append(td.text.replace('\n', '').replace('\t', '').strip())
acct.write(', '.join(stack) + '\n')
Очистите несколько страниц с помощью BeautifulSoup и Python