Skip to content

Referenced schemas don't seem to be using base URL? #773

@jstafford5380

Description

@jstafford5380

Summary

Schemas don't seem to follow child references relative to parent reference base uri

Relevant information

I have a as schema that has some properties referencing other schemas via $ref using a relative path. But the document I'm trying to validate is returning an error stating that schema could not be loaded and the path that it shows seems to be relative to root, not relative to the first schema. For example

  • Doc uses $schema=c:\user\me\docs\foo.schema.json
  • foo.schema.json has a property reference "$ref": "bar.schema.json"
  • Doc shows a validation error 'Problems loading reference 'file:///bar.schema.json': Unable to load schema from \bar.schema.json`: No content.

The schema files are co-located; same directory.

I'm not sure if I'm doing something wrong or if it's not supported or a bug or what

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions