Skip to content

Commit

Permalink
Working fix for typing in telegram provider (#40258)
Browse files Browse the repository at this point in the history
The python-telegram-bot new version has typing added and we should
pass the right dict type to it. The #40255 was an unsuccessful
attempt to fix it, this one actually fixes it.

(cherry picked from commit 1451bac)
  • Loading branch information
potiuk authored and utkarsharma2 committed Jul 3, 2024
1 parent 7df4f5a commit 12df2ef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion airflow/providers/telegram/hooks/telegram.py
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ def send_message(self, api_params: dict) -> None:
:param api_params: params for telegram_instance.send_message. It can also be used to override chat_id
"""
kwargs: dict[str, int | str | bool] = {
kwargs: dict[str, Any] = {
"parse_mode": telegram.constants.ParseMode.HTML,
"disable_web_page_preview": True,
}
Expand Down

0 comments on commit 12df2ef

Please sign in to comment.