Skip to content

Conversation

TimWolla
Copy link
Member

This is a follow-up for #19779 which updated the error messages for the non-syntax errors, but did not update the exception class, still implying it's related to invalid URIs.

Given that we don't know ourselves if these are reachable in practice, they are cannot be meaningfully handled by a user of PHP. Thus this should be a Error according to our exception policy.

This is a follow-up for php#19779 which updated the error *messages*
for the non-syntax errors, but did not update the exception class, still
implying it's related to invalid URIs.

Given that we don't know ourselves if these are reachable in practice, they are
cannot be meaningfully handled by a user of PHP. Thus this should be a `Error`
according to our exception policy.
@TimWolla TimWolla changed the title uri: Throw UriError for unexpected failures in uri_parser_rfc3986 uri: Throw UriError for unexpected failures Sep 15, 2025
@alexandre-daubois
Copy link
Member

Should the NEWS file be updated as a new error class is introduced?

@TimWolla
Copy link
Member Author

Should the NEWS file be updated as a new error class is introduced?

Yes. I generally only update NEWS after review when it's clear which changes will happen and in which version they'll land to avoid merge conflicts.

Copy link
Member

@edorian edorian left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

RM approval 👍

@TimWolla TimWolla merged commit fe0263f into php:master Sep 17, 2025
9 checks passed
@TimWolla TimWolla deleted the uri-error branch September 17, 2025 17:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants