OpenAPITools / OpenAPITools/openapi-diff

false positive for type if only the format is changed.

Open
#248 2 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
1.1k
Forks
190
PR merge metrics
No merged PRs in 30d

Description

i changed the format of a string property.
e.g. when generated out of java and the propery is now mapped via Spring from a String to a UUID.

Perhaps it's correct to report a change. but the change is not on the type but on the format.
and therefore userUid (string -> string) does not help.

old

"ServicePageInteractionRequest":{
   "type":"object",
   "properties":{
      "userUid":{
         "type":"string"
      },
      ...
   }
}

new

"ServicePageInteractionRequest" : {
   "type" : "object",
   "properties" : {
      "userUid" : {
         "type" : "string",
         "format" : "uuid",
         "example" : "5412185d-2cf1-46d0-85d3-50bfc93b1122"
       },
      ...
   }
}

report:

Changed property type: userUid (string -> string)

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

No source files or tests are named. Start by tracing the comparison and reporting path that emits “Changed property type,” then reproduce the provided String-to-UUID format change. Done means format-only changes no longer produce a misleading string-to-string type report, with a regression test covering the example.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, openapi
Domain
api
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.