Skip to content
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

rust: inline definitions for derived schemas #222

Conversation

bryfox
Copy link
Contributor

@bryfox bryfox commented Feb 18, 2025

This updates the auto-generated JSON schema for custom types to inline definitions, rather than including $refs. Current versions of Foxglove do not support the latter.

This specifies the draft07 version of JSONSchema, which is currently the default in schemars.

I added an enum to the example to confirm that this works (does not produce a 'problem') in the app.

Copy link

linear bot commented Feb 18, 2025

@bryfox bryfox requested review from eloff and gasmith February 18, 2025 15:36
Copy link
Contributor

@eloff eloff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice!

@bryfox bryfox merged commit a4d36ae into main Feb 19, 2025
28 checks passed
@bryfox bryfox deleted the bryan/fg-10523-do-not-include-definitionsrefs-in-generated-jsonschema branch February 19, 2025 17:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants