How to use b4 - 2 common examples

To help you get started, we’ve selected a few b4 examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github buckyroberts / Source-Code-from-Tutorials / Python / 26_python.py View on Github external
def trade_spider(max_pages):
  page = 1
  while page <= max_pages:
    url = 'https://buckysroom.org/trade/search.php?page=' + str(page)
    source_code = requests.get(url)
    plain_text = source_code.text
    soup = BeautifulSoup(plain_text)
    for link in soup.findAll('a', {'class': 'item-name'}):
        href = "https://buckysroom.org" + link.get('href')
        title = link.string
        print(href)
        print(title)
    page += 1
github buckyroberts / Source-Code-from-Tutorials / Python / 27_python.py View on Github external
def get_single_item_data(item_url):
    source_code = requests.get(item_url)
    plain_text = source_code.text
    soup = BeautifulSoup(plain_text)
    for item_name in soup.findAll('div', {'class': 'i-name'}):
        print(item_name.string)
    for link in soup.findAll('a'):
        href = "https://buckysroom.org" + link.get('href')
        print(href)

b4

A tool to work with public-inbox and patch archives

GPL-2.0
Latest version published 2 months ago

Package Health Score

73 / 100
Full package analysis

Popular b4 functions

Similar packages