ImportError: cannot import name '_endpoint_from_view_func' from 'flask.helpers'
See original GitHub issueCheck this or we will delete your issue. (fill in the checkbox with an X like so: [x])
- I have searched for other issues with the same problem or similar feature requests.
Select one:
- [ X] Bug
- Feature Request
- Technical Help
- Other
Environment
- Are you using the module on a VPS or other Cloud hosting?
- Are you using the module on a Raspberry Pi?
What kind of internet connection do you have?
Cable
Include here a description of your internet access like cable, lte and up and download rate.
Whatever COX cable provides the highest bandwidth for residential access
Average system load (CPU)
%55
Include here the ammount of cpu cores and the average system load.
4
Hardware specification
Include here a description of the server hardware.
3.2 GHz 6-Core Intel Core i7 64 GB 2667 MHz DDR4
Operating System? (include version)
- [ X] macOS Catalina 10.15.7
- Windows
- Linux (include flavour)
Options
- stream_buffer
- process_stream_data
Which endpoint do you connect?
Include here the endpint you are connecting to, like binance.com, binance.com-isolated_margin or binance.org-testnet
binance-us
Python Version Requirement
- [ X] I am using Python 3.6.1 or above
Exact Python Version?
Include here the response of 'python --version' AND 'python3 --version'
(venv3) > $ python --version
Python 3.8.2
(venv3) > $ python3 --version
Python 3.8.2
Pip Version?
Include here the response of 'python3 -m pip --version' or 'pip3 --version'
pip 21.1.1 from /Users/matlihan/venv3/lib/python3.8/site-packages/pip (python 3.8)
Dependencies
Run pip list > pip_list.txt
and upload the file.
Package Version
aniso8601 9.0.1 certifi 2020.12.5 chardet 4.0.0 cheroot 8.5.2 click 8.0.0 coach 1.0.0 colorama 0.4.4 Flask 2.0.0 Flask-RESTful 0.3.8 idna 2.10 itsdangerous 2.0.0 jaraco.functools 3.3.0 Jinja2 3.0.0 MarkupSafe 2.0.0 more-itertools 8.7.0 numpy 1.20.1 pathlib 1.0.1 pip 21.1.1 poloniex 0.0.17 poloniexapi 0.5.7 psutil 5.8.0 pytz 2021.1 pyzmq 22.0.3 requests 2.25.1 setuptools 54.1.2 six 1.15.0 ujson 4.0.2 unicorn-binance-websocket-api 1.30.0 unicorn-fy 0.11.0 urllib3 1.26.4 websocket-client 0.58.0 websockets 8.1 Werkzeug 2.0.0
UNICORN Binance WebSocket API Version?
Latest
Did you upgrade to the latest release version with `pip install unicorn-binance-websocket-api --upgrade`?
Yes
Please control what version you are using with this script and post the output: https://github.com/oliver-zehentleitner/unicorn-binance-websocket-api/blob/master/tools/get_used_module_version.py
Description of your issue
Attempted to run binance-us example posted here which results in an import error stated below.
https://github.com/oliver-zehentleitner/unicorn-binance-websocket-api/blob/master/example_binance_us.py
Include the contents of the log file here. (REMOVE API_KEY, API_SECRET, LISTEN_KEY!!)
/Users/matlihan/venv3/bin/python /Users/matlihan/dev/c/tabox/trunk/apps/lua/modules/broker/Binance.py Traceback (most recent call last): File “/Users/matlihan/dev/c/tabox/trunk/apps/lua/modules/broker/Binance.py”, line 36, in <module> from unicorn_binance_websocket_api.unicorn_binance_websocket_api_manager import BinanceWebSocketApiManager File “/Users/matlihan/venv3/lib/python3.8/site-packages/unicorn_binance_websocket_api/init.py”, line 3, in <module> from unicorn_binance_websocket_api.unicorn_binance_websocket_api_manager import BinanceWebSocketApiManager File “/Users/matlihan/venv3/lib/python3.8/site-packages/unicorn_binance_websocket_api/unicorn_binance_websocket_api_manager.py”, line 40, in <module> from .unicorn_binance_websocket_api_restserver import BinanceWebSocketApiRestServer File “/Users/matlihan/venv3/lib/python3.8/site-packages/unicorn_binance_websocket_api/unicorn_binance_websocket_api_restserver.py”, line 36, in <module> from flask_restful import Resource File “/Users/matlihan/venv3/lib/python3.8/site-packages/flask_restful/init.py”, line 14, in <module> from flask.helpers import _endpoint_from_view_func ImportError: cannot import name ‘_endpoint_from_view_func’ from ‘flask.helpers’ (/Users/matlihan/venv3/lib/python3.8/site-packages/flask/helpers.py)
Process finished with exit code 1
Issue Analytics
- State:
- Created 2 years ago
- Comments:8 (2 by maintainers)
Downgrading flask solved the problem for me: pip install flask==1.1.2
It seems to be solved in upstream: https://github.com/flask-restful/flask-restful/pull/913
Does everything work again as it should?