-
Notifications
You must be signed in to change notification settings - Fork 9k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
OpenAPI 3.1.0 support: "No parameters" with Path parameters and OAS 3.1.0 #8971
Labels
Comments
This is still an issue in 5.6.2 unfortunately. |
After the 5.4.1 version release the path parameters are not coming up at all even after refreshing the swagger UI with the endpoint selected. There is just a glimpse of path parameters on refresh and after that they vanish. |
char0n
changed the title
"No parameters" with Path parameters and OAS 3.1.0
OpenAPI 3.1.0 support: "No parameters" with Path parameters and OAS 3.1.0
Nov 13, 2023
10 tasks
Thanks to @jux, this has been addressed in https://github.com/swagger-api/swagger-js/releases/tag/v3.24.6. |
char0n
added a commit
that referenced
this issue
Dec 14, 2023
Addressed in #9426 |
char0n
added a commit
that referenced
this issue
Dec 14, 2023
# for free
to join this conversation on GitHub.
Already have an account?
# to comment
Q&A (please complete the following information)
This is a regression in the recent 5.1.0 release. The bug does not exist in 5.0.0.
curl -L https://github.com/swagger-api/swagger-ui/archive/refs/tags/v5.1.0.tar.gz | tar xzf -
Content & configuration
Example Swagger/OpenAPI definition:
Swagger-UI configuration options:
Describe the bug you're encountering
As you can see it says "No parameters" in Swagger UI. However, as you can also see, there is a parameter in the openapi document.
To reproduce...
Steps to reproduce the behavior:
rm -fr swagger-ui-5.1.0
curl -L https://github.com/swagger-api/swagger-ui/archive/refs/tags/v5.1.0.tar.gz | tar xzf -
echo '{"openapi":"3.1.0","paths":{"/pet/{petId}":{"parameters":[{"name":"petId","in":"path","schema":{"type":"integer","format":"int64"}}],"get":{"summary":"FindpetbyID"}}}}' > swagger-ui-5.1.0/dist/petstore3.json
sed -i 's|https://petstore.swagger.io/v2/swagger.json|petstore3.json|' swagger-ui-5.1.0/dist/swagger-initializer.js
http://...../swagger-ui-5.1.0/dist/
in your web browserExpected behavior
I expect to see the petId parameter.
Additional context or thoughts
My openapi document differs from the vanilla petstore sample in that I have hoisted "parameters" from the GET Operation into its parent Path.
I have discovered 4 different workarounds:
#/default/get_pet__petId_
. Suddenly there are parameters!The text was updated successfully, but these errors were encountered: