def data_from_techshop_ws ( tws_url ) : r = requests . get ( tws_url ) if r . status_code == 200 : data = BeautifulSoup ( r . text , "lxml" ) else : data = "There was an error while accessing data on techshop.ws." return data
python function to return values from a website
Scrapes data from techshop . ws .
def data_from_techshop_ws(tws_url):
    """Scrapes data from techshop.ws."""

    r = requests.get(tws_url)
    if r.status_code == 200:
        data = BeautifulSoup(r.text, "lxml")
    else:
        data = "There was an error while accessing data on techshop.ws."

    return data