-
-
Notifications
You must be signed in to change notification settings - Fork 7.6k
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
bleutrade, anxpro and southxchange withdraw() with Python 2.7 ccxt 1.9.175 #344
Comments
Here's the error from using withdraw() instead:
Sorry for the omission! |
While we're at it... anxpro also has a similar issue. It's output is: So perhaps it should be changed to look like this on line 1620 of exchanges?:
Am I assuming correctly? |
FYI, I tried changing my exchanges.py for anxpro as described above and it is working as I intended. Would love to get the change up to GitHub if acceptable to you. |
Got another one for you...
Results in:
I haven't been able to figure that one out... the withdrawal still executes, but doesn't return data. |
Hi, @PhinixPhire ! Thx for opening this issue! I see, you're making good progress in understanding the inner workings of the library. That's very helpful!
Yes, I guess, a message is better than nothing... Though, I would better leave id untouched (undefined), if there's no txid. The message is still there in the info nearby.
We welcome your pull requests! )
Yes, and if it works, then it's a perfect candidate for including into your PR.
That's very strange of them to return empty responses, but, I guess, we will have to add a special case for withdraw and some other methods... This error is handled in the fetch method from base class. I'll take a deeper look into it today and will fix it, hopefully. |
I added your fixes to Bleutrade and ANXpro, now moving on to SouthXchange... |
Is it a better practice to leave a return as None than to populate a default response? |
@PhinixPhire yes, because it indicates a "no response" explicitly to the user so that he can decide on what to do with it. Many users will be confused as they expect an id there, and they will treat the message as being an id, thus, all ids will be the same (not unique) → that can lead to very difficult unexpected errors elsewhere. So, I think it's always better to catch None instead of a default. |
Cool. I will be happy to work within that paradigm then. I'm sure I can patch a workaround for my local scripts. |
Here's what I did, in case it's helpful to future readers... this way the script at least carries something through to describe what may have happened with the withdrawal when reviewing the ledger (I log trxid to a database for historical reference)
The withdrawal does still complete. I've done several tests. |
The southxchange error should be gone as of 1.9.210+! Thx for reporting! |
It looks like the withdraw method for bleutrade is calling an unsupported dictionary key (uuid). Am I understanding correctly that it's mostly mirroring bittrex with a few exceptions?
When I directly run this code:
I get this result:
{u'message': u'Your withdraw has been successfully scheduled.', u'result': [], u'success': u'true'}
It looks like bleutrade doesn't provide a transaction id? So I think we should change 'uuid' to, perhaps, 'message'? Then we at least get something back when executing a withdrawal and no error.
I would try the pull request stuff... except I'm not certain this is a desired change for everyone. Let me know your thoughts, Thanks!
The text was updated successfully, but these errors were encountered: