RepreZen / KaiZen-OpenAPI-Editor

Eclipse Editor for the Swagger-OpenAPI Description Language
Eclipse Public License 1.0
115 stars 12 forks source link

Error message on external $ref should specify invalid path or JSON Pointer #436

Open tedepstein opened 6 years ago

tedepstein commented 6 years ago

Currently, KZOE provides the same error message on an invalid $ref URL, regardless of whether the problem is with the base URL (i.e. the scheme://domain/path part), the JSON Pointer fragment that follows (i.e. the #/definitions/customer part), or failure to parse the retrieve content.

Invalid Reference - Unable to resolve the reference. The value must be a valid JSON Reference (for external references) or JSON Pointer (for local references), and must resolve to an object of the expected 
 type.

It would be helpful to have differentiated error messages, depending on the cause. There are at least three general categories of failures like this: