Merge pull request #10693 from tk0miya/mypy-0.971

Fix mypy violations (with mypy-0.971)
This commit is contained in:
Takeshi KOMIYA 2022-07-23 15:16:33 +09:00 committed by GitHub
commit 94f62e7f2b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -41,7 +41,7 @@ extras_require = {
'lint': [
'flake8>=3.5.0',
'isort',
'mypy>=0.950',
'mypy>=0.971',
'docutils-stubs',
"types-typed-ast",
"types-requests",

View File

@ -77,7 +77,7 @@ def convert_serializable(records: List[logging.LogRecord]) -> None:
location = getattr(r, 'location', None)
if isinstance(location, nodes.Node):
r.location = get_node_location(location) # type: ignore
r.location = get_node_location(location)
class SphinxLogRecord(logging.LogRecord):
@ -431,7 +431,7 @@ class DisableWarningIsErrorFilter(logging.Filter):
"""Disable WarningIsErrorFilter if this filter installed."""
def filter(self, record: logging.LogRecord) -> bool:
record.skip_warningsiserror = True # type: ignore
record.skip_warningsiserror = True
return True