You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Changing this without deprecation is backwards incompatible, so we
re-introduce a warning.
This only applies if you have not configured neither a Registry nor a legacy
RefResolver. Both of the former 2 cases already have 'correct' behavior (the
former will not automatically retrieve references and is not backwards
incompatible as it is a new API, and the latter will do so but is already
fully deprecated by this release).
Cloess: #1089
Copy file name to clipboardExpand all lines: CHANGELOG.rst
+4Lines changed: 4 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -9,6 +9,9 @@ It does so in a way that *should* be backwards compatible, preserving old behavi
9
9
This change is a culmination of a meaningful chunk of work to make ``$ref`` resolution more flexible and more correct.
10
10
Backwards compatibility *should* be preserved for existing code which uses ``RefResolver``, though doing so is again now deprecated, and all such use cases should be doable using the new APIs.
11
11
Please file issues on the ``referencing`` tracker if there is functionality missing from it, or here on the ``jsonschema`` issue tracker if you have issues with existing code not functioning the same, or with figuring out how to change it to use ``referencing``.
12
+
In particular, this referencing change includes a change concerning *automatic* retrieval of remote references (retrieving ``http://foo/bar`` automatically within a schema).
13
+
This behavior has always been a potential security risk and counter to the recommendations of the JSON Schema specifications; it has survived this long essentially only for backwards compatibility reasons, and now explicitly produces warnings.
14
+
The ``referencing`` library itself will *not* automatically retrieve references if you interact directly with it, so the deprecated behavior is only triggered if you fully rely on the default ``$ref`` resolution behavior and also include remote references in your schema, which will still be retrieved during the deprecation period (after which they will become an error).
12
15
* Support for Python 3.7 has been dropped, as it is nearing end-of-life.
13
16
This should not be a "visible" change in the sense that ``requires-python`` has been updated, so users using 3.7 should still receive ``v4.17.3`` when installing the library.
14
17
* On draft 2019-09, ``unevaluatedItems`` now properly does *not* consider items to be evaluated by an ``additionalItems`` schema if ``items`` is missing from the schema, as the specification says in this case that ``additionalItems`` must be completely ignored.
@@ -20,6 +23,7 @@ Deprecations
20
23
21
24
* ``jsonschema.RefResolver`` -- see above for details on the replacement
22
25
* ``jsonschema.RefResolutionError`` -- see above for details on the replacement
26
+
* relying on automatic resolution of remote references -- see above for details on the replacement
23
27
* importing ``jsonschema.ErrorTree`` -- instead import it via ``jsonschema.exceptions.ErrorTree``
24
28
* importing ``jsonschema.FormatError`` -- instead import it via ``jsonschema.exceptions.FormatError``
0 commit comments