Misleading static type for "execution result" attribute (introduced in 0.240.0
)
#3635
Labels
bug
Something isn't working
0.240.0
)
#3635
I think #3554 introduce a static typing bug in the execution result attribute.
It's statically typed as graphql.ExecutionResult type from
graphql-core
:strawberry/strawberry/types/execution.py
Line 25 in 2941146
strawberry/strawberry/types/execution.py
Line 56 in 2941146
But in reality it's this custom dataclass from Strawberry's codebase (at least in some situations):
strawberry/strawberry/types/execution.py
Lines 92 to 108 in 2941146
PS: The specific problem is the typechecker makes us think it's okay to access the
formatted
property, which is actually missing:https://github.com/graphql-python/graphql-core/blob/26701397d84338a42c7acbce78368ae8f9d97271/src/graphql/execution/incremental_publisher.py#L97-L105
Upvote & Fund
The text was updated successfully, but these errors were encountered: