{"thread":{"id":"65257","subject":"[GSoC] microproject idea: improve corrupt patch location reporting in git am","startedAt":"2026-03-15T22:44:39Z","lastAt":"2026-03-16T11:17:26Z","messageCount":2,"participants":["Jerry Wang","Karthik Nayak"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"539052","messageId":"CAKWWG_nGhD6vqhAS1mkEwBQPrg_YX0+C3-xW=Q3ifFDw4dDviw@mail.gmail.com","threadId":"65257","inReplyTo":null,"subject":"[GSoC] microproject idea: improve corrupt patch location reporting in git am","fromName":"Jerry Wang","fromEmail":"jerrywang1201@gmail.com","sentAt":"2026-03-15T22:44:27Z","receivedAt":"2026-03-15T22:44:39Z","isPatch":false,"sender":{"key":"jerrywang1201@gmail.com","avatar":null},"body":"Hi,\n\nMy name is Jialong Wang, and I plan to apply to Git for GSoC 2026.\n\nI have been reading the Git contribution documentation, including\nDocumentation/CodingGuidelines, Documentation/SubmittingPatches, and\nDocumentation/MyFirstContribution.txt. I have also built Git from\nsource locally and started looking for a small microproject.\n\nI found an older open issue that still seems reproducible on my setup:\n\nwhen git am encounters a corrupt patch, it reports \"corrupt patch at\nline <n>\", but that line number does not correspond to the original\nmail/mbox as the user sees it.\n\nRelated discussion I found:\n  - bug report from 2019-10-02:\n    https://public-inbox.org/git/20191002184546.GA22174@generichostname/\n  - follow-up patch from 2019-10-04:\n    https://public-inbox.org/git/ec38908d05f0d40190173158ef3f0753fa9f1184.1570226253.git.liu.denton@gmail.com/\n  - GitGitGadget issue #374:\n    https://github.com/gitgitgadget/git/issues/374\n\nI also saw review feedback mentioning additional test coverage for\ncases such as stdin input and running from a subdirectory.\n\nI reproduced the issue locally with Git 2.51.0 on 2026-03-15, and I am\nconsidering working on a small patch in this area.\n\nBefore I start, I wanted to ask whether this still looks like an\nappropriate microproject for a GSoC applicant, and whether improving\nthe error location/reporting plus adding the missing tests would be a\ngood direction.\n\nThanks,\nJialong\n"},{"id":"539097","messageId":"CAOLa=ZQDNB+4r1s8dD=ZJmfkBMH1Zm8d4=CQjECqvRUGDNJ22g@mail.gmail.com","threadId":"65257","inReplyTo":"CAKWWG_nGhD6vqhAS1mkEwBQPrg_YX0+C3-xW=Q3ifFDw4dDviw@mail.gmail.com","subject":"Re: [GSoC] microproject idea: improve corrupt patch location reporting in git am","fromName":"Karthik Nayak","fromEmail":"karthik.188@gmail.com","sentAt":"2026-03-16T11:17:23Z","receivedAt":"2026-03-16T11:17:26Z","isPatch":false,"sender":{"key":"karthik.188@gmail.com","avatar":"https://avatars.githubusercontent.com/u/1786334?v=4"},"body":"Jerry Wang <jerrywang1201@gmail.com> writes:\n\n> Hi,\n>\n> My name is Jialong Wang, and I plan to apply to Git for GSoC 2026.\n>\n> I have been reading the Git contribution documentation, including\n> Documentation/CodingGuidelines, Documentation/SubmittingPatches, and\n> Documentation/MyFirstContribution.txt. I have also built Git from\n> source locally and started looking for a small microproject.\n>\n> I found an older open issue that still seems reproducible on my setup:\n>\n> when git am encounters a corrupt patch, it reports \"corrupt patch at\n> line <n>\", but that line number does not correspond to the original\n> mail/mbox as the user sees it.\n>\n> Related discussion I found:\n>   - bug report from 2019-10-02:\n>     https://public-inbox.org/git/20191002184546.GA22174@generichostname/\n>   - follow-up patch from 2019-10-04:\n>     https://public-inbox.org/git/ec38908d05f0d40190173158ef3f0753fa9f1184.1570226253.git.liu.denton@gmail.com/\n>   - GitGitGadget issue #374:\n>     https://github.com/gitgitgadget/git/issues/374\n>\n> I also saw review feedback mentioning additional test coverage for\n> cases such as stdin input and running from a subdirectory.\n>\n> I reproduced the issue locally with Git 2.51.0 on 2026-03-15, and I am\n> considering working on a small patch in this area.\n>\n> Before I start, I wanted to ask whether this still looks like an\n> appropriate microproject for a GSoC applicant, and whether improving\n> the error location/reporting plus adding the missing tests would be a\n> good direction.\n>\n> Thanks,\n> Jialong\n\nI see that you already sent in a patch. For what its worth, the General\ninformation page also covers how to approach microprojects [1].\n\nThat said, this is a good microproject. It doesn't touch too many files,\nis not too complex and gives you a good starting point with the mailing\nlist.\n\n[1]: https://git.github.io/General-Microproject-Information/\n\nRegards,\nKarthik\n"}]}