{"thread":{"id":"56766","subject":"git log displaying wrong account information","startedAt":"2021-10-23T06:01:45Z","lastAt":"2021-10-23T06:21:10Z","messageCount":3,"participants":["Schanzenbach, Martin","Đoàn Trần Công Danh"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"439439","messageId":"9826C830-3680-4AC4-9ADB-5FA45222A15B@posteo.de","threadId":"56766","inReplyTo":null,"subject":"git log displaying wrong account information","fromName":"Schanzenbach, Martin","fromEmail":"mschanzenbach@posteo.de","sentAt":"2021-10-23T05:58:37Z","receivedAt":"2021-10-23T06:01:45Z","isPatch":false,"sender":{"key":"mschanzenbach@posteo.de","avatar":null},"body":"Hello,\n\nthere is some odd behaviour in \"git log\" which affects me in various ways:\nFor some reason, it \"canonicalizes\" the author/commiter information in our repository: https://git.gnunet.org/git/gnunet.git\n5 years ago or so I was using another email address for commits. I have been using a different email address since that.\n\nBut if you clone this repo, and take a look at a recent commit such as be9b998b3369056c7c8fb0ae84fb4e2a064b496c using \"git log\", you will see that my email address is actually the old one and different from the _real_ information.\nYou can see that I correctly set the author/commiter email here using either cgit (https://git.gnunet.org/gnunet.git/commit/?id=be9b998b3369056c7c8fb0ae84fb4e2a064b496c) or a specific format such as\n\n$ git log --pretty=format:\"[%h] %cd - Committer: %cn (%ce), Author: %an (%ae)\n\nThis is driving me crazy as the information is just plain wrong and when our CI tries to collect a blamelist when sending out notifications, it also uses the info from \"git log\" instead of the actual author/commiter emails, promptly sending the reports to the wrong account.\n\nAny idea what to do? I really do not want to rebase and rewrite thousands of commits with questionable success.\nDoing that locally also does not change the output from \"git log\", in case you are wondering.\nThis problem will reemerge eventually whenever an author wants to change to another email address it seems so is this a bug?\n\nAny help/pointers appreciated.\n\nMartin\n"},{"id":"439440","messageId":"YXOopkKXrluffiuX@danh.dev","threadId":"56766","inReplyTo":"9826C830-3680-4AC4-9ADB-5FA45222A15B@posteo.de","subject":"Re: git log displaying wrong account information","fromName":"Đoàn Trần Công Danh","fromEmail":"congdanhqx@gmail.com","sentAt":"2021-10-23T06:16:06Z","receivedAt":"2021-10-23T06:16:13Z","isPatch":false,"sender":{"key":"congdanhqx@gmail.com","avatar":"https://avatars.githubusercontent.com/u/42673067?v=4"},"body":"On 2021-10-23 05:58:37+0000, \"Schanzenbach, Martin\" <mschanzenbach@posteo.de> wrote:\n> Hello,\n> \n> there is some odd behaviour in \"git log\" which affects me in various ways:\n> For some reason, it \"canonicalizes\" the author/commiter information in our repository: https://git.gnunet.org/git/gnunet.git\n> 5 years ago or so I was using another email address for commits. I have been using a different email address since that.\n> \n> But if you clone this repo, and take a look at a recent commit such\n> as be9b998b3369056c7c8fb0ae84fb4e2a064b496c using \"git log\", you\n> will see that my email address is actually the old one and different\n> from the _real_ information.\n\nBy old one, do you mean:\n\n\tMartin Schanzenbach <martin.schanzenbach@aisec.fraunhofer.de>\n\nIt's because you have those entries in .mailmap:\n\n---- 8< ----\nMartin Schanzenbach <martin.schanzenbach@aisec.fraunhofer.de> Schanzenbach, Martin <martin.schanzenbach@aisec.fraunhofer.de>\nMartin Schanzenbach <martin.schanzenbach@aisec.fraunhofer.de> Schanzenbach, Martin <mschanzenbach@posteo.de>\nMartin Schanzenbach <martin.schanzenbach@aisec.fraunhofer.de> Martin Schanzenbach <mschanzenbach@posteo.de>\n---- >8 -----\n\nWhich will map your:\n\n\tMartin Schanzenbach <mschanzenbach@posteo.de>\n\ninto it.\n\n\n> You can see that I correctly set the author/commiter email here\n> using either cgit\n> (https://git.gnunet.org/gnunet.git/commit/?id=be9b998b3369056c7c8fb0ae84fb4e2a064b496c)\n> or a specific format such as\n> \n> $ git log --pretty=format:\"[%h] %cd - Committer: %cn (%ce), Author: %an (%ae)\n> \n> This is driving me crazy as the information is just plain wrong and\n> when our CI tries to collect a blamelist when sending out\n> notifications, it also uses the info from \"git log\" instead of the\n> actual author/commiter emails, promptly sending the reports to the\n> wrong account.\n\nThe original value is recorded in the commit. You can retrieve raw\nvalue with git-cat-file\n\n> \n> Any idea what to do?\n\nChange your mailmap entries to:\n\n---- 8< ---\nMartin Schanzenbach <mschanzenbach@posteo.de> Schanzenbach, Martin <martin.schanzenbach@aisec.fraunhofer.de>\nMartin Schanzenbach <mschanzenbach@posteo.de> Schanzenbach, Martin <mschanzenbach@posteo.de>\nMartin Schanzenbach <mschanzenbach@posteo.de> Martin Schanzenbach <martin.schanzenbach@aisec.fraunhofer.de>\n---- >8 ----\n\n\n> I really do not want to rebase and rewrite\n> thousands of commits with questionable success.\n> Doing that locally also does not change the output from \"git log\", in case you are wondering.\n> This problem will reemerge eventually whenever an author wants to\n> change to another email address it seems so is this a bug?\n> \n> Any help/pointers appreciated.\n> \n> Martin\n\n\n\n-- \nDanh\n"},{"id":"439441","messageId":"F36A97CE-2245-4EF8-B63D-B917166308D8@posteo.de","threadId":"56766","inReplyTo":"YXOopkKXrluffiuX@danh.dev","subject":"Re: git log displaying wrong account information","fromName":"Schanzenbach, Martin","fromEmail":"mschanzenbach@posteo.de","sentAt":"2021-10-23T06:21:05Z","receivedAt":"2021-10-23T06:21:10Z","isPatch":false,"sender":{"key":"mschanzenbach@posteo.de","avatar":null},"body":"Thanks! I did not know about that file.\n\n> On 23. Oct 2021, at 08:16, Đoàn Trần Công Danh <congdanhqx@gmail.com> wrote:\n> \n> On 2021-10-23 05:58:37+0000, \"Schanzenbach, Martin\" <mschanzenbach@posteo.de> wrote:\n>> Hello,\n>> \n>> there is some odd behaviour in \"git log\" which affects me in various ways:\n>> For some reason, it \"canonicalizes\" the author/commiter information in our repository: https://git.gnunet.org/git/gnunet.git\n>> 5 years ago or so I was using another email address for commits. I have been using a different email address since that.\n>> \n>> But if you clone this repo, and take a look at a recent commit such\n>> as be9b998b3369056c7c8fb0ae84fb4e2a064b496c using \"git log\", you\n>> will see that my email address is actually the old one and different\n>> from the _real_ information.\n> \n> By old one, do you mean:\n> \n> \tMartin Schanzenbach <martin.schanzenbach@aisec.fraunhofer.de>\n> \n> It's because you have those entries in .mailmap:\n> \n> ---- 8< ----\n> Martin Schanzenbach <martin.schanzenbach@aisec.fraunhofer.de> Schanzenbach, Martin <martin.schanzenbach@aisec.fraunhofer.de>\n> Martin Schanzenbach <martin.schanzenbach@aisec.fraunhofer.de> Schanzenbach, Martin <mschanzenbach@posteo.de>\n> Martin Schanzenbach <martin.schanzenbach@aisec.fraunhofer.de> Martin Schanzenbach <mschanzenbach@posteo.de>\n> ---- >8 -----\n> \n> Which will map your:\n> \n> \tMartin Schanzenbach <mschanzenbach@posteo.de>\n> \n> into it.\n> \n> \n>> You can see that I correctly set the author/commiter email here\n>> using either cgit\n>> (https://git.gnunet.org/gnunet.git/commit/?id=be9b998b3369056c7c8fb0ae84fb4e2a064b496c)\n>> or a specific format such as\n>> \n>> $ git log --pretty=format:\"[%h] %cd - Committer: %cn (%ce), Author: %an (%ae)\n>> \n>> This is driving me crazy as the information is just plain wrong and\n>> when our CI tries to collect a blamelist when sending out\n>> notifications, it also uses the info from \"git log\" instead of the\n>> actual author/commiter emails, promptly sending the reports to the\n>> wrong account.\n> \n> The original value is recorded in the commit. You can retrieve raw\n> value with git-cat-file\n> \n>> \n>> Any idea what to do?\n> \n> Change your mailmap entries to:\n> \n> ---- 8< ---\n> Martin Schanzenbach <mschanzenbach@posteo.de> Schanzenbach, Martin <martin.schanzenbach@aisec.fraunhofer.de>\n> Martin Schanzenbach <mschanzenbach@posteo.de> Schanzenbach, Martin <mschanzenbach@posteo.de>\n> Martin Schanzenbach <mschanzenbach@posteo.de> Martin Schanzenbach <martin.schanzenbach@aisec.fraunhofer.de>\n> ---- >8 ----\n> \n> \n>> I really do not want to rebase and rewrite\n>> thousands of commits with questionable success.\n>> Doing that locally also does not change the output from \"git log\", in case you are wondering.\n>> This problem will reemerge eventually whenever an author wants to\n>> change to another email address it seems so is this a bug?\n>> \n>> Any help/pointers appreciated.\n>> \n>> Martin\n> \n> \n> \n> --\n> Danh\n\n"}]}