-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
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
Generic dataclass detection fails for unions #7
Comments
Wow thanks so much for the lightning-quick patch :) |
oops, seems it was too fast and the CI is broken :) looking into it... |
Actually, everything seems to be in order; just had a typo in a test + an outdated version of Appreciate the issue report + reproduction instructions! As an FYI I am thinking of deprecating the API though, I can think of a couple other issues and the benefit over just using PyYAML seems fairly incremental. Will file a separate issue. |
Thanks, appreciate the heads-up! I wanted to file an issue in case the |
Sounds good! If you haven't considered it, I'd recommend also looking into serializing with PyYAML + the standard |
Hi Brent,
I have a very low-level bug to flag for you -- when saving/loading nested dataclasses to yaml (using
extras.to_yaml()
,extras.from_yaml()
, if a dataclass has a Union of two custom types, they don't get detected as custom types for theyaml.Loader
to construct.I wrote a MWE to replicate the issue:
No worries if this is too low-level to deal with right now -- I think we can work around it by just pickling the configs, but wanted to flag something is going awry in the custom type detection.
The text was updated successfully, but these errors were encountered: