MizaGBF / MizaBOT

Python 3 Granblue Fantasy-themed Discord Bot
MIT License
25 stars 13 forks source link

loadData error when deploying #18

Closed atliv closed 2 years ago

atliv commented 2 years ago

hello i have a lil problem again, it's seems when i tried to up the bot in local or production env. i got this error

image

and here's my config.json

image

is my config file setup is correct ady or something wrong in somewhere else ?

MizaGBF commented 2 years ago

it's a save.json error, not config.json.
Again it's caused by old code which I didn't test properly with the example file (or broke at some point).
I just pushed a fix, try it out.

atliv commented 2 years ago

here i get new error message in differrent place now image

MizaGBF commented 2 years ago

The first two are normal, it's because my test files are missing (the bot will run without them).
The third, however, I'm not sure. What python version are you running?

atliv commented 2 years ago

it's 3.10.4 image

MizaGBF commented 2 years ago

I found the cause of the problem, it's likely caused by Windows. I'll push a fix in a few minutes.

atliv commented 2 years ago

btw i just want to give you some update, the bot is online in my dummy server but it didnt response everytime i typed a command, here's the log in my heroku image

MizaGBF commented 2 years ago

From what I see:

MizaGBF commented 2 years ago

In doubt: Also check if you put your server ID under debug_server.

atliv commented 2 years ago

From what I see:

  • The missing access error is caused by a permission problem. Double check its permissions in your server. If it's not it, check the invite link you used: It needs the applications.commands scope. The url should have something like &scope=bot%20applications.commands. Also, take note the commands can take up to one hour to be available in your server (it's a Discord side problem, there is nothing we can do about it).
  • The two Invalid key errors are caused by config.json, image_upload and debug_update channel IDs aren't set or wrong (You can ignore it for now).
  • The last two errors are because it couldn't access the debug channel you set in config.json. Considering it didn't cause a key error above, maybe a permission problem too?

yeah i forgot to check application commands. now in my server the bot will response "the application did not respond" image is this what you mean "the commands can take up to one hour to be available" ?

MizaGBF commented 2 years ago

If you can see the commands when typing /, then they are already available (it doesn't take long with only one server).
I believe you get this message because the bot can't post in this channel, or something similar.

MizaGBF commented 2 years ago

Note: you should see a boot message, if everything is alright, in your debug channel. Something like this: image

atliv commented 2 years ago

ok thanks, i think i will try to check the permission in my server first. anyway about loadData error has been solved,

should i close this issue ?

MizaGBF commented 2 years ago

If there is nothing else, yes.