APIDevTools / json-schema-ref-parser

Parse, Resolve, and Dereference JSON Schema $ref pointers in Node and browsers
https://apitools.dev/json-schema-ref-parser
MIT License
957 stars 228 forks source link

Handle direct external circular references #169

Closed P0lip closed 4 years ago

P0lip commented 4 years ago

Should fix_ https://github.com/APIDevTools/json-schema-ref-parser/issues/180

Currently json-schema-ref-parser fails to process the document and errors out. image

I'm not fully convinced about the fix though, think there might be some slightly nicer way to accomplish the same result?

philsturgeon commented 4 years ago

@P0lip what's got you feeling down about this one?

P0lip commented 4 years ago

@philsturgeon reliance on pathFromRoot.

iamkenos commented 4 years ago

hi folks, any chance of this getting merged soon?

JamesMessinger commented 4 years ago

As long as all the tests pass, I'm fine with merging it. @P0lip, what do you say? Want to merge it?

P0lip commented 4 years ago

@P0lip, what do you say? Want to merge it?

Yeah, I think we can merge this. We've used this code for quite some time in production at Stoplight and it works just fine.