Skip to content

Agent/fix falsy callback data - #5328

Closed
Vamp1reAchao wants to merge 3 commits into
python-telegram-bot:masterfrom
Vamp1reAchao:agent/fix-falsy-callback-data
Closed

Agent/fix falsy callback data#5328
Vamp1reAchao wants to merge 3 commits into
python-telegram-bot:masterfrom
Vamp1reAchao:agent/fix-falsy-callback-data

Conversation

@Vamp1reAchao

@Vamp1reAchao Vamp1reAchao commented Aug 13, 2026

Copy link
Copy Markdown

Fixed CallbackQueryHandler incorrectly ignoring falsy callback_data values such as False, 0, and "" when a pattern is configured. Added regression tests.

@harshil21

Copy link
Copy Markdown
Member

There is no use case for this. pure ints / bools are technically arbitrary callback data already. Moreover your proposal doesn't actually fix it, if the callback_data is e.g. False, and the pattern is False, the handler still isn't triggered.

@harshil21 harshil21 closed this Aug 13, 2026
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.

2 participants