Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error when trying to import from binance_chain.environment import BinanceEnvironment #18

Open
ledzgio opened this issue Jun 21, 2019 · 3 comments

Comments

@ledzgio
Copy link

ledzgio commented Jun 21, 2019

After installing the library on my environment with Python 3.5.3, I try to import the library as follows (in Python shell):

from binance_chain.environment import BinanceEnvironment

But I get this error:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/vagrant/.local/lib/python3.5/site-packages/binance_chain/environment.py", line 45
    return hash(f"{self.api_url}{self.wss_url}{self.hrp}")
                                                        ^
SyntaxError: invalid syntax

Any idea why?

UPDATE: it is apparently due to f'' string not supported on python 3.5.3, can you confirm this? could you please add support for python 3.5 as well?

UPDATE2: trying it with Python 3.7 but there is an error during the package installation due to libsecp256k1 library. Then I tried to install the package here (as suggested in the readme) https://github.com/ludbb/secp256k1-py#installation but this is not compatible with python 3.7!

I am currently still not able to use the library.

@ScriptProdigy
Copy link

Hey @ledzgio ,

I had similar issues with secp256k. Had to install the lib properly first.

sudo apt-get install lib32ncurses5-dev
sudo add-apt-repository ppa:tah83/secp256k1
sudo apt update
sudo apt install libsecp256k1-dev

try this before pip install python-binance-chain

@ledzgio
Copy link
Author

ledzgio commented Jun 24, 2019

Hey @ledzgio ,

I had similar issues with secp256k. Had to install the lib properly first.

sudo apt-get install lib32ncurses5-dev
sudo add-apt-repository ppa:tah83/secp256k1
sudo apt update
sudo apt install libsecp256k1-dev

try this before pip install python-binance-chain

It worked, thank you

@ledzgio
Copy link
Author

ledzgio commented Jun 25, 2019

@sammchardy is there any chance we get this library compatible with Python 3.5?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants