Hello!
It seems the Pydantic 2.9.0 version introduced a breaking change on PydanticModelField.to_argument adding two new arguments:
pydantic/pydantic@d6df62a
and
pydantic/pydantic@93ced97
This is the mypy trace
./my-file.py:132: 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.11.2
Traceback (most recent call last):
File "mypy/semanal.py", line 7087, in accept
File "mypy/nodes.py", line 1183, in accept
File "mypy/semanal.py", line 1700, in visit_class_def
File "mypy/semanal.py", line 1891, in analyze_class
File "mypy/semanal.py", line 1925, in analyze_class_body_common
File "mypy/semanal.py", line 1996, in apply_class_plugin_hooks
File "/Users/victorbarroncas/code/boostsec-asset-management/.venv/lib/python3.12/site-packages/strawberry/ext/mypy_plugin.py", line 489, in strawberry_pydantic_class_callback
f.to_argument(
TypeError: PydanticModelField.to_argument() missing 2 required positional arguments: 'model_strict' and 'is_root_model_root'
./my-file.py:132: : note: use --pdb to drop into pdb
Similar issue:
#3560
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too