Closed vst212 closed 1 year ago
Try Updating Py-cord it solved the issue for me , still getting "Request has failed; please try later" tho
Try Updating Py-cord it solved the issue for me , still getting "Request has failed; please try later" tho
thx, fixed for that, how if you faced error 401 unauthorized? But I am so sure that the API key is correct.
@vst212 try debugging more, we don't have enough info
I got this error as well, did you find any solution for that? I believe my py-cord version is up-to-date 2.0.0 ### discord.errors.HTTPException: 405 Method Not Allowed (error code: 0): 405: Method Not Allowed
I tried the bot today, and it seems that can't reproduce the error, everything works fine for me.
It should me this error. I uninstalled py-cord:
pip uninstall py-cord
and installed it again:
pip install py-cord
I am also seeing this issue. Spawning from https://github.com/Wildric-Auric/MidJourney-Wrapper/issues/15
I thought it was my environment, so I used a completely fresh VM of Ubuntu 22.10 and still get the Method not allowed error and Request has failed; please try later whenever I try to invoke the /mj_imagine command
I just used WSL to launch the bot and it worked; does the command /Hello work for you?
/hello hello
Returns hello into the chat.
I just tested Windows 10, as well as Raspberry Pi, and Linux Debian. It worked on Windows for one time, but now getting
Request has failed; please try later
Same error on Linux and Pi too.
I am getting 400 error
I am getting 400 error
after new release , everything ok now
I no longer get any errors when the bot starts but now get this error when I do any /mj_imagine prompt:
python3 main.py
Logged in as Bot ####
Ignoring exception in command mj_imagine:
Traceback (most recent call last):
File "/home/pi/.local/lib/python3.10/site-packages/discord/commands/core.py", line 124, in wrapped
ret = await coro(arg)
File "/home/pi/.local/lib/python3.10/site-packages/discord/commands/core.py", line 982, in _invoke
await self.callback(ctx, **kwargs)
File "/home/pi/MidJourney-Wrapper/main.py", line 27, in mj_imagine
print(response.txt)
AttributeError: 'Response' object has no attribute 'txt'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/pi/.local/lib/python3.10/site-packages/discord/bot.py", line 1114, in invoke_application_command
await ctx.command.invoke(ctx)
File "/home/pi/.local/lib/python3.10/site-packages/discord/commands/core.py", line 375, in invoke
await injected(ctx)
File "/home/pi/.local/lib/python3.10/site-packages/discord/commands/core.py", line 132, in wrapped
raise ApplicationCommandInvokeError(exc) from exc
discord.errors.ApplicationCommandInvokeError: Application Command raised an exception: AttributeError: 'Response' object has no attribute 'txt'
@BoredMind
Well, it's reponse.text
not response.txt
...
It's in the main.py in the repo:
C:\Users\Administrator\Desktop\MidJourney-Wrapper-main>python main.py Ignoring exception in on_connect Traceback (most recent call last): File "C:\Users\Administrator\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\client.py", line 352, in _run_event await coro(*args, **kwargs) File "C:\Users\Administrator\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\bot.py", line 793, in on_connect await self.register_commands() File "C:\Users\Administrator\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\bot.py", line 460, in register_commands await self.http.bulk_upsert_command_permissions( File "C:\Users\Administrator\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\http.py", line 338, in request raise HTTPException(response, data) discord.errors.HTTPException: 405 Method Not Allowed (error code: 0): 405: Method Not Allowed
do you know any reason that he error 405 in program first one. error 401 when prompt submitted