Skip to content

feat: ✨ add unknown sticker format type to StickerFormatType enum #58

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

Paillat-dev
Copy link
Member

fixes: #16

@Paillat-dev Paillat-dev requested a review from a team as a code owner August 3, 2025 22:45
@NeloBlivion
Copy link
Member

this should probably just use try_enum instead, which has a built-in strategy for unknown values

@Paillat-dev
Copy link
Member Author

Yeah that makes sense

Copy link

@Lumabots Lumabots left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@Paillat-dev Paillat-dev force-pushed the feat/unknown-sticker-format branch from 57fe250 to bfd6d0b Compare August 4, 2025 11:43
@Paillat-dev
Copy link
Member Author

This already uses try_enum wherever needed, I changed from png to None because it is better representative in my opinion

@Paillat-dev Paillat-dev requested a review from Lumabots August 4, 2025 11:44
@Lumabots
Copy link

Lumabots commented Aug 4, 2025

i dont really get why we should use None instead of unknow. Its not really clear imo to have None as a format type

@Paillat-dev
Copy link
Member Author

So it's not the format type, it's the file extension. The format type will always be an integer, and if that integer exists in the enum it will be made into the enum with try_enum

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.

Improve handling of unknown sticker format types if possible
3 participants