Skip to content
This repository has been archived by the owner on Feb 16, 2020. It is now read-only.

Support for Binance Exchange, including Import #1356

Merged
merged 4 commits into from
Nov 22, 2017
Merged

Support for Binance Exchange, including Import #1356

merged 4 commits into from
Nov 22, 2017

Conversation

cmroche
Copy link
Contributor

@cmroche cmroche commented Nov 22, 2017

  • What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)

Feature

  • What is the new behavior (if this is a feature change)?

Added exchange and import support for binance.com, updated documentation.

  • Other information:

I've been able to test and validate importing and paper trading on a number of coins, and populated some of the more popular coins. They support a lot, so I'll look to a more painless way of entering other ones in the future, or leave it to the community to add the ones that they use.

Live trading is not yet tested, but will happen in the next few weeks as I setup my strategy for this exchange.

@askmike
Copy link
Owner

askmike commented Nov 22, 2017

You are on fire!

'QTUM',
'ZEC',
],
markets: [
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI: this is fine, but I am okay with skipping prettier (using // prettier-ignore) in these kind of config blocks.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Noted, I didn't realize that prettier did this to me :)

@askmike askmike merged commit 47309c9 into askmike:develop Nov 22, 2017
@cmroche cmroche deleted the binance branch November 22, 2017 22:00
@StevenHop
Copy link

I gave Binance a testrun. Saw an error on line 181. Replaced

_first

with

_.first

and i could continue until the following error :-)

This is the complete line in the original \exchanges\binance.js file
181 var result = _first(data, function(ticker) {

I have no clue where to put it or update it in the github so i leave it up to you..

FTR: papertrade and importers works. Tradebot not (yet). Thanks.

@cmroche
Copy link
Contributor Author

cmroche commented Nov 27, 2017

@StevenHop Thanks, I'll make a fix tonight.

@ms121
Copy link

ms121 commented Dec 2, 2017

Hey, @cmroche just want to thank you for the awesome import and backtesting addition! I know you are yet to finish the live trade part (or test it anyway). Currently, it is unable to see the balance amount that is "free" within the exchange.
I have added the relevant section of the Debug log file below;

balances:
[ { asset: 'BTC', free: '0.00397164', locked: '0.00000000' },
{ asset: 'POWR', free: '40.93600000', locked: '0.00000000' },
2017-12-02 04:49:19 (ERROR): Binance did not return portfolio for POWR, assuming 0.
2017-12-02 04:49:19 (ERROR): Binance did not return portfolio for BTC, assuming 0.

kind regards,

@cmroche
Copy link
Contributor Author

cmroche commented Dec 2, 2017

@ms121 Thanks for the information, lodash always surprises me in the way some of its functions work, in this case _.first(...) was not the correct operation and so it was mangling the results. Replaced it with a _.find, I have not tested in live again but if you grab PR #1401 it should then work, please confirm.

This was referenced Dec 5, 2017
@clownfish44
Copy link

Hello @cmroche when will this be done do you think?

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

Successfully merging this pull request may close these issues.

5 participants