René's URL Explorer Experiment


Title: fix(diff): read the index line after a dissimilarity index by JROtto5 · Pull Request #2353 · gitpython-developers/GitPython · GitHub

Open Graph Title: fix(diff): read the index line after a dissimilarity index by JROtto5 · Pull Request #2353 · gitpython-developers/GitPython

X Title: fix(diff): read the index line after a dissimilarity index by JROtto5 · Pull Request #2353 · gitpython-developers/GitPython

Description: I am a Claude (Opus 5.5) agent working through the contributor's account. Continuing the comparison of GitPython's parsers with what a current Git (2.56) prints, this time the patch header in Diff._index_from_patch_format. With B=True (git diff -B), a file that Git reports as rewritten came back with a_blob and b_blob set to None, and with no modes either when the mode had not changed. The same diff without -B has them. Other files in a -B diff are not affected. For a broken pair Git writes dissimilarity index N% between the mode lines and the index line. re_header has no group for that line, and every group after it is optional, so the match ends there and the index line is never read. The hunks are still parsed, so nothing warns. Accept the line, in the place Git writes it, before the index line. Validation on Linux, CPython 3.14.4, Git 2.56.0: The new fixture is real git diff -B --full-index output for two rewritten files, one with a mode change and one without. test_diff_with_dissimilarity_index fails on the original diff.py (a_blob is None) and passes with the change. commit.diff(None, create_patch=True, B=True) on a real repository with the same two files: before, both had no blobs and the unchanged-mode file had no modes; after, both have the right blob ids and modes. Complete test suite with the default backend: 2302 passed, 60 skipped, 1 xfailed. test/test_diff.py also passes (51) with GIT_PYTHON_BACKEND=gix. Ruff check and format pass. Not run: mypy, the complete suite with the gix backend, other platforms and Python versions.

Open Graph Description: I am a Claude (Opus 5.5) agent working through the contributor's account. Continuing the comparison of GitPython's parsers with what a current Git (2.56) prints, this time the patch header ...

X Description: I am a Claude (Opus 5.5) agent working through the contributor's account. Continuing the comparison of GitPython's parsers with what a current Git (2.56) prints, this time the patch...

Opengraph URL: https://github.com/gitpython-developers/GitPython/pull/2353

X: @github

direct link

Domain: github.com

IPv4 address: 140.82.113.3

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:c29fa169-fb62-04da-7d5d-37c70df819aa
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-id99BA:107A1:128FA8F:18AFC7C:6B065CBA
html-safe-nonceba68bee8c3ace4c81c30cd71f02cf078c986b980fb13c31c70adceda87370771
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5OUJBOjEwN0ExOjEyOEZBOEY6MThBRkM3Qzo2QjA2NUNCQSIsInZpc2l0b3JfaWQiOiI2MTgxMzY2Njk5OTg0ODM3ODE4IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmacf842baa806ab2956194d46628630e9e1a152c77bb76e6105ab0393cb2a31ff30
hovercard-subject-tagpull_request:5445050549
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/gitpython-developers/GitPython/pull/2353/files
twitter:imagehttps://avatars.githubusercontent.com/u/222316562?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/222316562?s=400&v=4
og:image:altI am a Claude (Opus 5.5) agent working through the contributor's account. Continuing the comparison of GitPython's parsers with what a current Git (2.56) prints, this time the patch header ...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None6324e6ac990fb6befbec840cc0e102a1071c339bfe8f9826bb12de2e3ba1d297
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/gitpython-developers/GitPython git https://github.com/gitpython-developers/GitPython.git
octolytics-dimension-user_id503709
octolytics-dimension-user_logingitpython-developers
octolytics-dimension-repository_id1126087
octolytics-dimension-repository_nwogitpython-developers/GitPython
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id1126087
octolytics-dimension-repository_network_root_nwogitpython-developers/GitPython
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
release7f0aa75f4141d440c6110dc31af7ea7797abb6c4
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/gitpython-developers/GitPython/pull/2353/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgitpython-developers%2FGitPython%2Fpull%2F2353%2Ffiles
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
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
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://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/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgitpython-developers%2FGitPython%2Fpull%2F2353%2Ffiles
Sign uphttps://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=gitpython-developers%2FGitPython
Reloadhttps://github.com/gitpython-developers/GitPython/pull/2353/files
Reloadhttps://github.com/gitpython-developers/GitPython/pull/2353/files
Reloadhttps://github.com/gitpython-developers/GitPython/pull/2353/files
gitpython-developershttps://github.com/gitpython-developers
GitPythonhttps://github.com/gitpython-developers/GitPython
Codehttps://github.com/gitpython-developers/GitPython
Issues1 (1)https://github.com/gitpython-developers/GitPython/issues
Pull requests1 (1)https://github.com/gitpython-developers/GitPython/pulls
Discussionshttps://github.com/gitpython-developers/GitPython/discussions
Actionshttps://github.com/gitpython-developers/GitPython/actions
Security and quality42 (42)https://github.com/gitpython-developers/GitPython/security
Insightshttps://github.com/gitpython-developers/GitPython/insights
Sign up for GitHub https://github.com/signup?return_to=%2Fgitpython-developers%2FGitPython%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2Fgitpython-developers%2FGitPython%2Fissues%2Fnew%2Fchoose
Byronhttps://github.com/Byron
gitpython-developers:mainhttps://github.com/gitpython-developers/GitPython/tree/main
JROtto5:fix/diff-dissimilarity-indexhttps://github.com/JROtto5/GitPython/tree/fix/diff-dissimilarity-index
Conversation 0 https://github.com/gitpython-developers/GitPython/pull/2353
Commits 1 https://github.com/gitpython-developers/GitPython/pull/2353/commits
Checks 64 https://github.com/gitpython-developers/GitPython/pull/2353/checks
Files changed 3 https://github.com/gitpython-developers/GitPython/pull/2353/files
fix(diff): read the index line after a dissimilarity index https://github.com/gitpython-developers/GitPython/pull/2353/files#top
Show all changes 1 commit https://github.com/gitpython-developers/GitPython/pull/2353/files
5ffee6c fix(diff): read the index line after a dissimilarity index JROtto5 Nov 22, 2026 https://github.com/gitpython-developers/GitPython/pull/2353/commits/5ffee6c00aea4faad42622932f6f6e4fc6c22621
Clear filters https://github.com/gitpython-developers/GitPython/pull/2353/files
Please reload this pagehttps://github.com/gitpython-developers/GitPython/pull/2353/files
Please reload this pagehttps://github.com/gitpython-developers/GitPython/pull/2353/files
diff.py https://github.com/gitpython-developers/GitPython/pull/2353/files#diff-300633890a1b325dfed86bb5120d89465f0687f4f6b8d5701c44c02f0eee723a
diff_dissimilarity_mode https://github.com/gitpython-developers/GitPython/pull/2353/files#diff-dcf824908950fdcd5a2f80023e2ed7ab6f094e1beba34e013ee0501e8c126539
test_diff.py https://github.com/gitpython-developers/GitPython/pull/2353/files#diff-a4c794e0849bb401148549f5efcaa756477ae6f7c2976d2ebf7cb56ff7850139
git/diff.pyhttps://github.com/gitpython-developers/GitPython/pull/2353/files#diff-300633890a1b325dfed86bb5120d89465f0687f4f6b8d5701c44c02f0eee723a
View file https://github.com/JROtto5/GitPython/blob/5ffee6c00aea4faad42622932f6f6e4fc6c22621/git/diff.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/gitpython-developers/GitPython/pull/2353/{{ revealButtonHref }}
https://github.com/gitpython-developers/GitPython/pull/2353/files#diff-300633890a1b325dfed86bb5120d89465f0687f4f6b8d5701c44c02f0eee723a
https://github.com/gitpython-developers/GitPython/pull/2353/files#diff-300633890a1b325dfed86bb5120d89465f0687f4f6b8d5701c44c02f0eee723a
test/fixtures/diff_dissimilarity_modehttps://github.com/gitpython-developers/GitPython/pull/2353/files#diff-dcf824908950fdcd5a2f80023e2ed7ab6f094e1beba34e013ee0501e8c126539
View file https://github.com/JROtto5/GitPython/blob/5ffee6c00aea4faad42622932f6f6e4fc6c22621/test/fixtures/diff_dissimilarity_mode
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/gitpython-developers/GitPython/pull/2353/{{ revealButtonHref }}
test/test_diff.pyhttps://github.com/gitpython-developers/GitPython/pull/2353/files#diff-a4c794e0849bb401148549f5efcaa756477ae6f7c2976d2ebf7cb56ff7850139
View file https://github.com/JROtto5/GitPython/blob/5ffee6c00aea4faad42622932f6f6e4fc6c22621/test/test_diff.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/gitpython-developers/GitPython/pull/2353/{{ revealButtonHref }}
https://github.com/gitpython-developers/GitPython/pull/2353/files#diff-a4c794e0849bb401148549f5efcaa756477ae6f7c2976d2ebf7cb56ff7850139
https://github.com/gitpython-developers/GitPython/pull/2353/files#diff-a4c794e0849bb401148549f5efcaa756477ae6f7c2976d2ebf7cb56ff7850139
Please reload this pagehttps://github.com/gitpython-developers/GitPython/pull/2353/files
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

Response headers:
Servergithub.com
Content-Typetext/html; charset=utf-8
Cache-Controlno-cache

Viewport: width=device-width


URLs of crawlers that visited me.