bsc-predict / bsc-predict-bot

PancakeSwap Prediction market bot. Use your own strategy
https://www.bscpredict.com
38 stars 16 forks source link

Not working #3

Open allservice-ro opened 1 year ago

allservice-ro commented 1 year ago

Not working on Python 3.8 and 3.11. all sort of errors File "c:\Python38\Predict\contracts\prediction.py", line 20, in rounds = [Round(r.split(",")) for r in r.text.split("\n")[1:] if len(r) > 0]

File "c:\Python38\Predict\classes\RoundClass.py", line 29, in init epoch, \ VlueError: too many values to unpack (expected 14)

Using Windows I added \r\n for the next line, still not working. It gets the csv but doesn't see, to parse it correctly.

If I modify RoundCLass like below, it jumps the error but contract is reverted. No bet.

def __init__(self, t: List):
  epoch, \
  startTimestamp, \
  lockTimestamp, \
  closeTimestamp, \
  lockPrice, \
  closePrice, \
  lockOracleId, \
  closeOracleId, \
  totalAmount, \
  bullAmount, \
  bearAmount, \
  rewardBaseCalAmount, \
  rewardAmount, \
  oracleCalled, \
  *extra  = t

It's buggy and I'm done iwth it. Verdict. Not working.

Illusive-Girl commented 1 year ago

I tried python from 3.7 to 3.11 on linux and windows, spent two days trying to get it to work, but with each corrected error a new one appeared (you seem to have moved further, I don’t even have a csv file). maybe if the developer would specify the necessary versions of modules and python in the requirements.txt file, then it could still be made to work (well, or pancakeswap v2 would not allow). it's a pity of all the bots, this one is the most interesting due to the simple adjustment of strategies.

allservice-ro commented 1 year ago

Well the bot uses the csv file to obtain the timestamp for the previous round to know when the round started and is betable, and it also uses this stupid "oracle" contract to obtain "previsions" that I found to be not quite trustworthy. The idea is to eliminate these two get_history() and get_oracle_history() from the BaseBot.py and create a new Bot class without this shht, and use StartRound event to get the correct timestamp when the round is starting. Or smply start the bot manually when the first round starts and then add time from there. I am trying to eliminate the junk and make it work.