Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions pydantic_ai_slim/pydantic_ai/_function_schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ def function_schema( # noqa: C901
errors: list[str] = []

try:
sig = signature(function)
sig = signature(function, follow_wrapped=False)
except ValueError as e:
errors.append(str(e))
sig = signature(lambda: None)
Expand Down Expand Up @@ -244,7 +244,7 @@ def _takes_ctx(function: TargetFunc[P, R]) -> TypeIs[WithCtx[P, R]]:
`True` if the function takes a `RunContext` as first argument, `False` otherwise.
"""
try:
sig = signature(function)
sig = signature(function, follow_wrapped=False)
except ValueError: # pragma: no cover
return False # pragma: no cover
try:
Expand Down