-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
protoc-gen-openapiv2: google.api.field_behavior = REQUIRED
annotates the wrong schema object
#2635
Comments
Hi, thanks for the issue! That definitely looks wrong. If you're interested in helping to contribute a fix, the first step is usually to create a failing test. It looks like with what you've got here that shouldn't be too hard at all. Would you be interested in contributing a fix? CC @ewhauser |
I am looking to contribute to this issue please assign it to me and I kind of know where to change.
|
Thank you @lakshkeswani, I think we usually add tests to |
This was fixed by #2769. Lets reopen if it persists. |
🐛 Bug Report
protoc-gen-openapiv2 offers to mark properties as required based on the
google.api.field_behavior
field option, but it adds the"required": ["<property>"],
annotation to the property itself in addition to adding it to the object containing the property.https://grpc-ecosystem.github.io/grpc-gateway/docs/mapping/customizing_openapi_output/#using-googleapifield_behavior
To Reproduce
Run
protoc-gen-openapiv2
.Expected Output
Actual Output
Your Environment
github.com/grpc-ecosystem/grpc-gateway/v2 v2.10.0
The text was updated successfully, but these errors were encountered: