We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pyright flags the code below with "Type of "make_converter" is partially unknown".
converter = cattrs.preconf.json.make_converter()
The problem is the type of the parameter unstruct_collection_overrides: Mapping[type, (...) -> Unknown].
Poking around in the cattrs code, this error can be resolved by changing the type of unstruct_collection_overrides in Converter.Init from
unstruct_collection_overrides: Mapping[type, Callable] = {}
to unstruct_collection_overrides: Mapping[type, UnstructureHookT] = {}
unstruct_collection_overrides: Mapping[type, UnstructureHookT] = {}
The text was updated successfully, but these errors were encountered:
Interesting. Care to submit a pr?
Sorry, something went wrong.
I can do that.
Pull request #594 submitted.
No branches or pull requests
Pyright flags the code below with "Type of "make_converter" is partially unknown".
The problem is the type of the parameter unstruct_collection_overrides: Mapping[type, (...) -> Unknown].
Poking around in the cattrs code, this error can be resolved by changing the type of unstruct_collection_overrides in Converter.Init from
unstruct_collection_overrides: Mapping[type, Callable] = {}
to
unstruct_collection_overrides: Mapping[type, UnstructureHookT] = {}
The text was updated successfully, but these errors were encountered: