Conversation
|
I just saw that this probably messes with List types. Set to draft for now. |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #669 +/- ##
==========================================
- Coverage 89.16% 89.03% -0.14%
==========================================
Files 39 39
Lines 4746 4761 +15
==========================================
+ Hits 4232 4239 +7
- Misses 514 522 +8 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
sorry for the radio silence here @ndxmrb. This would be a great addition if you want to keep banging at it. I did indeed see the challenge with list types. I wonder whether #663 might have helped the situation here (I haven't had time to look closely, so it's possibly no). @hanjinliu may also have some insights... if you have a moment and want to resolve merge conflicts and see what the state of things look like now, that would be great :) |
|
Sorry for the silence as well @tlambert03. I'm still willing to work on it. I think the latest work here has indeed helped with the list types. But unfortunately, I'm not sure anymore what problem exactly I encountered. Either way, I can now use a nested pydantic model alongside a list field and validate the resulting dict without any issues. Do you think the I'll update this (or make a new PR, if that's easier) as soon as I know how to go on with that. |
|
Closing in favor of #704. |
Hi @tlambert03,
when using nested pydantic models, I found this post on how to add a simple way of nesting widgets/containers. When trying to use the values, I needed to modify
asdict()as well. Although there might be a reason you didn't just implement it already when answering the post (probably due to #317), I thought I'd make a pull request just in case.Notably, some things are missing:
ValueWidgets andContainerWidgets - as I didn't really know where to startAlso, I tried my best with the types, but I probably don't oversee the grand scheme of things... 😅
I hope it's helpful, but I'm aware it might not be, so feel free to just close 😄
Thanks for having a look!