-
Notifications
You must be signed in to change notification settings - Fork 295
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
Uri::__toString()
can yield malformed URIs
#583
Comments
Thanks for the report. I am a little hesitent to change the behaviour here in 1.x or 2.x, but I am planning for 3.x to make some breaking changes to "fix" some spec compatibility issues, and this could be one such fix, if we can agree on a correct behaviour over on the php-http/psr7-integration-tests repo. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
PHP version: 8.2.11
guzzlehttp/psr7: 2.6.1
Description
The
Uri
class is able to parse malformed URIs but this results inUri::__toString()
generating a malformed URI. Attempting to pass that URI back intoUri
will yield aMalformedUriException
.How to reproduce
Line 3 throws a
GuzzleHttp\Psr7\Exception\MalformedUriException
with the following error message:Notice how the colon after the
https
was stripped.The text was updated successfully, but these errors were encountered: