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

fix: Valid URLs failing validation - query and fragment parts #297

Merged
merged 3 commits into from
Sep 17, 2023

Conversation

danherbriley
Copy link
Contributor

@danherbriley danherbriley commented Sep 12, 2023

  • Adds strict_query (default value is True) flag to url validation,
    functional urls with weird query parts should now pass with strict_query=False
  • The fragment part of an url can now contain /
  • Added a few tests

Related Items

Issues

Thanks to @joe733 for the proposed changes!

src/validators/url.py Outdated Show resolved Hide resolved
@yozachar yozachar self-assigned this Sep 17, 2023
@yozachar yozachar added review PR: Can be reviewed maintenance PR: Alters existing source code bugfix PR: Bug is fixed labels Sep 17, 2023
@yozachar
Copy link
Collaborator

@danherbriley thanks for the PR!

@yozachar yozachar added maintenance PR: Alters existing source code and removed review PR: Can be reviewed maintenance PR: Alters existing source code labels Sep 17, 2023
@yozachar yozachar merged commit 960b48b into python-validators:master Sep 17, 2023
14 checks passed
@danherbriley danherbriley deleted the fix/strict_query branch September 17, 2023 18:39
@yozachar yozachar linked an issue Sep 18, 2023 that may be closed by this pull request
gregtyler added a commit to ministryofjustice/opg-data that referenced this pull request Nov 28, 2023
v0.21 introduced a breaking change to validating queries. This [has been fixed](python-validators/validators#297) but the fix hasn't been released in a version yet so for now we need to lock to v0.20.0
gregtyler added a commit to ministryofjustice/opg-data that referenced this pull request Nov 28, 2023
* Create LICENSE

* Pin validators to 0.20.0

v0.21 introduced a breaking change to validating queries. This [has been fixed](python-validators/validators#297) but the fix hasn't been released in a version yet so for now we need to lock to v0.20.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix PR: Bug is fixed maintenance PR: Alters existing source code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

url raising validation error on a valid url Valid URLs failing validation - query and fragment parts
2 participants