Author Topic: btsbots wallet release v0.0.1  (Read 93634 times)

0 Members and 1 Guest are viewing this topic.

Offline fluxer555

  • Hero Member
  • *****
  • Posts: 749
    • View Profile
I'm currently getting a 502 Bad Gateway error from https://btsbots.com/sockjs/info

EDIT: Actually, the whole website is serving that error right now.
EDIT2: Everybody's back up now. Downtime of about 5 minutes.
« Last Edit: May 10, 2017, 10:25:55 pm by fluxer555 »

Offline 8ejM

  • Newbie
  • *
  • Posts: 12
    • View Profile
got it, I will provide all these native data, and give the choice to users.

A guess you mean the ticker feed on top of the poloniex api page (https://poloniex.com/support/api/). And you take the "last" trade value, right? What about
Code: [Select]
("lowestAsk" + "highestBid")/2 . This could get a little better prices.
Great, thanks a lot!
 +5%

Offline alt

  • Hero Member
  • *****
  • Posts: 2821
    • View Profile
  • BitShares: baozi
seems the price change much after you halt your computer.
but bots can't update your order when your browser is not acitve, because all code is running in the client side.
so when you open btsbots.com again, the bots update the old orders.

Also the bot seems to refer to the price of the last session under some circumstances:

Code: [Select]
run bots
new order OPEN.DASH BTS  amount: 7.500000000000001 price: 2628.9024795702967
new order OPEN.DASH USD  amount: 7.499999999999999 price: 124.16536069244391
run bots
cancel order --- OPEN.DASH BTS
because of price: 2628.9024786666664 change to 1985.2493480088676 ----
new order OPEN.DASH BTS  amount: 7.5 price: 1985.2493480088676
cancel order ---- OPEN.DASH USD
because of price: 124.1653601655538 change to 93.76506100000002 -----
new order OPEN.DASH USD  amount: 7.5 price: 93.76506100000002

See the price drop from 2629 to 1985 and 124 to 94 just after starting the bot. Bad thing is, orders were given before correction occurs. Nothing happend this time but this could result in huge losses.

Debug info:
Computer was turned off after last session, restarted and reconnected after about 12h, ip should also be a new one.

Hi Alt,

no, I know,  so I normally cancel all orders from my wallet after stopping all bots and closing the connection (I reckon closing the tab also closes the active websocket connection). So there were no old orders.
The log I was providing is the log of a just freshly started bot (after complete shutdown of the computer and 12h). The bot gave these orders just after start up and canceled them just after that, when he got a new price. But presumable the old price was saved from the former session and used until new price feeds went in and corrected the situation. Just guessing.

But I can assure you that there were no open orders from the last session when I started the bot. I know from my own experience that users sometimes are confident that a setup was like this or that and rule out any user error. But I'm 100% confident there were no old orders simply because there were no 15 DASH on that account in the last session.

Thanks for looking into this.
thanks for the detail.
I never thought about this condition.
I will add  some logic to make sure all data is fresh before run the bot.

Offline alt

  • Hero Member
  • *****
  • Posts: 2821
    • View Profile
  • BitShares: baozi

these is the logic, if the client can't get the newest block  in time, it will pause the bot,

Hi alt,

thank you for your work, I think one can't overestimate the value the rise in liquidity brought to bitshares by your software.
I see that it's pretty work-in-progress. And want to make a few wishes, if I may:

* An oversight of all available markets with informations about the used price feed.
I was trading DASH the other day, low liquidity there still, and was a bit worried about the price feed quality. Sometimes the prices changed but my bots didn't react. Other bots seemed not to follow the same feed, and some actions observed with others bots didn't seem to make sense. Maybe everything is alright, but I'm lacking these informations about the price feed to throw real money at such a market.

PS: I saw you writing, that Dash price feed is the poloniex data.

* Safeguard against bad or broken connections:
The main reason I halted trading for now is that I assume my connection to be poor. I don't know if I get all feeds on time and sometimes the websocket connection is lost which leaves open orders unattended. It would be nice if the client would be able to recognize delayed data (maybe a timestamp in the feed data) and missed data (if that can be the possible in websocket, maybe a index number in the feed data). Any of these events, plus the worst case a broken websocket connection, could set the client in emergency mode, making him desperately try to reconnect and cancel all orders immediately.

Does "pause the bot" mean that he will cancel all open orders? That would be awesome.
no, 'pause the bot' means the bot will stop running and do nothing.
usually client can't cancel the orders too when it lost connect to the server.

Offline alt

  • Hero Member
  • *****
  • Posts: 2821
    • View Profile
  • BitShares: baozi
got it, I will provide all these native data, and give the choice to users.

yes, for OPEN.DASH, simple  use last ticker data from poloniex.
I  have no idea, why it change such more.
PS: The price feed is simple last trade ticker data, right? I'm asking, because I see 8% changes up and down:

Code: [Select]
cancel order --- OPEN.DASH USD
because of price: 99.10707803964283 change to 107.90515943227852 ----
new order OPEN.DASH USD  amount: 7.142857142857142 price: 107.90515943227852
cancel order --- OPEN.DASH OPEN.BTC
because of price: 0.06632999839798 change to 0.07240041489940716 ----

The price goes down a few seconds again.

Maybe it would be better than to exclude mini trades from the feed, so that only trades >$100 are taken into account.

A guess you mean the ticker feed on top of the poloniex api page (https://poloniex.com/support/api/). And you take the "last" trade value, right? What about
Code: [Select]
("lowestAsk" + "highestBid")/2 . This could get a little better prices.

Offline 8ejM

  • Newbie
  • *
  • Posts: 12
    • View Profile
yes, for OPEN.DASH, simple  use last ticker data from poloniex.
I  have no idea, why it change such more.
PS: The price feed is simple last trade ticker data, right? I'm asking, because I see 8% changes up and down:

Code: [Select]
cancel order --- OPEN.DASH USD
because of price: 99.10707803964283 change to 107.90515943227852 ----
new order OPEN.DASH USD  amount: 7.142857142857142 price: 107.90515943227852
cancel order --- OPEN.DASH OPEN.BTC
because of price: 0.06632999839798 change to 0.07240041489940716 ----

The price goes down a few seconds again.

Maybe it would be better than to exclude mini trades from the feed, so that only trades >$100 are taken into account.

A guess you mean the ticker feed on top of the poloniex api page (https://poloniex.com/support/api/). And you take the "last" trade value, right? What about
Code: [Select]
("lowestAsk" + "highestBid")/2 . This could get a little better prices.

Offline 8ejM

  • Newbie
  • *
  • Posts: 12
    • View Profile
these is the logic, if the client can't get the newest block  in time, it will pause the bot,

Hi alt,

thank you for your work, I think one can't overestimate the value the rise in liquidity brought to bitshares by your software.
I see that it's pretty work-in-progress. And want to make a few wishes, if I may:

* An oversight of all available markets with informations about the used price feed.
I was trading DASH the other day, low liquidity there still, and was a bit worried about the price feed quality. Sometimes the prices changed but my bots didn't react. Other bots seemed not to follow the same feed, and some actions observed with others bots didn't seem to make sense. Maybe everything is alright, but I'm lacking these informations about the price feed to throw real money at such a market.

PS: I saw you writing, that Dash price feed is the poloniex data.

* Safeguard against bad or broken connections:
The main reason I halted trading for now is that I assume my connection to be poor. I don't know if I get all feeds on time and sometimes the websocket connection is lost which leaves open orders unattended. It would be nice if the client would be able to recognize delayed data (maybe a timestamp in the feed data) and missed data (if that can be the possible in websocket, maybe a index number in the feed data). Any of these events, plus the worst case a broken websocket connection, could set the client in emergency mode, making him desperately try to reconnect and cancel all orders immediately.

Does "pause the bot" mean that he will cancel all open orders? That would be awesome.

Offline 8ejM

  • Newbie
  • *
  • Posts: 12
    • View Profile
seems the price change much after you halt your computer.
but bots can't update your order when your browser is not acitve, because all code is running in the client side.
so when you open btsbots.com again, the bots update the old orders.

Also the bot seems to refer to the price of the last session under some circumstances:

Code: [Select]
run bots
new order OPEN.DASH BTS  amount: 7.500000000000001 price: 2628.9024795702967
new order OPEN.DASH USD  amount: 7.499999999999999 price: 124.16536069244391
run bots
cancel order --- OPEN.DASH BTS
because of price: 2628.9024786666664 change to 1985.2493480088676 ----
new order OPEN.DASH BTS  amount: 7.5 price: 1985.2493480088676
cancel order ---- OPEN.DASH USD
because of price: 124.1653601655538 change to 93.76506100000002 -----
new order OPEN.DASH USD  amount: 7.5 price: 93.76506100000002

See the price drop from 2629 to 1985 and 124 to 94 just after starting the bot. Bad thing is, orders were given before correction occurs. Nothing happend this time but this could result in huge losses.

Debug info:
Computer was turned off after last session, restarted and reconnected after about 12h, ip should also be a new one.

Hi Alt,

no, I know,  so I normally cancel all orders from my wallet after stopping all bots and closing the connection (I reckon closing the tab also closes the active websocket connection). So there were no old orders.
The log I was providing is the log of a just freshly started bot (after complete shutdown of the computer and 12h). The bot gave these orders just after start up and canceled them just after that, when he got a new price. But presumable the old price was saved from the former session and used until new price feeds went in and corrected the situation. Just guessing.

But I can assure you that there were no open orders from the last session when I started the bot. I know from my own experience that users sometimes are confident that a setup was like this or that and rule out any user error. But I'm 100% confident there were no old orders simply because there were no 15 DASH on that account in the last session.

Thanks for looking into this.
« Last Edit: May 09, 2017, 02:07:42 pm by 8ejM »

Offline alt

  • Hero Member
  • *****
  • Posts: 2821
    • View Profile
  • BitShares: baozi
yes, for OPEN.DASH, simple  use last ticker data from poloniex.
I  have no idea, why it change such more.
PS: The price feed is simple last trade ticker data, right? I'm asking, because I see 8% changes up and down:

Code: [Select]
cancel order --- OPEN.DASH USD
because of price: 99.10707803964283 change to 107.90515943227852 ----
new order OPEN.DASH USD  amount: 7.142857142857142 price: 107.90515943227852
cancel order --- OPEN.DASH OPEN.BTC
because of price: 0.06632999839798 change to 0.07240041489940716 ----

The price goes down a few seconds again.

Maybe it would be better than to exclude mini trades from the feed, so that only trades >$100 are taken into account.

Offline alt

  • Hero Member
  • *****
  • Posts: 2821
    • View Profile
  • BitShares: baozi
these is the logic, if the client can't get the newest block  in time, it will pause the bot,

Hi alt,

thank you for your work, I think one can't overestimate the value the rise in liquidity brought to bitshares by your software.
I see that it's pretty work-in-progress. And want to make a few wishes, if I may:

* An oversight of all available markets with informations about the used price feed.
I was trading DASH the other day, low liquidity there still, and was a bit worried about the price feed quality. Sometimes the prices changed but my bots didn't react. Other bots seemed not to follow the same feed, and some actions observed with others bots didn't seem to make sense. Maybe everything is alright, but I'm lacking these informations about the price feed to throw real money at such a market.

PS: I saw you writing, that Dash price feed is the poloniex data.

* Safeguard against bad or broken connections:
The main reason I halted trading for now is that I assume my connection to be poor. I don't know if I get all feeds on time and sometimes the websocket connection is lost which leaves open orders unattended. It would be nice if the client would be able to recognize delayed data (maybe a timestamp in the feed data) and missed data (if that can be the possible in websocket, maybe a index number in the feed data). Any of these events, plus the worst case a broken websocket connection, could set the client in emergency mode, making him desperately try to reconnect and cancel all orders immediately.

Offline alt

  • Hero Member
  • *****
  • Posts: 2821
    • View Profile
  • BitShares: baozi
have you resolve the problem?
I have no idea about these output.

Something wrong with btsbots? I'm unable to get the bot running today, and I've got the following errors in the console:
unreachable code after return statement[Learn More]  ef1f8ace46776681012bcd9fdcbacba5f253ce2c.js:21:27050
unreachable code after return statement[Learn More]  ef1f8ace46776681012bcd9fdcbacba5f253ce2c.js:30:6977
unreachable code after return statement[Learn More]  ef1f8ace46776681012bcd9fdcbacba5f253ce2c.js:35:5851

Side note - the android application seems to freeze/stutter when I use the chat, specifically when my keyboard is opened to type with.

Thanks :)  +5%

Offline alt

  • Hero Member
  • *****
  • Posts: 2821
    • View Profile
  • BitShares: baozi
seems the price change much after you halt your computer.
but bots can't update your order when your browser is not acitve, because all code is running in the client side.
so when you open btsbots.com again, the bots update the old orders.

Also the bot seems to refer to the price of the last session under some circumstances:

Code: [Select]
run bots
new order OPEN.DASH BTS  amount: 7.500000000000001 price: 2628.9024795702967
new order OPEN.DASH USD  amount: 7.499999999999999 price: 124.16536069244391
run bots
cancel order --- OPEN.DASH BTS
because of price: 2628.9024786666664 change to 1985.2493480088676 ----
new order OPEN.DASH BTS  amount: 7.5 price: 1985.2493480088676
cancel order ---- OPEN.DASH USD
because of price: 124.1653601655538 change to 93.76506100000002 -----
new order OPEN.DASH USD  amount: 7.5 price: 93.76506100000002

See the price drop from 2629 to 1985 and 124 to 94 just after starting the bot. Bad thing is, orders were given before correction occurs. Nothing happend this time but this could result in huge losses.

Debug info:
Computer was turned off after last session, restarted and reconnected after about 12h, ip should also be a new one.

Offline 8ejM

  • Newbie
  • *
  • Posts: 12
    • View Profile
Also the bot seems to refer to the price of the last session under some circumstances:

Code: [Select]
run bots
new order OPEN.DASH BTS  amount: 7.500000000000001 price: 2628.9024795702967
new order OPEN.DASH USD  amount: 7.499999999999999 price: 124.16536069244391
run bots
cancel order --- OPEN.DASH BTS
because of price: 2628.9024786666664 change to 1985.2493480088676 ----
new order OPEN.DASH BTS  amount: 7.5 price: 1985.2493480088676
cancel order ---- OPEN.DASH USD
because of price: 124.1653601655538 change to 93.76506100000002 -----
new order OPEN.DASH USD  amount: 7.5 price: 93.76506100000002

See the price drop from 2629 to 1985 and 124 to 94 just after starting the bot. Bad thing is, orders were given before correction occurs. Nothing happend this time but this could result in huge losses.

Debug info:
Computer was turned off after last session, restarted and reconnected after about 12h, ip should also be a new one.

Offline R

  • Hero Member
  • *****
  • Posts: 1004
    • View Profile
Something wrong with btsbots? I'm unable to get the bot running today, and I've got the following errors in the console:
unreachable code after return statement[Learn More]  ef1f8ace46776681012bcd9fdcbacba5f253ce2c.js:21:27050
unreachable code after return statement[Learn More]  ef1f8ace46776681012bcd9fdcbacba5f253ce2c.js:30:6977
unreachable code after return statement[Learn More]  ef1f8ace46776681012bcd9fdcbacba5f253ce2c.js:35:5851

Side note - the android application seems to freeze/stutter when I use the chat, specifically when my keyboard is opened to type with.

Thanks :)  +5%

Offline 8ejM

  • Newbie
  • *
  • Posts: 12
    • View Profile
PS: The price feed is simple last trade ticker data, right? I'm asking, because I see 8% changes up and down:

Code: [Select]
cancel order --- OPEN.DASH USD
because of price: 99.10707803964283 change to 107.90515943227852 ----
new order OPEN.DASH USD  amount: 7.142857142857142 price: 107.90515943227852
cancel order --- OPEN.DASH OPEN.BTC
because of price: 0.06632999839798 change to 0.07240041489940716 ----

The price goes down a few seconds again.

Maybe it would be better than to exclude mini trades from the feed, so that only trades >$100 are taken into account.
« Last Edit: May 08, 2017, 02:30:04 pm by 8ejM »