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
api: swagger: Adjust ContainerWaitResponse error as optional #43656
api: swagger: Adjust ContainerWaitResponse error as optional #43656
Conversation
hm, interesting, so I recall I added the required to make the generated type match the existing one. In this commit, the type that was moved, already had "Required: true" in the generated Go code; e4c6ca3 Wondering if that was a quirk in the generator that's used in this repository 🤔 |
Looks indeed that the generated type differs with this patch (perhaps it's ok to change though);
|
To be clear, I see the field exists but is set to There is perhaps a case to look into using the |
Yes, to be honest; at times it's a bit tricky to pick the most suitable option in swagger, as not all of them are a "perfect fit" for the go types (combinations of "nullable" fields, "omit empty", etc). I think the change shown in the diff above (at least at a glance) looks still OK, and I don't expect that change to be causing issues from our side (or at least, i'd expect the client to unmarshal both the "before" and "after" identical), so to unblock this PR, I'd suggest to;
Last one gives us a bit more flexibility to decide if we want to backport only the "documentation" changes or both the documentation and code changes to the "20.10" release branch (which is the branch that's also used for the documentation at docs.docker.com) |
Signed-off-by: Niel Drummond <niel@drummond.lu>
Signed-off-by: Niel Drummond <niel@drummond.lu>
16abf74
to
152467d
Compare
I've regenerated the types with the provided make command and split the commits. Let me know if there's anything outstanding.. |
1 similar comment
I've regenerated the types with the provided make command and split the commits. Let me know if there's anything outstanding.. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks!
CI failure is unrelated; I kicked the Windows CI once more, but this should be ready to merge 👍
|
alright; good to go; thanks! |
- What I did
Removed the
required
API swagger flag on theContainerWaitResponse
typeError
property- How I did it
Amended API 1.39, 1.40, 1.41 and the future swagger for 1.42 YAML description to remove the
required
flag- How to verify it
Generated types for the Bollard docker client and ran integration tests on the new types.
- Description for the changelog
Removed the
required
field in the swagger documentation for theContainerWaitResponse
Error
property.fixes #43655
- A picture of a cute animal (not mandatory but encouraged)