rafaelwdornelas / Foxbit_Bot

Bot Automatic Trader Foxbit - Buy & Sell.
72 stars 56 forks source link

Parou de Vender, só Compra #3

Closed astfarias closed 7 years ago

astfarias commented 7 years ago

Ontem estava funcionando normalmente. Hoje cedo tentei executar Compras a

[9:57:00] Bests Order Book: Buy: 3063 BRL | Sell: 3074.43 BRL
{ btcbuyamount: '0.001',
  btcbuypriceamountmin: '0',
  btcbuypriceamountmax: '3020' }
POST Buy
[9:57:02] Bests Order Book: Buy: 3063 BRL | Sell: 3074.43 BRL
(node:7008) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): TypeError: amount.toFixed is not a function
(node:7008) DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
[9:57:04] Bests Order Book: Buy: 3063 BRL | Sell: 3074.43 BRL
[9:57:06] Foxbit Balance: 31.24 BRL | 0.325159 BTC

E vendas a

[9:57:54] Bests Order Book: Buy: 3063 BRL | Sell: 3074.43 BRL
{ btcsellamount: '0.002',
  btcsellpriceamountmin: '3060',
  btcsellpriceamountmax: '3139' }
POST Sell
[9:57:56] Bests Order Book: Buy: 3063 BRL | Sell: 3074.43 BRL

Neste momento o Book está assim: screenshot-127 0 0 1 3000-2017-02-10-10-01-22

Porem o Bot não envia nenhuma ordem de SELL msm com o preço atual maior que o definido no limite mínimo. Então eu gerei novas chaves de API no Foxbit e testei. Mesmo resultado. Então excluí os arquivos do bot e instalei novamente. Mesmo resultado.

Acredito que eu configurei corretamente as ordens e ontem estava rolando normal. Criar SELL manualmente na Foxbit funciona. Vocês também tiveram esse problema? Obrigado

astfarias commented 7 years ago

Consegui fazer funcionar da seguinte forma:

Para comprar basta ativar o BUY normalmente Para vender, é necessário dar STOP no BUY e só então ativar o SELL Para vender e comprar, STOP em tudo, ativar o SELL primeiro e depois o BUY.

Fiz vários testes e só assim rodou o SELL e BUY. Estranhamente ontem não notei esse problema ou não existia...