On 2024-06-25, at 22:43:10 +0200, Aymeric Agon-Rambosson wrote: > Hello to both of you, > > First of all, Jeremy, thank you for having gone to the bottom of this. > > Le mardi 25 juin 2024 à 08:53, Jeremy Sowden <aza...@debian.org> a écrit : > > The problem is that git-commit requires the name and e-mail address of > > the committer as well as the author. > > I was thinking so, I just couldn't test it (since I can't reproduce). > > > (sid)aztest@ulthar:~$ cd $( mktemp -d ) > > (sid)aztest@ulthar:/tmp/tmp.6XyqcRs3l9$ git init > > hint: Using 'master' as the name for the initial branch. This > > default branch name > > hint: is subject to change. To configure the initial branch name to > > use in all > > hint: of your new repositories, which will suppress this warning, > > call: > > hint: > > hint: git config --global init.defaultBranch <name> > > hint: > > hint: Names commonly chosen instead of 'master' are 'main', 'trunk' > > and > > hint: 'development'. The just-created branch can be renamed via this > > command: > > hint: > > hint: git branch -m <name> > > Initialized empty Git repository in /tmp/tmp.6XyqcRs3l9/.git/ > > (sid)aztest@ulthar:/tmp/tmp.6XyqcRs3l9$ $ git config --list > > core.repositoryformatversion=0 > > core.filemode=true > > core.bare=false > > core.logallrefupdates=true > > (sid)aztest@ulthar:/tmp/tmp.6XyqcRs3l9$ GIT_AUTHOR_NAME=Aztest > > GIT_AUTHOR_EMAIL=aztest@sid.ulthar.dreamlands git commit --allow-empty > > Committer identity unknown > > > > *** Please tell me who you are. > > > > Run > > > > git config --global user.email "y...@example.com" > > git config --global user.name "Your Name" > > > > to set your account's default identity. > > Omit --global to set the identity only in this repository. > > > > fatal: empty ident name (for <aztest@ulthar.dreamlands>) not allowed > > This I can reproduce in the same chroot in which I cannot reproduce Lucas's > behaviour with sbuild. > > So the issue of why I cannot reproduce must be down to the difference in > environment variables inside the chroot. I personnally only run "sbuild -d > unstable magit", with the eventual "--no-run-piuparts". > > So @Lucas, would you be so kind as to give me the exact same command line > that let you reproduce the behaviour whose log you sent us last Tuesday ? > Your environment, that is : > > > APT_CONFIG=/var/lib/sbuild/apt.conf > > HOME=/sbuild-nonexistent > > LANG=C.UTF-8 > > LC_ALL=C.UTF-8 > > LOGNAME=user42 > > PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games > > SCHROOT_ALIAS_NAME=unstable > > SCHROOT_CHROOT_NAME=sid-amd64-sbuild > > SCHROOT_COMMAND=env > > SCHROOT_GID=1001 > > SCHROOT_GROUP=user42 > > SCHROOT_SESSION_ID=sid-amd64-sbuild-6a820ace-adb5-4f8a-a17e-b4e773461f33 > > SCHROOT_UID=1001 > > SCHROOT_USER=user42 > > SHELL=/bin/sh > > USER=user42 > > is quite different from mine : > > > APT_CONFIG=/var/lib/sbuild/apt.conf > > HOME=/sbuild-nonexistent > > LANG=fr_FR.UTF-8 > > LC_ALL=C.UTF-8 > > LD_LIBRARY_PATH=/usr/lib/libeatmydata > > LD_PRELOAD=libeatmydata.so > > LOGNAME=rico > > PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games > > PWD=/<<PKGBUILDDIR>> > > SCHROOT_ALIAS_NAME=unstable-amd64-sbuild > > SCHROOT_CHROOT_NAME=unstable-amd64-sbuild > > SCHROOT_COMMAND=env > > SCHROOT_GID=1000 > > SCHROOT_GROUP=rico > > SCHROOT_SESSION_ID=unstable-amd64-sbuild-767aa3ef-99b2-4d74-ae69-86501e870978 > > SCHROOT_UID=1000 > > SCHROOT_USER=rico > > SHELL=/bin/sh > > USER=rico > > And I suspect the reason I could not reproduce lies therein.
Lucas used a test account, 'user42', to run sbuild [0]: su user42 -c 'sbuild -n -A -s --force-orig-source --apt-update -d unstable -v --no-run-lintian magit_3.3.0+git20240412.1.da14749d-1' so I created one to do likewise: aztest:x:1001:1001:,,,:/home/aztest:/bin/bash Note the blank gecos field. Git looks first for config or environment variables. If those aren't set, it uses getpwnam to try to find a name from /etc/passwd. I got the test failures because the user running sbuild had no git config and a blank gecos field. Another problem that came to light is that one of the tests requires a UTF-8 locales, so I added `LC_ALL=C.UTF-8` to d/rules. > > There is an existing patch that sets the e-mail address, but not the > > name. I will update it and forward it upstream. > > There you go, the updated patch : > > From: Aymeric Agon-Rambosson <aymeric.a...@yandex.com> > Date: Sat, 24 Dec 2022 16:44:54 +0100 > Subject: Repair "git unable to detect address" error. > Forwarded: not-needed > > --- a/test/magit-tests.el > +++ b/test/magit-tests.el > @@ -40,6 +40,8 @@ > (process-environment process-environment) > (magit-git-global-arguments > (nconc (list "-c" "protocol.file.allow=always") > + (list "-c" "user.email=\"a.u.t...@example.com\"") > + (list "-c" "user.name=\"A U Thor\"") > magit-git-global-arguments))) > (push "GIT_AUTHOR_NAME=A U Thor" process-environment) > (push "GIT_AUTHOR_EMAIL=a.u.t...@example.com" process-environment) > > Sorry of having been quite useless on that one. > > Best, > > Aymeric No problem. Happy to help. J. 0 - http://qa-logs.debian.net/2024/06/15/magit_3.3.0+git20240412.1.da14749d-1_unstable.log
signature.asc
Description: PGP signature