Hi, first apologies I got upset but it was I have been using zenbot for 1 week and made me keep losing money (I lost 0.15 ether thanks to this)
Launch latest zenbot (unstable branch) with following parameters:
$ ./zenbot.sh trade gdax.eth-USD --trend_ema 21 --period 1m --max_slippage 0.001 --poll_trades 6000 --order_poll_time 3000 --order_adjust_time 4000 --oversold_rsi_periods=1000 --oversold_rsi=1000 --neutral_rate=0.065 --max_sell_loss_pct=0.85 --max_buy_loss_pct=5 --buy_pct=100 --sell_pct=100 --selector gdax.eth-usd --rsi_periods 1100 --profit_stop_enable_pct 1 --profit_stop_percent 0.5 --markup_sell_pct 0.02 --markdown_buy_pct 0.02 --verbose --reset-profit
buy_pct and sell_pct to 99a. zenbot live log will show 'buying' state. It will keep remain showing 'buying' state for several periods.
b. Eventually zenbot live log will show the message 'order completed' and 'bought/sold'; however the next period we see that both asset and currency balances remained untouched. Moreover, if I go to gdax interface I see that in fact no sell/buy was completed.
c. Using manual buy/sell commands ('b', 's', 'B', 'S' key presses during live log) also does not reliably work. It will work some times and others the same situation described in previous statements a. and b. will happen (i.e. 'buying'...'buying'...'bought' or 'selling'... 'selling'.... 'sold' but truth when we look balances is both asset/currency remained unchanged.
Zenbot is unusable until this is fixed. You get high risk
a. I enabled --debug flag and I see messages being cancelled with message '183.23 vs our marked price 183.41' . I commented out the code which triggers 'cancelOrder(...)' function but still buying.. sell.. flow is not reliable.
Can someone who knows this code well please add an extra step that checks that ending balances after 'bought' or 'sold' did not remain unchanged, and if they remain unchanged then the buy/sell flow is triggered again? Repeat this until we are sure the buy/sell was truly done. I think this is the simplest solution for now
a. When trading eth-USD in gdax:

b. When trading ltc-USD in gdax same happens:

First keep calm, with capslocking every word i am sure no one will be willing to investigate on that issue.
For any investigation there are some basic information needed, like:
Which version do you use (stable/unstable, which commit)
Which exchange are you trading on?
The pair is seen on screenshot (but no idea how you could lose eth if trading on ltc/usd). Recently there was a bug on poloniex fixed, which sounds like that (#1455) but w/o knowing anything about your setup, we can only guess.
Hi thanks everyone for the response I have attached more information above. I am willing to lose at most 50 dollars more if this assures the code is completing sell/purchases reliably and not randomly report them as sold/bought but when in reality no sell/buy did finish successfully
As you are running on gdax, can you please check if you have this commit https://github.com/DeviaVir/zenbot/pull/1482 ? Looks like your issue if you ask me.
edit: your edited issue is now (on my opinion) a clear and wellformed issue report, thanks for that
Hi Shawn, thanks a lot for your reply. Yes, it certainly looks like the issue I am reporting. Ok i will test it and run it with 50 dollars not to loose lot if it doesnt work.
I will report here if this fixes this issue so this bug can be closed. I am bit sad (i was angry before and i apologize a lot) for losing money because of this bug but I understand this is a work in progress, and foremost, I am grateful that smart and nice developers work on this.
Yes, that commit seems to have fixed the bug. I see one sell/one buy that succeeded. I need more time to fully confirm this commit fixed the issue but seems that the commit https://github.com/DeviaVir/zenbot/pull/1482 fixes the issue; but please give more time as I have just started to run test live with real money.
I restarted zenbot, it has two trades one sell/one buy and both succeeded. Yes it seems that it was the bug mentioned in https://github.com/DeviaVir/zenbot/pull/1482. By far, this was not a small bug but a big one to say (in the end we want bot to follow strategy, not to randomly succeed or fail on our strategy, right?).. I mean, the bug was randomly reporting done for sales/purchases when it truly didnt succeed, which in fact equals to be randomly selling or buying. In the end, this was consistently leading to lose money. Anyways, I am turning the page about the money I lost.
I will leave it running overnight and report if this was truly the fix. It seems that yes that commit (https://github.com/DeviaVir/zenbot/pull/148) is the fix but I will keep running zenbot live overnight and look if this fix really solved this bad bug. Thanks a lot guys for the help.
As reported in previous update, I left zenbot running overnight. It performed 5 trades and all succeeded. So yes https://github.com/DeviaVir/zenbot/pull/1482 seems to be the fix.
I will leave the bot running the full day today and I guess I will attempt reopen this ticket (or open a new one if tickets cannot be opened again) if i see some weir behavior but for now, after that commit (https://github.com/DeviaVir/zenbot/pull/1482) zenbot seems to be working very reliably with gdax.
For now, I think this ticket can be closed.
Thanks a lot guys!
Hello abelardojarab,
good news.
can you send me your command syntax ?
./zenbot.sh ... ?
Regards
Mario
See the original issue? Its lthere, ready for c&p....
When I experimented with this I removed a flag in engine.js and set a flag at the beginning of the strategy to s.signal = bought
Then on strategy signaling you hafto set a parameter to if (s.signal === bought && yourcalculation === yoursignal ) { s.signal = sell }
However, this depends if the strategy has this implemented. It would be of great help if I could see what strategy you are using sir. Thank you.
@juanzolo i dont see where this is related to this issue?
@abelardojarab if the issue is now fixed for you, please consider closing.
Most helpful comment
Hi Shawn, thanks a lot for your reply. Yes, it certainly looks like the issue I am reporting. Ok i will test it and run it with 50 dollars not to loose lot if it doesnt work.
I will report here if this fixes this issue so this bug can be closed. I am bit sad (i was angry before and i apologize a lot) for losing money because of this bug but I understand this is a work in progress, and foremost, I am grateful that smart and nice developers work on this.
Update: March 3rd, 2018 @ 1:04pm PST (Pacific Standard Time)
Yes, that commit seems to have fixed the bug. I see one sell/one buy that succeeded. I need more time to fully confirm this commit fixed the issue but seems that the commit https://github.com/DeviaVir/zenbot/pull/1482 fixes the issue; but please give more time as I have just started to run test live with real money.
Update: March 12th, 2018 @ 3:05pm PST (Pacific Standard Time)
I restarted zenbot, it has two trades one sell/one buy and both succeeded. Yes it seems that it was the bug mentioned in https://github.com/DeviaVir/zenbot/pull/1482. By far, this was not a small bug but a big one to say (in the end we want bot to follow strategy, not to randomly succeed or fail on our strategy, right?).. I mean, the bug was randomly reporting done for sales/purchases when it truly didnt succeed, which in fact equals to be randomly selling or buying. In the end, this was consistently leading to lose money. Anyways, I am turning the page about the money I lost.
I will leave it running overnight and report if this was truly the fix. It seems that yes that commit (https://github.com/DeviaVir/zenbot/pull/148) is the fix but I will keep running zenbot live overnight and look if this fix really solved this bad bug. Thanks a lot guys for the help.
Update: March 13th, 2108 @ 7:54am PST (Pacific Standard Time)
As reported in previous update, I left zenbot running overnight. It performed 5 trades and all succeeded. So yes https://github.com/DeviaVir/zenbot/pull/1482 seems to be the fix.
I will leave the bot running the full day today and I guess I will attempt reopen this ticket (or open a new one if tickets cannot be opened again) if i see some weir behavior but for now, after that commit (https://github.com/DeviaVir/zenbot/pull/1482) zenbot seems to be working very reliably with gdax.
For now, I think this ticket can be closed.
Thanks a lot guys!