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
When I use oneOf with Rust-server output I get the following Rust code in my model:
pub targets: Vec<oneOf<PolygonTarget,CircleTarget,AlertTarget>>,
oneOf isn't defined anywhere, and I can't compile.
The text was updated successfully, but these errors were encountered:
I don't think we've added oneOf support to rust-server generator.
oneOf
rust-server
What does the correct code look like?
Sorry, something went wrong.
Oh right ... is that documented somewhere?
When I do the generation it says:
[main] INFO o.o.codegen.DefaultGenerator - Generator 'rust-server' is considered stable.
If it doesn't cover the whole OpenAPI spec I think maybe it should be mentioned there or not listed as stable?
Let me think about the correct code overnight - worst case you'd need an enum per oneOf:
enum oneOfPolygonTargetCircleTargetAlertTarget { PolygonTarget, CircleTarget, AlertTarget }
(with all the Serde magic it needs) Then use that.
No branches or pull requests
Description
When I use oneOf with Rust-server output I get the following Rust code in my model:
pub targets: Vec<oneOf<PolygonTarget,CircleTarget,AlertTarget>>,
oneOf isn't defined anywhere, and I can't compile.
The text was updated successfully, but these errors were encountered: