-
Notifications
You must be signed in to change notification settings - Fork 260
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
Binance api connection problem #92
Comments
Interesting, I'm assuming that we make an invalid assumption when Binance gives their first If you go to the file at and paste this code over the def init_exchange(self):
try:
symbols = self.calls.get_exchange_info()["symbols"]
except binance.exceptions.BinanceAPIException as e:
print(e)
raise exceptions.APIException("Invalid API Key, IP, or permissions for action - are you trying "
"to use your normal exchange keys while in sandbox mode? "
"\nTry toggling the \'use_sandbox\' setting in your settings.json or check "
"if the keys were input correctly into your keys.json.") it will allow us to see what the binance package itself is saying about your keys. It is interesting that it works inside the binance client package but not in the blankly framework. We had someone who had a very similar error who fixed it by reinstalling the package: #41 (comment) |
Thanks for the fast reply! The script continued a litlle bit further, but then it failed again. I am trying out the backtesting so, I thought that it shouldn't be a big deal if I am not in the sanbox environment (correct me if I'm wrong), so I set the "use_sandbox" to false
This also works without your fix, so as a conclusion we can say that I had my settings.json messed up... Maybe not relevant for the thread anymore, but now the script is failing a little bit further:
|
Awesome I didn't notice the binance TLD setting and forgot to ask. I think the invalid symbol error is because binance uses |
Just added a suggestion to check the |
Changing the USD to USDT fixed it indeed. |
Hello,
The following error pops up when I try to test one of the examples with the Binance interface:
INFO: No portfolio name to load specified, defaulting to the first in the file: (Pompom). This is fine if there is only one portfolio in use. Invalid API Key, IP, or permissions for action - are you trying to use your normal exchange keys while in sandbox mode? Try toggling the 'use_sandbox' setting in your settings.json or check if the keys were input correctly into your keys.json.
Any idea what it could be?
My api keys appear to be correct, because I get my account information using the following code (python-binance package):
If I look at the trace, it is on the self.calls.get_account() call, where the code breaks.
My settings file is as follows:
Thanks in advance!
The text was updated successfully, but these errors were encountered: