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

ns-openapi-3-1: allow normalization refractor plugins to work on scoped ApiDOM trees #4134

Closed
char0n opened this issue May 23, 2024 · 1 comment
Assignees
Labels

Comments

@char0n
Copy link
Member

char0n commented May 23, 2024

Prelude

We have an issue with normalization during partial dereference in swagger-client. How it works currently is that the undereferenced definition gets normalized and then partially dereferenced. $$normalized flag is set on the dereferenced structure. This means that whatever got dereferencedd during dereferencing phase, will not be normalized. This creates various side effects and inconsistencies in derefencing. End use of SwaggerUI or SwaggerClient must not expected that anything that is referenced will get normalized.

More info in swagger-api/swagger-js#1396 (comment)


Optimization

Implementation aligned above will require additional traversal pass. The moment all the plugins are idempotent, we can try incorporating them into dereference traversal.

@char0n char0n self-assigned this May 23, 2024
@char0n char0n added enhancement New feature or request OpenAPI 3.1 ApiDOM labels May 23, 2024
@char0n
Copy link
Member Author

char0n commented May 29, 2024

All normalize refractor plugins have been made idempotent.

@char0n char0n closed this as completed May 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant