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

[NO TESTS NEEDED] swagger: add missing schema properties #9117

Conversation

tmds
Copy link
Contributor

@tmds tmds commented Jan 27, 2021

@jwhonce ptal.

@tmds
Copy link
Contributor Author

tmds commented Jan 27, 2021

cc @baude

@zhangguanzhang
Copy link
Collaborator

thanks for contribute, and your commit messages should change to include Sign-off-by $name .. and git push -f

@zhangguanzhang
Copy link
Collaborator

Fixes: #8577

@rhatdan
Copy link
Member

rhatdan commented Jan 27, 2021

Do we need this change in all of the register_*go files?

@tmds tmds force-pushed the swagger_missing_schema_properties branch from ee1f811 to e6b029c Compare January 27, 2021 15:08
@tmds
Copy link
Contributor Author

tmds commented Feb 2, 2021

Do we need this change in all of the register_*go files?

@rhatdan I think this covers all needed cases. Do you have some specific section in mind that still should be patched?

Is this good to merge?

@rhatdan rhatdan changed the title swagger: add missing schema properties [NO TESTS NEEDED] swagger: add missing schema properties Feb 2, 2021
@rhatdan
Copy link
Member

rhatdan commented Feb 2, 2021

Could you repush to see if we get by the smoke test.

@baude
Copy link
Member

baude commented Feb 2, 2021

/approve

@openshift-ci-robot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: baude, tmds

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Feb 2, 2021
@baude
Copy link
Member

baude commented Feb 2, 2021

I think thew NO_TESTS_NEEDED needs to be in the body of your commit message. Speaking of which, can you provide a commit message?

@baude
Copy link
Member

baude commented Feb 2, 2021

LGTM other than my comments about commit messages

@jwhonce
Copy link
Member

jwhonce commented Feb 2, 2021

@tmds Please let me know what tool you are using, or why you need these changes? I'm curious if we need to add that property to all our responses.

@tmds
Copy link
Contributor Author

tmds commented Feb 3, 2021

Please let me know what tool you are using, or why you need these changes?

I'm using a .NET specific tool: https://github.com/RicoSuter/NSwag

Without the schema properties it considers the swagger invalid.
I'm not a swagger expert. Based on the docker swagger, and skimming through the swagger spec, I think the tool is probably right.

I'm curious if we need to add that property to all our responses.

The other responses already include it, for example:

  BadParamError:
    description: Bad parameter in request
    schema:
      properties:
        cause:
          description: API root cause formatted for automated parsing
          example: API root cause
          type: string
          x-go-name: Because
        message:
          description: human error message, formatted for a human to read
          example: human error message
          type: string
          x-go-name: Message
        response:
          description: http response code
          format: int64
          type: integer
          x-go-name: ResponseCode
      type: object

@tmds
Copy link
Contributor Author

tmds commented Feb 16, 2021

Is this good to merge?

@mheon
Copy link
Member

mheon commented Feb 16, 2021

/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. label Feb 16, 2021
@mheon
Copy link
Member

mheon commented Feb 16, 2021

Wait, CI is red
/hold

@openshift-ci-robot openshift-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Feb 16, 2021
@mheon
Copy link
Member

mheon commented Feb 16, 2021

@tmds I think you need a force-push to make the [NO TESTS NEEDED] label work - I recommend changing something trivial (punctuation in a description, maybe) and force-pushing an amended commit

@TomSweeneyRedHat
Copy link
Member

LGTM
assuming happy tests

@rhatdan
Copy link
Member

rhatdan commented Feb 21, 2021

@tmds Could you rebase your PR and repush, so that the tests will notice the [NO TESTS NEEDED] flag and we can get this in.

@tmds tmds force-pushed the swagger_missing_schema_properties branch from e6b029c to bbc86bb Compare February 22, 2021 08:23
@openshift-ci-robot openshift-ci-robot removed the lgtm Indicates that a PR is ready to be merged. label Feb 22, 2021
@tmds
Copy link
Contributor Author

tmds commented Feb 22, 2021

I've rebased.

NO_TESTS_NEEDED

Signed-off-by: Tom Deseyn <[email protected]>
@tmds tmds force-pushed the swagger_missing_schema_properties branch from bbc86bb to a2e1b3e Compare February 22, 2021 08:28
@mheon
Copy link
Member

mheon commented Feb 22, 2021

/lgtm
/hold cancel

@openshift-ci-robot openshift-ci-robot added lgtm Indicates that a PR is ready to be merged. and removed do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. labels Feb 22, 2021
@openshift-merge-robot openshift-merge-robot merged commit cb3af5b into containers:master Feb 22, 2021
@github-actions github-actions bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Sep 23, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 23, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants