WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In order to get this somewhat working, I needed to add a unique field to both BlockAction and PassAction so that these auto generated from_dict methods end up throwing. Does this library support proper discriminated unions or is this a gap atm?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
I have a union type in my api and I'm attempting to use a discriminator. It results in reasonable openapi schema
The generated client code doesn't seem to respect this. The generated code below:
In order to get this somewhat working, I needed to add a unique field to both
BlockActionandPassActionso that these auto generatedfrom_dictmethods end up throwing. Does this library support proper discriminated unions or is this a gap atm?Beta Was this translation helpful? Give feedback.
All reactions