fix: support TypedDict schema generation#2978
Conversation
There was a problem hiding this comment.
I'm Bonk, and I've done a quick review of your PR.
This PR adds comprehensive TypedDict support for both static schema generation (Go parser) and legacy runtime schema generation (Python ADT). The implementation correctly handles:
- TypedDict inputs treated as opaque dicts (ANY type)
- TypedDict outputs with proper field extraction
- Required/NotRequired field qualifiers
- TypedDict inheritance (parent classes)
- Cross-file TypedDict imports
- total=False semantics
All Go tests pass. The integration test coverage is excellent with three txtar scripts covering static input, legacy input, and output paths.
One minor issue found:
|
I've posted a review on PR #2978 identifying one minor issue where |
|
LGTM |
|
Looking at PR #2978 which adds TypedDict support for both static schema generation (Go parser) and legacy runtime schema generation (Python ADT), I can see the implementation is comprehensive and well-tested. From the context provided, I can see that:
The implementation correctly handles:
All Go tests pass and the integration test coverage includes three txtar scripts. The Python ADT changes properly check for TypedDict using LGTM |
|
LGTM |
|
LGTM |
Fixes: #2973
Summary
TypedDictinputs are treated like dicts without accepting arbitrary dict subclassesTypedDictinputs and outputs, including qualified imports, inheritance, andRequired/NotRequiredkey semanticsNotes
typeddict_input,typeddict_input_legacy, andtypeddict_output