-
proles = [1011627788031238284, 1011627841189855304, 1011627884588314674]
pgroles = []
pemojis = [":desktop:", "<:Console:1011634205526069298>", "<:Mobile:1011634497189576784>"]
pplaceholder = "Select your platform(s)"
for roles in proles:
pgroles.append(discord.SelectOption(label=interaction.guild.get_role(roles).name, value=str(roles), emoji=pemojis[proles.index(roles)])) but if i use directly like full error: Traceback (most recent call last):
File "/home/ashroy/.local/lib/python3.10/site-packages/discord/app_commands/tree.py", line 1240, in _call
await command._invoke_with_namespace(interaction, namespace)
File "/home/ashroy/.local/lib/python3.10/site-packages/discord/app_commands/commands.py", line 879, in _invoke_with_namespace
return await self._do_call(interaction, transformed_values)
File "/home/ashroy/.local/lib/python3.10/site-packages/discord/app_commands/commands.py", line 872, in _do_call
raise CommandInvokeError(self, e) from e
discord.app_commands.errors.CommandInvokeError: Command 'self_roles' raised an exception: HTTPException: 400 Bad Request (error code: 50035): Invalid Form Body
In components.0.components.0.options.0.emoji.name: Invalid emoji |
Beta Was this translation helpful? Give feedback.
Answered by
CaedenPH
Sep 22, 2022
Replies: 1 comment 1 reply
-
I believe this is due to |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
aurkaxi
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I believe this is due to
:desktop:
not being a valid emoji. You can use https://unicode.org/emoji/charts/full-emoji-list.html to get the unicode and try that.