Awesome-Python-Scripts
Awesome-Python-Scripts copied to clipboard
Bug in Amazon-price-tracker
trafficstars
Hi,
I found a bug in Amazon-price-tracker script, which crashes the process if the given product is not available or out of stock.
The original error is
Traceback (most recent call last):
File "price_tracker.py", line 120, in <module>
print("The price of the product is expressed in " + (currency_used(URL)))
File "price_tracker.py", line 46, in currency_used
price = price_element.get_text()
AttributeError: 'NoneType' object has no attribute 'get_text'