Coder Social home page Coder Social logo

Comments (26)

whittlem avatar whittlem commented on June 8, 2024 2

I need to go through verification with Binance again. I stopped using Binance after it said I need to go through verification again. I need to sort this out to be able to troubleshoot this.

from pycryptobot.

whittlem avatar whittlem commented on June 8, 2024 2

Maybe i found the problem: doing some debug i see in line 191 it try to set variable quote_min by index name MIN_NOTIONAL but dataframe doesn't have that index, instead it return this:

0 PRICE_FILTER 1 LOT_SIZE 2 ICEBERG_PARTS 3 MARKET_LOT_SIZE 4 TRAILING_DELTA 5 PERCENT_PRICE_BY_SIDE 6 NOTIONAL 7 MAX_NUM_ORDERS 8 MAX_NUM_ALGO_ORDERS

df[df["filterType"] == "MIN_NOTIONAL"][["minNotional"]].values[0][0]

You are right about this... I was able to re-create this with a script.

import sys

sys.path.insert(0, ".")

from controllers.PyCryptoBot import PyCryptoBot  # noqa: E402
from models.TradingAccount import TradingAccount  # noqa: E402
from models.AppState import AppState  # noqa: E402
from models.exchange.binance import AuthAPI as BAuthAPI, PublicAPI as BPublicAPI  # noqa: E402

app = PyCryptoBot(exchange="binance")
account = TradingAccount(app)
state = AppState(app, account)
state.minimum_order_quote()

And returns this:

Traceback (most recent call last):
  File "<removed>/pycryptobot/examples/script-binance_v2.py", line 13, in <module>
    state.minimum_order_quote()
  File "<removed>/pycryptobot/./models/AppState.py", line 191, in minimum_order_quote
    df[df["filterType"] == "MIN_NOTIONAL"][["minNotional"]].values[0][0]
IndexError: index 0 is out of bounds for axis 0 with size 0

Although I'm not getting an error running the bot I can see the error above. I'll fix this and hopefully it fixed it for all of you. Thanks, this helped a lot.

from pycryptobot.

whittlem avatar whittlem commented on June 8, 2024 2

8.0.7 is available now. Docker image is building now. The issue should be fixed.

from pycryptobot.

thiazzz avatar thiazzz commented on June 8, 2024

I have the same. Did you already find a solution?

from pycryptobot.

MirekF avatar MirekF commented on June 8, 2024

from pycryptobot.

leohrs avatar leohrs commented on June 8, 2024

So far no solution, at least here. It seems that all config is fine, might be something with binance API handling maybe?

from pycryptobot.

leohrs avatar leohrs commented on June 8, 2024

update: same config works fine in kucoin

from pycryptobot.

FenarkSEC avatar FenarkSEC commented on June 8, 2024

I am having the same issue as well, using the Helm chart on a Kubernetes cluster.

from pycryptobot.

thiazzz avatar thiazzz commented on June 8, 2024

I could provide a temporary API key from a subaccount in Binance for testing? Would that make it easier to investigate and solve?

from pycryptobot.

achillebnt avatar achillebnt commented on June 8, 2024

Maybe i found the problem: doing some debug i see in line 191 it try to set variable quote_min by index name MIN_NOTIONAL but dataframe doesn't have that index, instead it return this:

0 PRICE_FILTER
1 LOT_SIZE
2 ICEBERG_PARTS
3 MARKET_LOT_SIZE
4 TRAILING_DELTA
5 PERCENT_PRICE_BY_SIDE
6 NOTIONAL
7 MAX_NUM_ORDERS
8 MAX_NUM_ALGO_ORDERS

df[df["filterType"] == "MIN_NOTIONAL"][["minNotional"]].values[0][0]

from pycryptobot.

afgvdp avatar afgvdp commented on June 8, 2024

Same problem here. If it helps, the "opentrades" bot runs normally, but I am not able to start a bot manually or trough telegram.

I'll share the JSON from the "opentrades" bots, and the "scanner" bots.

This one WORKS:

{
"botcontrol": {
"status": "active",
"manualsell": false,
"manualbuy": false,
"started": "2023-04-23T16:36:32.134203",
"startmethod": "telegram",
"watchdog_ping": "2023-04-24T07:34:01.420447"
},
"preventlosstriggered": false,
"exchange": "binance",
"margin": "-11.2487%",
"delta": "-45.57",
"price": 2.948,
"df_high": " ",
"from_df_high": " ",
"trailingstoplosstriggered": false,
"change_pcnt_high": 0.0,
"indicators": {
"EMA": true,
"BULL": false,
"MACD": true
},
"signal": "WAIT"
}

This one, DOESN'T work:

{
"botcontrol": {
"status": "active",
"manualsell": false,
"manualbuy": false,
"started": "2023-04-23T23:23:48.310596",
"startmethod": "telegram"
},
"preventlosstriggered": false,
"exchange": "binance",
"margin": "",
"delta": "",
"price": 0.0,
"df_high": " ",
"from_df_high": " ",
"trailingstoplosstriggered": false,
"change_pcnt_high": 0.0
}

from pycryptobot.

whittlem avatar whittlem commented on June 8, 2024

Maybe i found the problem: doing some debug i see in line 191 it try to set variable quote_min by index name MIN_NOTIONAL but dataframe doesn't have that index, instead it return this:

0 PRICE_FILTER 1 LOT_SIZE 2 ICEBERG_PARTS 3 MARKET_LOT_SIZE 4 TRAILING_DELTA 5 PERCENT_PRICE_BY_SIDE 6 NOTIONAL 7 MAX_NUM_ORDERS 8 MAX_NUM_ALGO_ORDERS

df[df["filterType"] == "MIN_NOTIONAL"][["minNotional"]].values[0][0]

Thanks, I will take a look.

from pycryptobot.

whittlem avatar whittlem commented on June 8, 2024

Guys, can you confirm if this is a Telegram issue or a general issue? I used the config at the top and I don't get an error message when I run the bot on that market for live or test modes. If the issue happens just as the bot starts, I don't get it.

Config:

{
  "binance": {
    "api_url": "https://api.binance.com",
    "config": {
      "autorestart": 1,
      "base_currency": "SHIB",
      "disablebuynearhigh": 1,
      "enableinsufficientfundslogging": 1,
      "enabletelegrambotcontrol": 1,
      "granularity": "15m",
      "live": 0,
      "nobuynearhighpcnt": 1,
      "nosellmaxpcnt": 3,
      "nosellminpcnt": -13,
      "quote_currency": "BRL",
      "selllowerpcnt": -21,
      "telegram": 1,
      "trailingbuypcnt": 1,
      "trailingstoploss": -1,
      "trailingstoplosstrigger": 3,
      "disablelog": 0,
      "use_sell_fee": 1,
      "buypercent": 99,
      "termwidth": 180,
      "termcolor": 1,
      "verbose": 0,
      "log": 1,
      "debug": 0
    },
    "api_key_file": "binance.key"
  },
  "telegram": {
    "token": "<removed>",
    "client_id": "<removed>"
  }
}

Running bot like this:
% python3 pycryptobot.py

from pycryptobot.

MirekF avatar MirekF commented on June 8, 2024

from pycryptobot.

whittlem avatar whittlem commented on June 8, 2024

I believe it's fixed. Doing a release now.

from pycryptobot.

leohrs avatar leohrs commented on June 8, 2024

from pycryptobot.

afgvdp avatar afgvdp commented on June 8, 2024

/addnew from telegram - WORKS
/scanner and open bot - WORKS

Thank you!

from pycryptobot.

afgvdp avatar afgvdp commented on June 8, 2024

Found a issue with the new release 8.0.7

The Index 0 is fixed, but now the Telegram Bot don't recognize the active bots. I think that maybe could be the same problem as this one:

#727 (comment)

from pycryptobot.

afgvdp avatar afgvdp commented on June 8, 2024

In 8.0.7 BOTs are not buying due to "Insufficient Funds":

Bot1 2023-04-25 02:15:00 POLYXUSDT 15m *** Skipping LIVE Buy Order -- Insufficient Funds ***

Manual Buy doesn't work either.

from pycryptobot.

demkoma20 avatar demkoma20 commented on June 8, 2024

I am still getting indexError when I stopped previous session and set LIMIT sell order.
On lower price levels I tried to start but got IndexError. When I unlock funds from LIMIT order bot works but start where ends. And that's what I don't want.

from pycryptobot.

whittlem avatar whittlem commented on June 8, 2024

In 8.0.7 BOTs are not buying due to "Insufficient Funds":

Bot1 2023-04-25 02:15:00 POLYXUSDT 15m *** Skipping LIVE Buy Order -- Insufficient Funds ***

Manual Buy doesn't work either.

This may sound like a thick question, but I have to ask. You definitely have sufficient funds? E.g., at least 10 of the quote currently (as a guide)

from pycryptobot.

whittlem avatar whittlem commented on June 8, 2024

This week is super busy for me but I'll take a look next week. If anyone can help narrow down the problem, that would help. For example, is it Binance only? Is it Docker or CLI or both? Is it happening with the Telegram bot only or both?, If you can provide more info to help me recreate what you are seeing that would help. If you can provide your config.json and the way you are running your bots that would help as well.

from pycryptobot.

afgvdp avatar afgvdp commented on June 8, 2024

In 8.0.7 BOTs are not buying due to "Insufficient Funds":
Bot1 2023-04-25 02:15:00 POLYXUSDT 15m *** Skipping LIVE Buy Order -- Insufficient Funds ***
Manual Buy doesn't work either.

This may sound like a thick question, but I have to ask. You definitely have sufficient funds? E.g., at least 10 of the quote currently (as a guide)

Hi Michael, it was solved in the Chat. Another guy told me to ser "buymaxsize". I did it and problem solved!

from pycryptobot.

demkoma20 avatar demkoma20 commented on June 8, 2024

This week is super busy for me but I'll take a look next week. If anyone can help narrow down the problem, that would help. For example, is it Binance only? Is it Docker or CLI or both? Is it happening with the Telegram bot only or both?, If you can provide more info to help me recreate what you are seeing that would help. If you can provide your config.json and the way you are running your bots that would help as well.

I tried only on Binance. Without Telegram or Docker/Kubernetes, running in shell through python3 ./pycryptobot.py --logfile cryptobot-BTCUSDT.log --market BTCUSDT --granularity 3600
Issue is occured when:

  1. 1st bot run - success
  2. Stop bot
  3. Previously bought funds by bot are locked in LIMIT order
  4. 2nd bot run - fail
  5. Unlock funds
  6. Bot run - success and started where ends

from pycryptobot.

whittlem avatar whittlem commented on June 8, 2024

I'm getting same "*** Skipping LIVE Buy Order -- Insufficient Funds ***" message. There is definitely a bug. I'm troubleshooting it and just waiting for the next buy signal to see what happens.

from pycryptobot.

whittlem avatar whittlem commented on June 8, 2024

Fixed for me in 8.0.9. Give it a try and let me know.

from pycryptobot.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.