swagger-api / swagger-api/validator-badge

Seeing parsing errors in Swagger UI but not seeing with generated json

Open
#197 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
227
Forks
81
Avg merge
2h 3m
Merged PRs (30d)
1

Description

Hi there,

We are trying to migrate from spring fox to spring doc as the former is no longer compatible with the latest spring boot version ( 2.6.x) and spring doc internally used open API specification ( 3.0.1). So I thought this might be the correct forum to raise the issue.

We have made all the migration changes and everything is working perfectly in my local but when we try to deploy to one of our ec2 instances we are facing the below issue. The swagger validator badge is invalid.

image

And on clicking the Invalid Json symbol we are getting the below error message,

image

I have fetched my swagger JSON file ( from the v3/api-docs) and checked in swagger editor it is not having any parsing errors, it just has a couple of semantic errors ( delete method expecting a request body ) can anyone point me to the reason we are getting it or tell me how to get more details on the issue?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by comparing the Swagger JSON fetched from v3/api-docs on the EC2 instance with the version that passes in Swagger Editor, then inspect how the validator badge parses it. Check whether the reported parsing error is distinct from the noted semantic error about a DELETE request body; done means identifying a reproducible cause or a more detailed validation error.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, openapi, spring, spring-boot
Domain
api
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.