You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The code simply uses float() to do type cast, without handling the corner cases where values
greater than 3 digits uses comma as separator.
Traceback (most recent call last):
File "./launcher.py", line 53, in
main(parse_args())
File "./launcher.py", line 48, in main
app.run()
File "/home/tcheng/Repositories/spice/spice/watcher.py", line 31, in run
self.check_stock_prices()
File "/home/tcheng/Repositories/spice/spice/watcher.py", line 56, in check_stock_prices
print(ita.get_quote("GOOG"))
File "/home/tcheng/Repositories/spice/venv/lib/python3.6/site-packages/InvestopediaApi/ita.py", line 261, in get_quote
return float(quote)
ValueError: could not convert string to float: '1,029.27'
The text was updated successfully, but these errors were encountered:
ita.get_quote("GOOG")
The code simply uses float() to do type cast, without handling the corner cases where values
greater than 3 digits uses comma as separator.
Traceback (most recent call last):
File "./launcher.py", line 53, in
main(parse_args())
File "./launcher.py", line 48, in main
app.run()
File "/home/tcheng/Repositories/spice/spice/watcher.py", line 31, in run
self.check_stock_prices()
File "/home/tcheng/Repositories/spice/spice/watcher.py", line 56, in check_stock_prices
print(ita.get_quote("GOOG"))
File "/home/tcheng/Repositories/spice/venv/lib/python3.6/site-packages/InvestopediaApi/ita.py", line 261, in get_quote
return float(quote)
ValueError: could not convert string to float: '1,029.27'
The text was updated successfully, but these errors were encountered: