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

[FEATURE] Support jsonschema 4.18.0+ #1755

Open
allanlewis opened this issue Jul 18, 2023 · 4 comments
Open

[FEATURE] Support jsonschema 4.18.0+ #1755

allanlewis opened this issue Jul 18, 2023 · 4 comments
Assignees
Labels
Difficulty: Intermediate Requires some experience Priority: Medium Planned for regular releases Type: Dependency Updating or changing dependencies Type: Feature New functionalities or enhancements

Comments

@allanlewis
Copy link
Contributor

Is your feature request related to a problem? Please describe.

As of v4.18.0, jsonschema emits the following warnings:

DeprecationWarning: jsonschema.exceptions.RefResolutionError is deprecated as of version 4.18.0. If you wish to catch potential reference resolution errors, directly catch referencing.exceptions.Unresolvable.
DeprecationWarning: jsonschema.RefResolver is deprecated as of v4.18.0, in favor of the https://github.com/python-jsonschema/referencing library, which provides more compliant referencing behavior as well as more flexible APIs for customization. A future release will remove RefResolver. Please file a feature request (on referencing) if you are missing an API for the kind of customization you need.

Describe the solution you'd like

It would be good if this package could address these warning before these deprecations turn into removals.

Describe alternatives you've considered

jsonschema could be pinned to older versions, but we would need to support 4.18.x at some point.

Additional context

I have raised a similar issue in hypothesis-jsonschema: python-jsonschema/hypothesis-jsonschema#102

@allanlewis allanlewis added Status: Needs Triage Requires initial assessment to categorize and prioritize Type: Feature New functionalities or enhancements labels Jul 18, 2023
@Stranger6667 Stranger6667 added this to the 3.21 milestone Oct 9, 2023
@Stranger6667 Stranger6667 added Type: Compatibility Compatibility with other tools Priority: Medium Planned for regular releases Difficulty: Intermediate Requires some experience Type: Dependency Updating or changing dependencies and removed Status: Needs Triage Requires initial assessment to categorize and prioritize Type: Compatibility Compatibility with other tools labels Oct 11, 2023
@allanlewis
Copy link
Contributor Author

This doesn't appear to have made it into v3.21 😞

@allanlewis
Copy link
Contributor Author

I see that python-jsonschema/hypothesis-jsonschema#102 appears to have been resolved in 0.23, but this package explicitly limits hypothesis-jsonschema to <0.23 😕

@Stranger6667
Copy link
Member

Originally I wanted to update hypothesis-jsonschema and provide an api to control the generated characters, but later postponed it. Probably, the update itself should be compatible, so maybe a patch version would work

@Stranger6667
Copy link
Member

I am going to postpone it a bit more - as jsonschema moves towards the referencing library, it requires quite more work to properly integrate it. Additionally, I noticed that hypothesis-jsonschema uses some private jsonschema APIs (e.g. _RefResolutionError that is deprecated), so it should be updated too.

But the next release will support hypothesis-jsonschema==0.23, so there are much fewer deprecation warnings.

In any event, I made some progress towards integrating referencing and will focus on it after this release.

@Stranger6667 Stranger6667 modified the milestones: 3.22, 3.23 Nov 30, 2023
@Stranger6667 Stranger6667 modified the milestones: 3.23, 3.24 Dec 29, 2023
@Stranger6667 Stranger6667 removed this from the 3.24 milestone Jan 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Difficulty: Intermediate Requires some experience Priority: Medium Planned for regular releases Type: Dependency Updating or changing dependencies Type: Feature New functionalities or enhancements
Projects
None yet
Development

No branches or pull requests

2 participants