derfabsSL / Splinterbuyer

Splinterbuyer - Splinterlands Autobid Market Bot
20 stars 8 forks source link

Error #6

Closed sieutran closed 2 years ago

sieutran commented 2 years ago

I get this error: Traceback (most recent call last): File "Splinterbuyer.py", line 23, in configfile = json.load(f) File "/usr/lib/python3.8/json/init.py", line 293, in load return loads(fp.read(), File "/usr/lib/python3.8/json/init.py", line 357, in loads return _default_decoder.decode(s) File "/usr/lib/python3.8/json/decoder.py", line 337, in decode obj, end = self.raw_decode(s, idx=_w(s, 0).end()) File "/usr/lib/python3.8/json/decoder.py", line 355, in raw_decode raise JSONDecodeError("Expecting value", s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 16 column 5 (char 390)

derfabsSL commented 2 years ago

looks like there is an error in line 16 of your bids.json

sieutran commented 2 years ago

Thanks. I got it. Its okie now

sieutran commented 2 years ago

Hi,

I get this error. Is it because of soft ban? error occured while checking cards: Exception('Invalid CardID') Error: Request Timeout Retry RPC Call on node: https://api.hive.blog (1/5)

derfabsSL commented 2 years ago

You are not banned, this error just means the bot can't read that specific Blockchain post, because it is in a weird format.

sieutran commented 2 years ago

Hi, How about this error? File "D:\xxxxxx\Splinterbuyer.py", line 128, in cards_tmp = [card for card in cardsjson if rarities[int(card["rarity"])] in bid["rarities"] File "D:\xxxxxx\Splinterbuyer.py", line 130, in and str(card["type"]).lower() in str(bid["types"]).lower()]

Here is my bid [{ "comment": "Fungus", "cards": [380], "editions": ["chaos"], "rarities": ["legendary"], "elements": ["earth"], "type": ["monster"], "max_price": 6, "max_quantity": 20, "gold_only": false, "exclude_cl": false, "sell_for_pct_more": 0 }, { "comment": "Torrent", "cards": [394], "editions": ["chaos"], "rarities": ["legendary"], "elements": ["water"], "type": ["monster"], "max_price": 5.5, "max_quantity": 10, "gold_only": false, "exclude_cl": false, "sell_for_pct_more": 0 }

]
derfabsSL commented 2 years ago

Should be "types" in bids.json, not "type", I made an error in example file. Thanks for the feedback, I'll update the example.

ZeroCool940711 commented 2 years ago

@derfabsSL you use on some parts "type" and in others "types", just to let you know so you can double-check.

derfabsSL commented 2 years ago

Bot works, files are updated. You don't need to redownload, just exchange "type" for "types" in bids