Skip to content
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

[BUG] Docs confusingly suggest that message_reaction and message_reaction_count are included in webhook updates by default #4116

Closed
mbanerjeepalmer opened this issue Feb 13, 2024 · 6 comments
Assignees

Comments

@mbanerjeepalmer
Copy link
Contributor

Steps to Reproduce

  1. Read docs which say that for allowed_updates you should 'Specify an empty sequence to receive all updates except telegram.Update.chat_member (default).'
  2. Leave allowed_updates empty (i.e. do not specify parameter at all).

Expected behaviour

Given the python-telegram-bot docs, the user expects the webhook to deliver message_reaction and message_reaction_count.

Actual behaviour

The webhook is not set up to deliver message reactions. This is because Telegram's default behaviour is actually the following:

Specify an empty list to receive all update types except chat_member, message_reaction, and message_reaction_count (default). If not specified, the previous setting will be used.

Source: https://core.telegram.org/bots/api#setwebhook

Operating System

Ubuntu 22.04.3

Version of Python, python-telegram-bot & dependencies

python-telegram-bot 20.7
Bot API 6.9
Python 3.10.12 (main, Nov 20 2023, 15:14:05) [GCC 11.4.0]

Relevant log output

No response

Additional Context

The wording change needs to be made here: https://github.com/python-telegram-bot/python-telegram-bot/blob/master/telegram/_bot.py#L4260

@Poolitzer
Copy link
Member

Do you want to PR against doc-fixes and change it?

@mbanerjeepalmer
Copy link
Contributor Author

Can do

@Trifase
Copy link
Contributor

Trifase commented Feb 13, 2024

Please, can you update the docs for run_polling too for the same parameter?

@harshil21
Copy link
Member

hey @mbanerjeepalmer, are you still working on this? We're nearing a new release so it would be nice to include this as well.

@mbanerjeepalmer
Copy link
Contributor Author

@harshil21 PR opened. Black was giving me weird line lengths so there are some unnecessary line breaks, let me know if that needs fixing.

@harshil21
Copy link
Member

Closed by #4140.

Bibo-Joshi added a commit that referenced this issue Mar 6, 2024
Co-authored-by: Aditya <adityayadav11082@gmail.com>
Co-authored-by: Harshil <37377066+harshil21@users.noreply.github.com>
Co-authored-by: Maurice Banerjee Palmer <31225563+mbanerjeepalmer@users.noreply.github.com>
@github-actions github-actions bot locked and limited conversation to collaborators Mar 10, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants