Closed NatasFX closed 1 year ago
Update: remove_reaction also shows the same behavior. Getting the emoji with client.get_emoji(EMOJI_ID) where emoji_id is the number part in the string above works, thus message.add_reaction(client.get_emoji(EMOJI_ID))
works fine.
Link to discussion in the "Discord Developers" server
Stripping the leading :
seems to do the trick:
<:Arch:905328118078775296>
does not work<Arch:905328118078775296>
works as expected
(this is a custom emoji from my server. the actual emoji doesn't matter)Could be changed to return emoji.strip('<:>')
Seems to be a breaking API change, and has broken our bot at Python Discord. However I'm not 100% sure because I don't see any mention of it in changelogs or the official discord API reference
Link to discussion in the "Discord Developers" server
Stripping the leading
:
seems to do the trick:
<:Arch:905328118078775296>
does not work<Arch:905328118078775296>
works as expected (this is a custom emoji from my server. the actual emoji doesn't matter)Could be changed to
return emoji.strip('<:>')
Can confirm, it indeed works.
Can confirm, it indeed works.
Did you try monkeypatching it in the discord.py internals?
Can confirm, it indeed works.
Did you try monkeypatching it in the discord.py internals?
I had tried just removing the first :
, altering the message.py as you said also worked.
Great. Looks like it should be a simple internal fix, then.
This was fixed on Discord's side. Issue can be closed.
Summary
add_reaction('<:thisisemoji:0123456789>') gives 400 http error code
Reproduction Steps
I'm on discord.py 1.7.3, and suddently today my bot started giving
discord.errors.HTTPException: 400 Bad Request (error code: 50035): Invalid Form Body In emoji_id: Value "sce" is not snowflake.
when trying to add a reaction to a message using a string of the custom guild emoji id, like this:message.add_reaction('<:customguildemoji:012345678901010010>')
full traceback:
Minimal Reproducible Code
No response
Expected Results
Emoji correcltly added to the message.
Actual Results
HTTP error 400.
Intents
all intents.
System Information
Checklist
Additional Context
No response