From 977d56ab4378bb00be97badcddb7d464ae0456be Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 2 Jun 2022 10:08:15 +0200 Subject: [PATCH] Bump `mypy` from 0.950 to 0.960 (#3070) * Bump mypy from 0.950 to 0.960 Bumps [mypy](https://github.com/python/mypy) from 0.950 to 0.960. - [Release notes](https://github.com/python/mypy/releases) - [Commits](https://github.com/python/mypy/compare/v0.950...v0.960) --- updated-dependencies: - dependency-name: mypy dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * update pre-commit as well * fix type hint for CIRHandler.collect_additional_context Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Hinrich Mahler <22366557+Bibo-Joshi@users.noreply.github.com> Co-authored-by: Harshil <37377066+harshil21@users.noreply.github.com> --- .pre-commit-config.yaml | 2 +- requirements-dev.txt | 2 +- telegram/ext/_choseninlineresulthandler.py | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index a5f4b39c0..9c1dbde0e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -39,7 +39,7 @@ repos: - cachetools~=5.0.0 - . # this basically does `pip install -e .` - repo: https://github.com/pre-commit/mirrors-mypy - rev: v0.950 + rev: v0.960 hooks: - id: mypy name: mypy-ptb diff --git a/requirements-dev.txt b/requirements-dev.txt index 6e30d0d3f..84a112796 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -6,7 +6,7 @@ pre-commit black==22.3.0 flake8==4.0.1 pylint==2.13.9 -mypy==0.950 +mypy==0.960 pyupgrade==2.32.1 isort==5.10.1 diff --git a/telegram/ext/_choseninlineresulthandler.py b/telegram/ext/_choseninlineresulthandler.py index 27f335ebf..8251fca97 100644 --- a/telegram/ext/_choseninlineresulthandler.py +++ b/telegram/ext/_choseninlineresulthandler.py @@ -29,7 +29,7 @@ from telegram.ext._utils.types import CCT, HandlerCallback RT = TypeVar("RT") if TYPE_CHECKING: - from telegram.ext import Application, CallbackContext + from telegram.ext import Application class ChosenInlineResultHandler(BaseHandler[Update, CCT]): @@ -108,7 +108,7 @@ class ChosenInlineResultHandler(BaseHandler[Update, CCT]): def collect_additional_context( self, - context: "CallbackContext", + context: CCT, update: Update, application: "Application", check_result: Union[bool, Match],