Describe the bug
websvc raise an Exeption when try to open a Binance Market
To Reproduce
Steps to reproduce the behavior:
Launch websvc.py
On the browser, Click on 'Binance'
Then click on one market (exemple : EGLDUSDT)
Browser return "Internal server error" and console raise the Exception :
[2022-02-13 11:40:04,274] ERROR in app: Exception on /binance/EGLDUSDT [GET] Traceback (most recent call last): File "/home/antoine/Dev/pycryptobot/venv/lib/python3.8/site-packages/flask/app.py", line 2073, in wsgi_app response = self.full_dispatch_request() File "/home/antoine/Dev/pycryptobot/venv/lib/python3.8/site-packages/flask/app.py", line 1518, in full_dispatch_request rv = self.handle_user_exception(e) File "/home/antoine/Dev/pycryptobot/venv/lib/python3.8/site-packages/flask/app.py", line 1516, in full_dispatch_request rv = self.dispatch_request() File "/home/antoine/Dev/pycryptobot/venv/lib/python3.8/site-packages/flask/app.py", line 1502, in dispatch_request return self.ensure_sync(self.view_functions[rule.endpoint])(**req.view_args) File "/home/antoine/Dev/pycryptobot/websvc/app/__init__.py", line 32, in binance_market return Pages.technical_analysis('binance', market, '15m', '1h', '6h') File "/home/antoine/Dev/pycryptobot/websvc/app/pages/pages.py", line 298, in technical_analysis ta = TechnicalAnalysis(api.getHistoricalData(market, g1, None)) File "/home/antoine/Dev/pycryptobot/models/exchange/binance/api.py", line 971, in getHistoricalData {"symbol": market, "interval": granularity.to_short, "limit": 300}, AttributeError: 'str' object has no attribute 'to_short'
Expected behavior
Should return the web page
Desktop (please complete the following information):
Describe the bug websvc raise an Exeption when try to open a Binance Market
To Reproduce Steps to reproduce the behavior:
[2022-02-13 11:40:04,274] ERROR in app: Exception on /binance/EGLDUSDT [GET] Traceback (most recent call last): File "/home/antoine/Dev/pycryptobot/venv/lib/python3.8/site-packages/flask/app.py", line 2073, in wsgi_app response = self.full_dispatch_request() File "/home/antoine/Dev/pycryptobot/venv/lib/python3.8/site-packages/flask/app.py", line 1518, in full_dispatch_request rv = self.handle_user_exception(e) File "/home/antoine/Dev/pycryptobot/venv/lib/python3.8/site-packages/flask/app.py", line 1516, in full_dispatch_request rv = self.dispatch_request() File "/home/antoine/Dev/pycryptobot/venv/lib/python3.8/site-packages/flask/app.py", line 1502, in dispatch_request return self.ensure_sync(self.view_functions[rule.endpoint])(**req.view_args) File "/home/antoine/Dev/pycryptobot/websvc/app/__init__.py", line 32, in binance_market return Pages.technical_analysis('binance', market, '15m', '1h', '6h') File "/home/antoine/Dev/pycryptobot/websvc/app/pages/pages.py", line 298, in technical_analysis ta = TechnicalAnalysis(api.getHistoricalData(market, g1, None)) File "/home/antoine/Dev/pycryptobot/models/exchange/binance/api.py", line 971, in getHistoricalData {"symbol": market, "interval": granularity.to_short, "limit": 300}, AttributeError: 'str' object has no attribute 'to_short'
Expected behavior Should return the web page
Desktop (please complete the following information):