René's URL Explorer Experiment


Title: fix: handle tags like debian/2%2.6-21 as identifiers by emanueleaina · Pull Request #1336 · python-gitlab/python-gitlab · GitHub

Open Graph Title: fix: handle tags like debian/2%2.6-21 as identifiers by emanueleaina · Pull Request #1336 · python-gitlab/python-gitlab

X Title: fix: handle tags like debian/2%2.6-21 as identifiers by emanueleaina · Pull Request #1336 · python-gitlab/python-gitlab

Description: Git refnames are relatively free-form and can contain all sort for special characters, not just / and #, see http://git-scm.com/docs/git-check-ref-format In particular, Debian's DEP-14 standard for storing packaging in git repositories mandates the use of the % character in tags in some cases like debian/2%2.6-21. Unfortunately python-gitlab currently only escapes / to / and in some cases # to #. This means that when using the commit API to retrieve information about the debian/2%2.6-21 tag only the slash is escaped before being inserted in the URL path and the % is left untouched, resulting in something like /api/v4/projects/123/repository/commits/debian/2%2.6-21. When urllib3 sees that, it detects the invalid % escape and then urlencodes the whole string, resulting in /api/v4/projects/123/repository/commits/debian%2F2%2.6-21, where the original / got escaped twice and produced %2F. To avoid the issue, fully urlencode identifiers and parameters to avoid the urllib3 auto-escaping in all cases. I've run the unit tests but not the integration ones, so in theory this does not break anything but I can't really confirm it. All I can firmly say is that it fixes the issue I hit. :D

Open Graph Description: Git refnames are relatively free-form and can contain all sort for special characters, not just / and #, see http://git-scm.com/docs/git-check-ref-format In particular, Debian's DEP-14 standard...

X Description: Git refnames are relatively free-form and can contain all sort for special characters, not just / and #, see http://git-scm.com/docs/git-check-ref-format In particular, Debian's DEP-14 stan...

Opengraph URL: https://github.com/python-gitlab/python-gitlab/pull/1336

X: @github

direct link

Domain: github.com

route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:f80e7217-cd3e-b34d-f2a1-f7930a05b007
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-id9910:16BB7B:168F61C:1EE0FEF:69733E61
html-safe-nonce908161cefbd3a4ab174c3797946120c0e7be0f9341ed6a4991df119a22065033
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5OTEwOjE2QkI3QjoxNjhGNjFDOjFFRTBGRUY6Njk3MzNFNjEiLCJ2aXNpdG9yX2lkIjoiNzUyOTI3MzYyNTI0NTA3Mjk5MyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac1bc30898d0df2668adc2067074f592ac538bd5bd1fc98fa3a328b47719d42bd4
hovercard-subject-tagpull_request:580713832
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/python-gitlab/python-gitlab/pull/1336/files
twitter:imagehttps://avatars.githubusercontent.com/u/145522?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/145522?s=400&v=4
og:image:altGit refnames are relatively free-form and can contain all sort for special characters, not just / and #, see http://git-scm.com/docs/git-check-ref-format In particular, Debian's DEP-14 standard...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None574266c5e0389fb19fcea86ddb6d5b0008f148ada57d7a37ec4c90a19caee8f6
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/python-gitlab/python-gitlab git https://github.com/python-gitlab/python-gitlab.git
octolytics-dimension-user_id28886265
octolytics-dimension-user_loginpython-gitlab
octolytics-dimension-repository_id8077625
octolytics-dimension-repository_nwopython-gitlab/python-gitlab
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id8077625
octolytics-dimension-repository_network_root_nwopython-gitlab/python-gitlab
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release3c64ddf9c1ec6ebf99c7b6faf0c61676d36f64c0
ui-targetcanary-1
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/python-gitlab/python-gitlab/pull/1336/files#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython-gitlab%2Fpython-gitlab%2Fpull%2F1336%2Ffiles
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub SparkBuild and deploy intelligent appshttps://github.com/features/spark
GitHub ModelsManage and compare promptshttps://github.com/features/models
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython-gitlab%2Fpython-gitlab%2Fpull%2F1336%2Ffiles
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=python-gitlab%2Fpython-gitlab
Reloadhttps://github.com/python-gitlab/python-gitlab/pull/1336/files
Reloadhttps://github.com/python-gitlab/python-gitlab/pull/1336/files
Reloadhttps://github.com/python-gitlab/python-gitlab/pull/1336/files
python-gitlab https://github.com/python-gitlab
python-gitlabhttps://github.com/python-gitlab/python-gitlab
Notifications https://github.com/login?return_to=%2Fpython-gitlab%2Fpython-gitlab
Fork 675 https://github.com/login?return_to=%2Fpython-gitlab%2Fpython-gitlab
Star 2.4k https://github.com/login?return_to=%2Fpython-gitlab%2Fpython-gitlab
Code https://github.com/python-gitlab/python-gitlab
Issues 26 https://github.com/python-gitlab/python-gitlab/issues
Pull requests 12 https://github.com/python-gitlab/python-gitlab/pulls
Discussions https://github.com/python-gitlab/python-gitlab/discussions
Actions https://github.com/python-gitlab/python-gitlab/actions
Projects 0 https://github.com/python-gitlab/python-gitlab/projects
Security 0 https://github.com/python-gitlab/python-gitlab/security
Insights https://github.com/python-gitlab/python-gitlab/pulse
Code https://github.com/python-gitlab/python-gitlab
Issues https://github.com/python-gitlab/python-gitlab/issues
Pull requests https://github.com/python-gitlab/python-gitlab/pulls
Discussions https://github.com/python-gitlab/python-gitlab/discussions
Actions https://github.com/python-gitlab/python-gitlab/actions
Projects https://github.com/python-gitlab/python-gitlab/projects
Security https://github.com/python-gitlab/python-gitlab/security
Insights https://github.com/python-gitlab/python-gitlab/pulse
Sign up for GitHub https://github.com/signup?return_to=%2Fpython-gitlab%2Fpython-gitlab%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2Fpython-gitlab%2Fpython-gitlab%2Fissues%2Fnew%2Fchoose
nejchhttps://github.com/nejch
python-gitlab:masterhttps://github.com/python-gitlab/python-gitlab/tree/master
emanueleaina:fix/quote-everythinghttps://github.com/emanueleaina/python-gitlab/tree/fix/quote-everything
Conversation 5 https://github.com/python-gitlab/python-gitlab/pull/1336
Commits 1 https://github.com/python-gitlab/python-gitlab/pull/1336/commits
Checks 0 https://github.com/python-gitlab/python-gitlab/pull/1336/checks
Files changed https://github.com/python-gitlab/python-gitlab/pull/1336/files
Please reload this pagehttps://github.com/python-gitlab/python-gitlab/pull/1336/files
fix: handle tags like debian/2%2.6-21 as identifiers https://github.com/python-gitlab/python-gitlab/pull/1336/files#top
Show all changes 1 commit https://github.com/python-gitlab/python-gitlab/pull/1336/files
b4dac5c fix: handle tags like debian/2%2.6-21 as identifiers emanueleaina Feb 25, 2021 https://github.com/python-gitlab/python-gitlab/pull/1336/commits/b4dac5ce33843cf52badeb9faf0f7f52f20a9a6a
Clear filters https://github.com/python-gitlab/python-gitlab/pull/1336/files
Please reload this pagehttps://github.com/python-gitlab/python-gitlab/pull/1336/files
Please reload this pagehttps://github.com/python-gitlab/python-gitlab/pull/1336/files
test_utils.py https://github.com/python-gitlab/python-gitlab/pull/1336/files#diff-89d3cb43c8b9c0d63b75a7e17772b8b7e7d098a64af14c7c3f8bc4d9cf6bd6c7
utils.py https://github.com/python-gitlab/python-gitlab/pull/1336/files#diff-f8491e1894d267d0ea4bcd44eaf0e9313e2cd3d7a7a2a32bcbbb0dcba902b25e
gitlab/tests/test_utils.pyhttps://github.com/python-gitlab/python-gitlab/pull/1336/files#diff-89d3cb43c8b9c0d63b75a7e17772b8b7e7d098a64af14c7c3f8bc4d9cf6bd6c7
View file https://github.com/emanueleaina/python-gitlab/blob/b4dac5ce33843cf52badeb9faf0f7f52f20a9a6a/gitlab/tests/test_utils.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/python-gitlab/python-gitlab/pull/1336/{{ revealButtonHref }}
https://github.com/python-gitlab/python-gitlab/pull/1336/files#diff-89d3cb43c8b9c0d63b75a7e17772b8b7e7d098a64af14c7c3f8bc4d9cf6bd6c7
https://github.com/python-gitlab/python-gitlab/pull/1336/files#diff-89d3cb43c8b9c0d63b75a7e17772b8b7e7d098a64af14c7c3f8bc4d9cf6bd6c7
https://github.com/python-gitlab/python-gitlab/pull/1336/files#diff-89d3cb43c8b9c0d63b75a7e17772b8b7e7d098a64af14c7c3f8bc4d9cf6bd6c7
gitlab/utils.pyhttps://github.com/python-gitlab/python-gitlab/pull/1336/files#diff-f8491e1894d267d0ea4bcd44eaf0e9313e2cd3d7a7a2a32bcbbb0dcba902b25e
View file https://github.com/emanueleaina/python-gitlab/blob/b4dac5ce33843cf52badeb9faf0f7f52f20a9a6a/gitlab/utils.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/python-gitlab/python-gitlab/pull/1336/{{ revealButtonHref }}
https://github.com/python-gitlab/python-gitlab/pull/1336/files#diff-f8491e1894d267d0ea4bcd44eaf0e9313e2cd3d7a7a2a32bcbbb0dcba902b25e
https://github.com/python-gitlab/python-gitlab/pull/1336/files#diff-f8491e1894d267d0ea4bcd44eaf0e9313e2cd3d7a7a2a32bcbbb0dcba902b25e
https://github.com/python-gitlab/python-gitlab/pull/1336/files#diff-f8491e1894d267d0ea4bcd44eaf0e9313e2cd3d7a7a2a32bcbbb0dcba902b25e
https://github.com/python-gitlab/python-gitlab/pull/1336/files#diff-f8491e1894d267d0ea4bcd44eaf0e9313e2cd3d7a7a2a32bcbbb0dcba902b25e
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.