Avatar for the strawberry-graphql user
strawberry-graphql
strawberry
BlogDocsChangelog

Performance History

Latest Results

Add generic exception handlers Shortcake-Parent: main
2026-06-28-add-generic-exception-handlers
2 hours ago
Address code review of exception handlers Fixes the issues found in the pre-merge review of the exception-handlers feature (mapping Python exceptions to typed GraphQL union results). Correctness: - Return an awaitable handled result on async fields so async field extensions (e.g. async PermissionExtension) can await it instead of crashing with "object ... can't be used in 'await' expression". - Make the argument-conversion-error path safe for arg-consuming extensions: field extensions (e.g. permission checks) run with the raw argument values, so a matching handler can convert the error instead of it surfacing as an unrelated crash. - Match a concrete generic error_type (e.g. Error[int]) against the matching union member by resolving it through StrawberryAnnotation, instead of silently collapsing to the bare generic and never matching. - Route basic fields (no resolver) through handling when a handler applies, so an unrelated extension no longer flips whether errors are converted. - Skip all exception-handling machinery when no handler applies to a field (fast path), so existing schemas keep the resolver's original Task/Future and pay no overhead. API surface: - Move federation Schema's exception_handlers after federation_version so a positional version argument can't land in it. - Make strawberry.ExceptionHandler a @runtime_checkable Protocol. - Declare exception_handlers on the BaseSchema protocol. - Rename the internal excepthook alias to ExcepthookHandler and the new type_comparison helper to _resolve_object_definition to avoid colliding with public names. Cleanup: - Pre-compute applicable handlers per field once at schema build, removing per-request rescans and the double handler scan. - Convert arguments once, guarded by a single try/except, instead of branching on whether the field has handlers. - Rely on type hints for handler configuration rather than validating it at runtime, matching the rest of the codebase. Also adds regression tests and benchmarks, documents that generic error types must be referenced by their concrete instantiation, and notes that subscriptions are not covered.
2026-06-28-add-generic-exception-handlers
3 hours ago
Require release URL in social copy
codex/require-release-link-social-copy
4 hours ago
Address code review of exception handlers Fixes the issues found in the pre-merge review of the exception-handlers feature (mapping Python exceptions to typed GraphQL union results). Correctness: - Return an awaitable handled result on async fields so async field extensions (e.g. async PermissionExtension) can await it instead of crashing with "object ... can't be used in 'await' expression". - Make the argument-conversion-error path safe for arg-consuming extensions: field extensions (e.g. permission checks) run with the raw argument values, so a matching handler can convert the error instead of it surfacing as an unrelated crash. - Match a concrete generic error_type (e.g. Error[int]) against the matching union member by resolving it through StrawberryAnnotation, instead of silently collapsing to the bare generic and never matching. - Route basic fields (no resolver) through handling when a handler applies, so an unrelated extension no longer flips whether errors are converted. - Skip all exception-handling machinery when no handler applies to a field (fast path), so existing schemas keep the resolver's original Task/Future and pay no overhead. API surface: - Move federation Schema's exception_handlers after federation_version so a positional version argument can't land in it. - Make strawberry.ExceptionHandler a @runtime_checkable Protocol. - Declare exception_handlers on the BaseSchema protocol. - Rename the internal excepthook alias to ExcepthookHandler and the new type_comparison helper to _resolve_object_definition to avoid colliding with public names. Cleanup: - Pre-compute applicable handlers per field once at schema build, removing per-request rescans and the double handler scan. - Convert arguments once, guarded by a single try/except, instead of branching on whether the field has handlers. - Rely on type hints for handler configuration rather than validating it at runtime, matching the rest of the codebase. Also adds regression tests and benchmarks, documents that generic error types must be referenced by their concrete instantiation, and notes that subscriptions are not covered.
2026-06-28-add-generic-exception-handlers
4 hours ago
Address code review of exception handlers Fixes the issues found in the pre-merge review of the exception-handlers feature (mapping Python exceptions to typed GraphQL union results). Correctness: - Return an awaitable handled result on async fields so async field extensions (e.g. async PermissionExtension) can await it instead of crashing with "object ... can't be used in 'await' expression". - Make the argument-conversion-error path safe for arg-consuming extensions: field extensions (e.g. permission checks) run with the raw argument values, so a matching handler can convert the error instead of it surfacing as an unrelated crash. - Match a concrete generic error_type (e.g. Error[int]) against the matching union member by resolving it through StrawberryAnnotation, instead of silently collapsing to the bare generic and never matching. - Route basic fields (no resolver) through handling when a handler applies, so an unrelated extension no longer flips whether errors are converted. - Skip all exception-handling machinery when no handler applies to a field (fast path), so existing schemas keep the resolver's original Task/Future and pay no overhead. API surface: - Move federation Schema's exception_handlers after federation_version so a positional version argument can't land in it. - Make strawberry.ExceptionHandler a @runtime_checkable Protocol. - Declare exception_handlers on the BaseSchema protocol. - Rename the internal excepthook alias to ExcepthookHandler and the new type_comparison helper to _resolve_object_definition to avoid colliding with public names. Cleanup: - Pre-compute applicable handlers per field once at schema build, removing per-request rescans and the double handler scan. - Convert arguments once, guarded by a single try/except, instead of branching on whether the field has handlers. - Rely on type hints for handler configuration rather than validating it at runtime, matching the rest of the codebase. Also adds regression tests and benchmarks, documents that generic error types must be referenced by their concrete instantiation, and notes that subscriptions are not covered.
2026-06-28-add-generic-exception-handlers
14 hours ago
Address code review of exception handlers Fixes the issues found in the pre-merge review of the exception-handlers feature (mapping Python exceptions to typed GraphQL union results). Correctness: - Return an awaitable handled result on async fields so async field extensions (e.g. async PermissionExtension) can await it instead of crashing with "object ... can't be used in 'await' expression". - Make the argument-conversion-error path safe for arg-consuming extensions: field extensions (e.g. permission checks) run with the raw argument values, so a matching handler can convert the error instead of it surfacing as an unrelated crash. - Match a concrete generic error_type (e.g. Error[int]) against the matching union member by resolving it through StrawberryAnnotation, instead of silently collapsing to the bare generic and never matching. - Route basic fields (no resolver) through handling when a handler applies, so an unrelated extension no longer flips whether errors are converted. - Skip all exception-handling machinery when no handler applies to a field (fast path), so existing schemas keep the resolver's original Task/Future and pay no overhead. API surface: - Move federation Schema's exception_handlers after federation_version so a positional version argument can't land in it. - Make strawberry.ExceptionHandler a @runtime_checkable Protocol. - Declare exception_handlers on the BaseSchema protocol. - Rename the internal excepthook alias to ExcepthookHandler and the new type_comparison helper to _resolve_object_definition to avoid colliding with public names. Cleanup: - Pre-compute applicable handlers per field once at schema build, removing per-request rescans and the double handler scan. - Convert arguments once, guarded by a single try/except, instead of branching on whether the field has handlers. - Rely on type hints for handler configuration rather than validating it at runtime, matching the rest of the codebase. Also adds regression tests and benchmarks, documents that generic error types must be referenced by their concrete instantiation, and notes that subscriptions are not covered.
2026-06-28-add-generic-exception-handlers
1 day ago

Latest Branches

CodSpeed Performance Gauge
0%
Add support for mapping exception to types via unions#4492
10 days ago
fb74bb0
2026-06-28-add-generic-exception-handlers
CodSpeed Performance Gauge
0%
Require release URL in social copy#4513
4 hours ago
293cd4e
codex/require-release-link-social-copy
CodSpeed Performance Gauge
0%
1 day ago
7535bb5
DoctorJohn:sync-graphql-over-http-spec-tests
© 2026 CodSpeed Technology
Home Terms Privacy Docs