OpenAPITools / OpenAPITools/openapi-diff

Reference resolved against wrong components.

Open
#139 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

I have two APIs, Old and New say. In Old there's a reference to a schema S that generates an error in the RefPointer class when it tries to resolve the reference, even though the API defines this schema.. But in API New there is no such schema. When I add some debug code to RefPointer::resolveRef I see that it's trying to resolve the reference in Old with the schemas from New, which explains why it can't resolve it. So are there two separate environments, one for each API, and somewhere it's just using the wrong one? Before I start tracking down the problem further I just wanted to check how this is supposed to work.

Thanks

Kevin

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 at RefPointer::resolveRef and trace how the Old and New API specifications provide schemas during reference resolution. Reproduce the case with schema S defined only in Old and compare the environments used for both APIs. Done means each reference is resolved against the correct API's schemas, with coverage for this two-API scenario.

Written by the indexing model from the issue text.

Assessment

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.