Skip to content

Conversation

Lacosst0
Copy link
Contributor

Pull Request Type

  • Feature addition
  • Bugfix
  • Documentation update
  • Code refactor
  • Tests improvement
  • CI/CD pipeline enhancement
  • Other: [Replace with a description]

Description

This PR fixes sending StringSelectOption with CustomEmoji when msgspec is installed (used)

Changes

  • Added isinstance check to enc_hook in interactions\client\utils\input_utils.py

Related Issues

#1561

Test Scenarios

@slash_command()
async def test(ctx: SlashContext):
    await ctx.respond(
        components=StringSelectMenu(
            StringSelectOption(label="test", value="test_value", emoji=(await ctx.guild.fetch_all_custom_emojis())[0]) # test emoji
        )
    )

Python Compatibility

  • I've ensured my code works on Python 3.10.x
  • I've ensured my code works on Python 3.11.x

Checklist

  • I've run the pre-commit code linter over all edited files
  • I've tested my changes on supported Python versions
  • I've added tests for my code, if applicable
  • I've updated / added documentation, where applicable

Signed-off-by: Lacosst0 <68904262+Lacosst0@users.noreply.github.com>
@LordOfPolls
Copy link
Contributor

Looks good. I'll test it tonight

Signed-off-by: Lacosst0 <68904262+Lacosst0@users.noreply.github.com>
@LordOfPolls LordOfPolls merged commit 0cea688 into interactions-py:unstable Nov 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants