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

[5.0.0-rc0] The ToSchema :: bound macro attributes is currently missing #1109

Closed
irevoire opened this issue Oct 9, 2024 · 2 comments
Closed

Comments

@irevoire
Copy link

irevoire commented Oct 9, 2024

Hello,

I’m trying to use the latest version of utoipa on a generic structure, and the documentation is a bit vague but links to a good example: https://github.com/juhaku/utoipa/blob/master/utoipa-gen/tests/schema_generics.rs
Except, when I try to use the bound parameter, it doesn’t work:

error: unexpected attribute: bound, expected any of: example, examples, xml, title, rename_all, max_properties, min_properties, as, default, deprecated, description
   --> meilisearch/src/routes/mod.rs:176:10
    |
176 | #[schema(bound = "T: ToSchema", rename_all = "camelCase")]
    |          ^^^

It looks like this attribute hasn’t been re-implemented in the latest rc

@juhaku
Copy link
Owner

juhaku commented Oct 9, 2024

Yes that attribute has been added in #1079 PR but the rc has been released earlier. If you want to use the bound attribute, you must point the utoipa version to master utoipa = {git = "..." } for time being.

@juhaku
Copy link
Owner

juhaku commented Oct 16, 2024

I guess this can be now closed, as this is already released

@juhaku juhaku closed this as completed Oct 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants