I'm running the development branch with default configuration (except GDAX API key) and a couple bucks for testing, however gekko doesn't seem to actually buy any ETH. It logs the attempted buy but eventually says the order wasn't filled, cancels it, and doesn't attempt to buy again. If I view GDAX in a browser, I don't see the order in my fills.
It doesn't seem to have any problems selling, but buying is problematic. I understand why after a minute it doesn't necessarily create a new buy order, as the price has probably changed, but the initial buy just never happens.
2017-03-15 13:02:32 (INFO): Attempting to BUY 0.07866869444150902 ETH at GDAX
*CHOP*
2017-03-15 13:03:33 (INFO): BUY order was not (fully) filled, cancelling and creating new order
Anyone else seeing issues like this?
Edit: nodejs v7.7.2, commit 7988cce
Strange.. Will have a look asap! After #611 I'll go over all bugs regarding exchange integrations.
The problem probably is post_only: true try disabling it.
it probably makes sense to default to false, while adding support i noticed the problem too, if you debug the error message the order has the status "rejected" while mentioning post_only.
@askmike feel free to mention me for gdax related problems so i'm aware of them.
Ah just noticed the default (if you remove post_only from the config) it actually defaults to false.
I also mentioned the reject problem at #564
If its NOT post_only what are you using ETH/USD or ETH/BTC (i only tested BTC/USD on sandbox and ETH/BTC on production)
I'm using the ETH/USD pair, tried adding post_only: true to my config.trader. (Wasn't in the default config file.) The bot's off and running, I'll chime back in with a trip report once it tries to buy something.
Edit: no good, it did the same thing as my OP, it said it was attempting to buy but it never actually happened.
I am having the same issue using ETH/BTC. However, it attempts to buy repeatedly.
@brian000 @boxofdeath post_only should false. If the problem still occur please tell me.
I will test the trader tonight with sandbox mode.
Gave it a crack with post_only: false and it still doesn't buy. It tries, gives up, then keeps trying a couple more times, just like my initial report.
my post_only is false as well. Still doing the same thing. Has no problem selling.
Has no problem selling.
ah! sorry i thought both selling and buying did not work.
Nope now selling isn't working! I think it might have to do with the amount it is trying to buy or sell. I tried doing the exact trade in GDAX and it told me the amount was too precise. Possibly its a rounding issue?
@boxofdeath I've seen that issue too, GDAX doesn't seem to like any more than six decimal places.
@brian000 is that confirmed (I can't find any GDAX documentation on decimal limits)? If so, should we just modify this?
https://github.com/askmike/gekko/blob/stable/exchanges/gdax.js#L65
From:
amount: parseFloat(account.available);
To:
amount: parseFloat(account.available).toFixed(6);
I am getting the same error in almost all buying orders. I am on feature/ui-trader branch.
After debugging the response from GDAX, these not (fully) filled orders all have open state. Gekko treats them as failed and cancels them.
BUY order was not (fully) filled, cancelling and creating new order
I tried stopping the bot before it cancels the order and waited for some time. The order appeared on my GDAX account.
ORDER LIFECYCLE
The HTTP Request will respond when an order is either rejected (insufficient funds, invalid parameters, etc) or received (accepted by the matching engine). A 200 response indicates that the order was received and is active. Active orders may execute immediately (depending on price and market conditions) either partially or fully. A partial execution will put the remaining size of the order in the open state. An order that is filled completely, will go into the done state.
https://docs.gdax.com/#place-a-new-order
After some time running the trader, I started getting such errors. @developdaly it seems this is the case. I'm not sure where is the best place to fix this though.
I have tried changing Trader.prototype.getPortfolio and now running the trader again. I also changed both buy and sell in gdax.js
var buyParams = {
'price': price.toFixed(6),
'size': amount,
'product_id': this.pair,
'post_only': this.post_only
};
2017-07-17 09:29:58 (ERROR): Error buying at GDAX: price too precise (0.02063999)
2017-07-17 09:30:03 (DEBUG): Requested LTC/BTC trade data from GDAX ...
2017-07-17 09:30:04 (DEBUG): Processing 2 new trades. From 2017-07-17 07:30:02 UTC to 2017-07-17 07:30:02 UTC. (a few seconds)
2017-07-17 09:30:04 (DEBUG): calculated DEMA properties for candle:
2017-07-17 09:30:04 (DEBUG): long ema: 0.02069643
2017-07-17 09:30:04 (DEBUG): short ema: 0.02066635
2017-07-17 09:30:04 (DEBUG): diff: -0.14541
2017-07-17 09:30:04 (DEBUG): DEMA age: 561 candles
2017-07-17 09:30:04 (DEBUG): we are currently in a downtrend @ 0.02063000 (-0.14541)
2017-07-17 09:30:06 (ERROR): Error buying at GDAX: price too precise (0.02072999)
2017-07-17 09:30:06 (DEBUG): GDAX returned an error, retrying..
2017-07-17 09:30:08 (DEBUG): GDAX returned an error, retrying..
2017-07-17 09:30:08 (ERROR): Error buying at GDAX: price too precise (0.02063999)
2017-07-17 09:30:16 (DEBUG): GDAX returned an error, retrying..
2017-07-17 09:30:16 (ERROR): Error buying at GDAX: price too precise (0.02072999)