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

Don't encode/decode '+' in url auth part #244

Merged
merged 2 commits into from
May 29, 2020
Merged

Don't encode/decode '+' in url auth part #244

merged 2 commits into from
May 29, 2020

Conversation

frostming
Copy link
Member

@frostming frostming commented May 28, 2020

This behaves the same as pip URL parsing. I am not sure what the RFC says, though.
'+' means a space only in a "application/x-www-form-urlencoded" context.

See original issue: pypa/pipenv#4272

@frostming frostming changed the title change to quote w/o plus Don't encode/decode '+' in url auth part May 28, 2020
@@ -132,7 +132,7 @@ def _parse_fragment(self):
extras = self.extras
for q in fragments:
key, _, val = q.partition("=")
val = unquote_plus(val.replace("+", " "))
Copy link
Member Author

Choose a reason for hiding this comment

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

This replacement is not necessary as unquote_plus will handle plus characters.

Copy link
Member

Choose a reason for hiding this comment

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

yeah, i wasn't thinking too hard at the time probably...

@coveralls
Copy link

coveralls commented May 28, 2020

Coverage Status

Coverage remained the same at 65.56% when pulling ac9b288 on bugfix/quote into 9d9ac1c on master.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants