Skip to content

Conversation

@srittau
Copy link
Collaborator

@srittau srittau commented May 30, 2025

  • Add a few Self return annotations.
  • Add a few # type: ignore[override].
  • Add a few @deprecated annotations.

Should help with #14194

* Add a few `Self` return annotations.
* Add a few `# type: ignore[override]`.
* Add a few `@deprecated` annotations.

Should help with python#14194
@github-actions
Copy link
Contributor

Diff from mypy_primer, showing the effect of this PR on open source code:

archinstall (https://github.com/archlinux/archinstall)
+ ./archinstall/tui/curses_menu.py:710: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.15.0
+ ./archinstall/tui/curses_menu.py:710: : note: use --pdb to drop into pdb
+ Traceback (most recent call last):
+   File "mypy/checkexpr.py", line 5903, in accept
+   File "mypy/nodes.py", line 1889, in accept
+   File "mypy/checkexpr.py", line 3284, in visit_member_expr
+   File "mypy/checkexpr.py", line 3309, in analyze_ordinary_member_access
+   File "mypy/checkmember.py", line 207, in analyze_member_access
+   File "mypy/checkmember.py", line 226, in _analyze_member_access
+   File "mypy/checkmember.py", line 344, in analyze_instance_member_access
+   File "mypy/meet.py", line 96, in meet_types
+   File "mypy/subtypes.py", line 223, in is_proper_subtype
+   File "mypy/subtypes.py", line 351, in _is_subtype
+   File "mypy/types.py", line 1469, in accept
+   File "mypy/subtypes.py", line 581, in visit_instance
+   File "mypy/subtypes.py", line 2095, in infer_class_variances
+   File "mypy/subtypes.py", line 2057, in infer_variance
+   File "mypy/subtypes.py", line 186, in is_subtype
+   File "mypy/subtypes.py", line 351, in _is_subtype
+   File "mypy/types.py", line 3033, in accept
+   File "mypy/subtypes.py", line 1079, in visit_partial_type
+ RuntimeError: Partial type "<partial list[?]>" cannot be checked with "issubtype()"

@JelleZijlstra JelleZijlstra merged commit 8465877 into python:main May 31, 2025
49 checks passed
@srittau srittau deleted the passlib-override branch June 1, 2025 06:05
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