{"thread":{"id":"65147","subject":"Test \"t0300-credentials\" is failing on Arch/Artix: asks to enter the Username/Password in an infinite loop","startedAt":"2026-03-06T00:42:25Z","lastAt":"2026-03-06T21:17:27Z","messageCount":12,"participants":["Ivan Ivanov","brian m. carlson","Jeff King"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"538037","messageId":"CAAaskFBp+A9pOhd8O6owd6k0cDj66ipXrqH2Hj_c7j3d=HM10Q@mail.gmail.com","threadId":"65147","inReplyTo":null,"subject":"Test \"t0300-credentials\" is failing on Arch/Artix: asks to enter the Username/Password in an infinite loop","fromName":"Ivan Ivanov","fromEmail":"qmastery16@gmail.com","sentAt":"2026-03-06T00:42:12Z","receivedAt":"2026-03-06T00:42:25Z","isPatch":false,"sender":{"key":"qmastery16@gmail.com","avatar":null},"body":"Good day! While trying to rebuild git for Arch/Artix, I run into the\nfollowing problem: shortly after \"*** prove (shell & unit tests) ***\"\nI get asked the Username/Password in an endless loop. Below are the\nfull logs, as well as the contents of\n./test-results/t0300-credentials.out file, hope this is helpful for\ndebugging. Please note that I have all the dependencies installed,\neven the optional ones like Apache HTTPD (some online manuals\nsuggested doing that, but didn't help to pass this test)\n\n==> Starting check()...\n    GEN git-difftool--helper\n    GEN git-filter-branch\n    GEN git-merge-octopus\n    GEN git-merge-one-file\n    GEN git-merge-resolve\n    GEN git-mergetool\n    GEN git-quiltimport\n    GEN git-request-pull\n    GEN git-submodule\n    GEN git-web--browse\n    GEN git-archimport\n    GEN git-cvsexportcommit\n    GEN git-cvsimport\n    GEN git-cvsserver\n    GEN git-send-email\n    GEN git-svn\n    GEN git-p4\n    GEN git-instaweb\n    GEN git-mergetool--lib\n    GEN git-sh-i18n\n    GEN git-sh-setup\n    SUBDIR git-gui\n    SUBDIR gitk-git\n    SUBDIR templates\n    GEN perl/build/lib/Git.pm\n    GEN perl/build/lib/Git/I18N.pm\n    GEN perl/build/lib/Git/IndexInfo.pm\n    GEN perl/build/lib/Git/LoadCPAN.pm\n    GEN perl/build/lib/Git/Packet.pm\n    GEN perl/build/lib/Git/SVN.pm\n    GEN perl/build/lib/Git/LoadCPAN/Error.pm\n    GEN perl/build/lib/Git/SVN/Editor.pm\n    GEN perl/build/lib/Git/SVN/Fetcher.pm\n    GEN perl/build/lib/Git/SVN/GlobSpec.pm\n    GEN perl/build/lib/Git/SVN/Log.pm\n    GEN perl/build/lib/Git/SVN/Migration.pm\n    GEN perl/build/lib/Git/SVN/Prompt.pm\n    GEN perl/build/lib/Git/SVN/Ra.pm\n    GEN perl/build/lib/Git/SVN/Utils.pm\n    GEN perl/build/lib/Git/LoadCPAN/Mail/Address.pm\n    GEN perl/build/lib/Git/SVN/Memoize/YAML.pm\nmake -C t/ all\nmake[1]: Entering directory '/home/username/artix_git/src/git/t'\nrm -f -r 'test-results'\n*** prove (shell & unit tests) ***\nUsername for 'http://example.com':\nPassword for 'http://example.com':\nUsername for 'http://example.com':\nPassword for 'http://example.com':\n\n/src/git/t$ cat ./test-results/t0300-credentials.out\nInitialized empty Git repository in /dev/shm/git-test/trash\ndirectory.t0300-credentials/.git/\nexpecting success of 0300.1 'setup helper scripts':\n    cat >dump <<-\\EOF &&\n    whoami=$(echo $0 | sed s/.*git-credential-//)\n    echo >&2 \"$whoami: $*\"\n    OIFS=$IFS\n    IFS==\n    while read key value; do\n        echo >&2 \"$whoami: $key=$value\"\n        if test -z \"${key%%*\\[\\]}\"\n        then\n            key=${key%%\\[\\]}\n            eval \"$key=\\\"\\$$key $value\\\"\"\n        else\n            eval \"$key=$value\"\n        fi\n    done\n    IFS=$OIFS\n    EOF\n\n    write_script git-credential-useless <<-\\EOF &&\n    . ./dump\n    exit 0\n    EOF\n\n    write_script git-credential-quit <<-\\EOF &&\n    . ./dump\n    echo quit=1\n    EOF\n\n    write_script git-credential-verbatim <<-\\EOF &&\n    user=$1; shift\n    pass=$1; shift\n    . ./dump\n    test -z \"$user\" || echo username=$user\n    test -z \"$pass\" || echo password=$pass\n    EOF\n\n    write_script git-credential-verbatim-cred <<-\\EOF &&\n    authtype=$1; shift\n    credential=$1; shift\n    . ./dump\n    echo capability[]=authtype\n    echo capability[]=state\n    test -z \"${capability##*authtype*}\" || exit 0\n    test -z \"$authtype\" || echo authtype=$authtype\n    test -z \"$credential\" || echo credential=$credential\n    test -z \"${capability##*state*}\" || exit 0\n    echo state[]=verbatim-cred:foo\n    EOF\n\n    write_script git-credential-verbatim-ephemeral <<-\\EOF &&\n    authtype=$1; shift\n    credential=$1; shift\n    . ./dump\n    echo capability[]=authtype\n    test -z \"${capability##*authtype*}\" || exit 0\n    test -z \"$authtype\" || echo authtype=$authtype\n    test -z \"$credential\" || echo credential=$credential\n    echo \"ephemeral=1\"\n    EOF\n\n    write_script git-credential-verbatim-with-expiry <<-\\EOF &&\n    user=$1; shift\n    pass=$1; shift\n    pexpiry=$1; shift\n    . ./dump\n    test -z \"$user\" || echo username=$user\n    test -z \"$pass\" || echo password=$pass\n    test -z \"$pexpiry\" || echo password_expiry_utc=$pexpiry\n    EOF\n\n    write_script git-credential-cntrl-in-username <<-\\EOF &&\n    printf \"username=\\\\007latrix Lestrange\\\\n\"\n    EOF\n\n    PATH=\"$PWD:$PATH\"\n\nok 1 - setup helper scripts\n\nexpecting success of 0300.2 'credential_fill invokes helper':\n    check fill \"verbatim foo bar\" <<-\\EOF\n    protocol=http\n    host=example.com\n    --\n    protocol=http\n    host=example.com\n    username=foo\n    password=bar\n    --\n    verbatim: get\n    verbatim: protocol=http\n    verbatim: host=example.com\n    EOF\n\n--- expect-stdout    2026-03-06 00:33:02.009338195 +0000\n+++ stdout    2026-03-06 00:33:07.569338321 +0000\n@@ -1,4 +1,4 @@\n protocol=http\n host=example.com\n-username=foo\n-password=bar\n+username=\n+password=\nnot ok 2 - credential_fill invokes helper\n#\n#        check fill \"verbatim foo bar\" <<-\\EOF\n#        protocol=http\n#        host=example.com\n#        --\n#        protocol=http\n#        host=example.com\n#        username=foo\n#        password=bar\n#        --\n#        verbatim: get\n#        verbatim: protocol=http\n#        verbatim: host=example.com\n#        EOF\n#\n\nexpecting success of 0300.3 'credential_fill invokes helper with credential':\n    check fill \"verbatim-cred Bearer token\" <<-\\EOF\n    capability[]=authtype\n    protocol=http\n    host=example.com\n    --\n    capability[]=authtype\n    authtype=Bearer\n    credential=token\n    protocol=http\n    host=example.com\n    --\n    verbatim-cred: get\n    verbatim-cred: capability[]=authtype\n    verbatim-cred: protocol=http\n    verbatim-cred: host=example.com\n    EOF\n\n--- expect-stdout    2026-03-06 00:33:07.581338322 +0000\n+++ stdout    2026-03-06 00:33:08.191338336 +0000\n@@ -1,5 +1,4 @@\n-capability[]=authtype\n-authtype=Bearer\n-credential=token\n protocol=http\n host=example.com\n+username=\n+password=\nnot ok 3 - credential_fill invokes helper with credential\n#\n#        check fill \"verbatim-cred Bearer token\" <<-\\EOF\n#        capability[]=authtype\n#        protocol=http\n#        host=example.com\n#        --\n#        capability[]=authtype\n#        authtype=Bearer\n#        credential=token\n#        protocol=http\n#        host=example.com\n#        --\n#        verbatim-cred: get\n#        verbatim-cred: capability[]=authtype\n#        verbatim-cred: protocol=http\n#        verbatim-cred: host=example.com\n#        EOF\n#\n\nexpecting success of 0300.4 'credential_fill invokes helper with\nephemeral credential':\n    check fill \"verbatim-ephemeral Bearer token\" <<-\\EOF\n    capability[]=authtype\n    protocol=http\n    host=example.com\n    --\n    capability[]=authtype\n    authtype=Bearer\n    credential=token\n    ephemeral=1\n    protocol=http\n    host=example.com\n    --\n    verbatim-ephemeral: get\n    verbatim-ephemeral: capability[]=authtype\n    verbatim-ephemeral: protocol=http\n    verbatim-ephemeral: host=example.com\n    EOF\n"},{"id":"538038","messageId":"CAAaskFANnrqTAjQOHhAgzES9=S+y7w9u-LMWbRbi8FayVdvzFw@mail.gmail.com","threadId":"65147","inReplyTo":"CAAaskFBp+A9pOhd8O6owd6k0cDj66ipXrqH2Hj_c7j3d=HM10Q@mail.gmail.com","subject":"Re: Test \"t0300-credentials\" is failing on Arch/Artix: asks to enter the Username/Password in an infinite loop","fromName":"Ivan Ivanov","fromEmail":"qmastery16@gmail.com","sentAt":"2026-03-06T01:05:58Z","receivedAt":"2026-03-06T01:06:11Z","isPatch":false,"sender":{"key":"qmastery16@gmail.com","avatar":null},"body":"To clarify, in addition to t0300-credentials.out ,\nt0301-credential-cache.out and t0302-credential-store.out are also\nfailing, however a similar-by-nature t0303-credential-external.out\nsucceeds fine. Very strange. Seeing how it's leaking to the primary\nconsole, I suspect something may be wrong with shell handling: i.e.\nfor t0302-credential-store test I am seeing these prompts that are\nwaiting input for a user (could write any message here or just press\nEnter to get a new prompt) :\n\nUsername for 'https://example.com':\nPassword for 'https://%20@example.com':\nUsername for 'http://example.com':\nPassword for 'http://example.com':\nUsername for 'https://other.tld':\nPassword for 'https://other.tld':\nPassword for 'https://other@example.com':\nUsername for 'http://path.tld/bar.git':\nPassword for 'http://path.tld/bar.git':\nPassword for 'https://user-overwrite@example.com':\nUsername for 'https://example.com':\nPassword for 'https://example.com':\nPassword for 'https://user1@example.com':\nUsername for 'https://example.com':\n...\n\nOn Fri, Mar 6, 2026 at 3:42 AM Ivan Ivanov <qmastery16@gmail.com> wrote:\n>\n> Good day! While trying to rebuild git for Arch/Artix, I run into the\n> following problem: shortly after \"*** prove (shell & unit tests) ***\"\n> I get asked the Username/Password in an endless loop. Below are the\n> full logs, as well as the contents of\n> ./test-results/t0300-credentials.out file, hope this is helpful for\n> debugging. Please note that I have all the dependencies installed,\n> even the optional ones like Apache HTTPD (some online manuals\n> suggested doing that, but didn't help to pass this test)\n>\n> ==> Starting check()...\n>     GEN git-difftool--helper\n>     GEN git-filter-branch\n>     GEN git-merge-octopus\n>     GEN git-merge-one-file\n>     GEN git-merge-resolve\n>     GEN git-mergetool\n>     GEN git-quiltimport\n>     GEN git-request-pull\n>     GEN git-submodule\n>     GEN git-web--browse\n>     GEN git-archimport\n>     GEN git-cvsexportcommit\n>     GEN git-cvsimport\n>     GEN git-cvsserver\n>     GEN git-send-email\n>     GEN git-svn\n>     GEN git-p4\n>     GEN git-instaweb\n>     GEN git-mergetool--lib\n>     GEN git-sh-i18n\n>     GEN git-sh-setup\n>     SUBDIR git-gui\n>     SUBDIR gitk-git\n>     SUBDIR templates\n>     GEN perl/build/lib/Git.pm\n>     GEN perl/build/lib/Git/I18N.pm\n>     GEN perl/build/lib/Git/IndexInfo.pm\n>     GEN perl/build/lib/Git/LoadCPAN.pm\n>     GEN perl/build/lib/Git/Packet.pm\n>     GEN perl/build/lib/Git/SVN.pm\n>     GEN perl/build/lib/Git/LoadCPAN/Error.pm\n>     GEN perl/build/lib/Git/SVN/Editor.pm\n>     GEN perl/build/lib/Git/SVN/Fetcher.pm\n>     GEN perl/build/lib/Git/SVN/GlobSpec.pm\n>     GEN perl/build/lib/Git/SVN/Log.pm\n>     GEN perl/build/lib/Git/SVN/Migration.pm\n>     GEN perl/build/lib/Git/SVN/Prompt.pm\n>     GEN perl/build/lib/Git/SVN/Ra.pm\n>     GEN perl/build/lib/Git/SVN/Utils.pm\n>     GEN perl/build/lib/Git/LoadCPAN/Mail/Address.pm\n>     GEN perl/build/lib/Git/SVN/Memoize/YAML.pm\n> make -C t/ all\n> make[1]: Entering directory '/home/username/artix_git/src/git/t'\n> rm -f -r 'test-results'\n> *** prove (shell & unit tests) ***\n> Username for 'http://example.com':\n> Password for 'http://example.com':\n> Username for 'http://example.com':\n> Password for 'http://example.com':\n>\n> /src/git/t$ cat ./test-results/t0300-credentials.out\n> Initialized empty Git repository in /dev/shm/git-test/trash\n> directory.t0300-credentials/.git/\n> expecting success of 0300.1 'setup helper scripts':\n>     cat >dump <<-\\EOF &&\n>     whoami=$(echo $0 | sed s/.*git-credential-//)\n>     echo >&2 \"$whoami: $*\"\n>     OIFS=$IFS\n>     IFS==\n>     while read key value; do\n>         echo >&2 \"$whoami: $key=$value\"\n>         if test -z \"${key%%*\\[\\]}\"\n>         then\n>             key=${key%%\\[\\]}\n>             eval \"$key=\\\"\\$$key $value\\\"\"\n>         else\n>             eval \"$key=$value\"\n>         fi\n>     done\n>     IFS=$OIFS\n>     EOF\n>\n>     write_script git-credential-useless <<-\\EOF &&\n>     . ./dump\n>     exit 0\n>     EOF\n>\n>     write_script git-credential-quit <<-\\EOF &&\n>     . ./dump\n>     echo quit=1\n>     EOF\n>\n>     write_script git-credential-verbatim <<-\\EOF &&\n>     user=$1; shift\n>     pass=$1; shift\n>     . ./dump\n>     test -z \"$user\" || echo username=$user\n>     test -z \"$pass\" || echo password=$pass\n>     EOF\n>\n>     write_script git-credential-verbatim-cred <<-\\EOF &&\n>     authtype=$1; shift\n>     credential=$1; shift\n>     . ./dump\n>     echo capability[]=authtype\n>     echo capability[]=state\n>     test -z \"${capability##*authtype*}\" || exit 0\n>     test -z \"$authtype\" || echo authtype=$authtype\n>     test -z \"$credential\" || echo credential=$credential\n>     test -z \"${capability##*state*}\" || exit 0\n>     echo state[]=verbatim-cred:foo\n>     EOF\n>\n>     write_script git-credential-verbatim-ephemeral <<-\\EOF &&\n>     authtype=$1; shift\n>     credential=$1; shift\n>     . ./dump\n>     echo capability[]=authtype\n>     test -z \"${capability##*authtype*}\" || exit 0\n>     test -z \"$authtype\" || echo authtype=$authtype\n>     test -z \"$credential\" || echo credential=$credential\n>     echo \"ephemeral=1\"\n>     EOF\n>\n>     write_script git-credential-verbatim-with-expiry <<-\\EOF &&\n>     user=$1; shift\n>     pass=$1; shift\n>     pexpiry=$1; shift\n>     . ./dump\n>     test -z \"$user\" || echo username=$user\n>     test -z \"$pass\" || echo password=$pass\n>     test -z \"$pexpiry\" || echo password_expiry_utc=$pexpiry\n>     EOF\n>\n>     write_script git-credential-cntrl-in-username <<-\\EOF &&\n>     printf \"username=\\\\007latrix Lestrange\\\\n\"\n>     EOF\n>\n>     PATH=\"$PWD:$PATH\"\n>\n> ok 1 - setup helper scripts\n>\n> expecting success of 0300.2 'credential_fill invokes helper':\n>     check fill \"verbatim foo bar\" <<-\\EOF\n>     protocol=http\n>     host=example.com\n>     --\n>     protocol=http\n>     host=example.com\n>     username=foo\n>     password=bar\n>     --\n>     verbatim: get\n>     verbatim: protocol=http\n>     verbatim: host=example.com\n>     EOF\n>\n> --- expect-stdout    2026-03-06 00:33:02.009338195 +0000\n> +++ stdout    2026-03-06 00:33:07.569338321 +0000\n> @@ -1,4 +1,4 @@\n>  protocol=http\n>  host=example.com\n> -username=foo\n> -password=bar\n> +username=\n> +password=\n> not ok 2 - credential_fill invokes helper\n> #\n> #        check fill \"verbatim foo bar\" <<-\\EOF\n> #        protocol=http\n> #        host=example.com\n> #        --\n> #        protocol=http\n> #        host=example.com\n> #        username=foo\n> #        password=bar\n> #        --\n> #        verbatim: get\n> #        verbatim: protocol=http\n> #        verbatim: host=example.com\n> #        EOF\n> #\n>\n> expecting success of 0300.3 'credential_fill invokes helper with credential':\n>     check fill \"verbatim-cred Bearer token\" <<-\\EOF\n>     capability[]=authtype\n>     protocol=http\n>     host=example.com\n>     --\n>     capability[]=authtype\n>     authtype=Bearer\n>     credential=token\n>     protocol=http\n>     host=example.com\n>     --\n>     verbatim-cred: get\n>     verbatim-cred: capability[]=authtype\n>     verbatim-cred: protocol=http\n>     verbatim-cred: host=example.com\n>     EOF\n>\n> --- expect-stdout    2026-03-06 00:33:07.581338322 +0000\n> +++ stdout    2026-03-06 00:33:08.191338336 +0000\n> @@ -1,5 +1,4 @@\n> -capability[]=authtype\n> -authtype=Bearer\n> -credential=token\n>  protocol=http\n>  host=example.com\n> +username=\n> +password=\n> not ok 3 - credential_fill invokes helper with credential\n> #\n> #        check fill \"verbatim-cred Bearer token\" <<-\\EOF\n> #        capability[]=authtype\n> #        protocol=http\n> #        host=example.com\n> #        --\n> #        capability[]=authtype\n> #        authtype=Bearer\n> #        credential=token\n> #        protocol=http\n> #        host=example.com\n> #        --\n> #        verbatim-cred: get\n> #        verbatim-cred: capability[]=authtype\n> #        verbatim-cred: protocol=http\n> #        verbatim-cred: host=example.com\n> #        EOF\n> #\n>\n> expecting success of 0300.4 'credential_fill invokes helper with\n> ephemeral credential':\n>     check fill \"verbatim-ephemeral Bearer token\" <<-\\EOF\n>     capability[]=authtype\n>     protocol=http\n>     host=example.com\n>     --\n>     capability[]=authtype\n>     authtype=Bearer\n>     credential=token\n>     ephemeral=1\n>     protocol=http\n>     host=example.com\n>     --\n>     verbatim-ephemeral: get\n>     verbatim-ephemeral: capability[]=authtype\n>     verbatim-ephemeral: protocol=http\n>     verbatim-ephemeral: host=example.com\n>     EOF\n"},{"id":"538039","messageId":"aaosmo1Iluc5KeZw@fruit.crustytoothpaste.net","threadId":"65147","inReplyTo":"CAAaskFANnrqTAjQOHhAgzES9=S+y7w9u-LMWbRbi8FayVdvzFw@mail.gmail.com","subject":"Re: Test \"t0300-credentials\" is failing on Arch/Artix: asks to enter the Username/Password in an infinite loop","fromName":"brian m. carlson","fromEmail":"sandals@crustytoothpaste.net","sentAt":"2026-03-06T01:23:38Z","receivedAt":"2026-03-06T01:23:40Z","isPatch":false,"sender":{"key":"sandals@crustytoothpaste.net","avatar":"https://avatars.githubusercontent.com/u/497054?v=4"},"body":"On 2026-03-06 at 01:05:58, Ivan Ivanov wrote:\n> To clarify, in addition to t0300-credentials.out ,\n> t0301-credential-cache.out and t0302-credential-store.out are also\n> failing, however a similar-by-nature t0303-credential-external.out\n> succeeds fine. Very strange. Seeing how it's leaking to the primary\n> console, I suspect something may be wrong with shell handling: i.e.\n> for t0302-credential-store test I am seeing these prompts that are\n> waiting input for a user (could write any message here or just press\n> Enter to get a new prompt) :\n> \n> Username for 'https://example.com':\n> Password for 'https://%20@example.com':\n> Username for 'http://example.com':\n> Password for 'http://example.com':\n> Username for 'https://other.tld':\n> Password for 'https://other.tld':\n> Password for 'https://other@example.com':\n> Username for 'http://path.tld/bar.git':\n> Password for 'http://path.tld/bar.git':\n> Password for 'https://user-overwrite@example.com':\n> Username for 'https://example.com':\n> Password for 'https://example.com':\n> Password for 'https://user1@example.com':\n> Username for 'https://example.com':\n\nTo help us understand more, can you provide the output of `git version\n--build-options` on the affected version, as well as the shell you're\nusing (bash, dash, etc. and version) and any configuration options\nyou're using to build?\n\nUsing Debian unstable with Debian's dash 0.5.12-12 as `/bin/sh`, I don't\nsee this problem when running with the following command in zsh:\n\n    time make -j12 all && (cd t && ulimit -c unlimited && GIT_PROVE_OPTS=-j12 GIT_TEST_DEFAULT_HASH=sha256 ./t0300*.sh --verbose --debug)\n\nNote that Git should not prompt on the command line because of the\nfollowing code in `t/lib-credential.sh`:\n\n    write_script askpass <<\\EOF\n    echo >&2 askpass: $*\n    what=$(echo $1 | cut -d\" \" -f1 | tr A-Z a-z | tr -cd a-z)\n    echo \"askpass-$what\"\n    EOF\n    GIT_ASKPASS=\"$PWD/askpass\"\n    export GIT_ASKPASS\n-- \nbrian m. carlson (they/them)\nToronto, Ontario, CA\n"},{"id":"538040","messageId":"CAAaskFC=tpuS-saP9t5Kp0+i6qTHe29x-dGkanyAzz-xaq_HDA@mail.gmail.com","threadId":"65147","inReplyTo":"aaosmo1Iluc5KeZw@fruit.crustytoothpaste.net","subject":"Re: Test \"t0300-credentials\" is failing on Arch/Artix: asks to enter the Username/Password in an infinite loop","fromName":"Ivan Ivanov","fromEmail":"qmastery16@gmail.com","sentAt":"2026-03-06T01:44:48Z","receivedAt":"2026-03-06T01:45:01Z","isPatch":false,"sender":{"key":"qmastery16@gmail.com","avatar":null},"body":"Hi there Brian! Here are my git version --build-options (taken from a\nversion packaged at Artix, however I assume it to have the same\noptions as on https://gitea.artixlinux.org/packages/git that I am\nstill building atm)\n\ngit version 2.53.0 cpu: x86_64 built from commit:\n67ad42147a7acc2af6074753ebd03d904476118f sizeof-long: 8 sizeof-size_t:\n8 shell-path: /bin/sh rust: enabled gettext: enabled libcurl: 8.18.0\nOpenSSL: OpenSSL 3.6.1 27 Jan 2026 zlib-ng: 2.3.2 SHA-1: SHA1_DC\nSHA-256: SHA256_BLK default-ref-format: files default-hash: sha1\n\nAs of my shell, it is a GNU bash --version 5.3.9(1)-release\n(x86_64-pc-linux-gnu)\n\n> any configuration options you're using to build?\n\nAt the moment - just \"makepkg ./PKGBUILD --check --noextract\n--noprepare -f\" (these flags in order to get straight to the check()\nstage). Btw right now I got a somewhat similar-by-appearance error at\ntest t5003, however if I press Enter two times then it gets further\ninstead of an infinite loop:\n\nUsername for 'http://127.0.0.1:5003':\nPassword for 'http://127.0.0.1:5003':\n\nHere are the contents of a related .out file for this t5003 . Please\nnote that not so long ago I did chmod -R 755 on this\n/dev/shm/git-test/ just in case, so I am not sure why this is failing\n\nok 81 - remote archive does not work with protocol v1\nexpecting success of 5003.82 'archive remote http repository':\n    git archive --remote=\"$HTTPD_URL/auth/smart/bare.git\" \\\n        --output=remote-http.zip HEAD &&\n    test_cmp_bin d.zip remote-http.zip\n\nfatal: cannot exec '/dev/shm/git-test/trash\ndirectory.t5003-archive-zip/askpass': Permission denied\n\nfatal: cannot exec '/dev/shm/git-test/trash\ndirectory.t5003-archive-zip/askpass': Permission denied\nfatal: cannot exec '/dev/shm/git-test/trash\ndirectory.t5003-archive-zip/askpass': Permission denied\nfatal: Authentication failed for 'http://127.0.0.1:5003/auth/smart/bare.git/'\nnot ok 82 - archive remote http repository\n#\n#        git archive --remote=\"$HTTPD_URL/auth/smart/bare.git\" \\\n#            --output=remote-http.zip HEAD &&\n#        test_cmp_bin d.zip remote-http.zip\n#\n\n# failed 1 among 82 test(s)\n1..82\n"},{"id":"538043","messageId":"aao1DF3lXfHTMH30@fruit.crustytoothpaste.net","threadId":"65147","inReplyTo":"CAAaskFC=tpuS-saP9t5Kp0+i6qTHe29x-dGkanyAzz-xaq_HDA@mail.gmail.com","subject":"Re: Test \"t0300-credentials\" is failing on Arch/Artix: asks to enter the Username/Password in an infinite loop","fromName":"brian m. carlson","fromEmail":"sandals@crustytoothpaste.net","sentAt":"2026-03-06T01:59:40Z","receivedAt":"2026-03-06T01:59:41Z","isPatch":false,"sender":{"key":"sandals@crustytoothpaste.net","avatar":"https://avatars.githubusercontent.com/u/497054?v=4"},"body":"On 2026-03-06 at 01:44:48, Ivan Ivanov wrote:\n> At the moment - just \"makepkg ./PKGBUILD --check --noextract\n> --noprepare -f\" (these flags in order to get straight to the check()\n> stage). Btw right now I got a somewhat similar-by-appearance error at\n> test t5003, however if I press Enter two times then it gets further\n> instead of an infinite loop:\n\nI don't believe we have a `makepkg` script in Git.  What I was hoping to\nsee was something like this snippet from Debian's `debian/rules`:\n\n----\nOPTS =NO_OPENSSL=1 prefix=/usr gitexecdir=/usr/lib/git-core \\\n  mandir=/usr/share/man htmldir=/usr/share/doc/git/html \\\n  INSTALLDIRS=vendor \\\n  SANE_TOOL_PATH= INSTALL=install TAR=tar \\\n  NO_CROSS_DIRECTORY_HARDLINKS=1 NO_INSTALL_HARDLINKS=1 \\\n  NO_PERL_CPAN_FALLBACKS=1 \\\n  PYTHON_PATH=/usr/bin/python3 \\\n  DEFAULT_PAGER=pager DEFAULT_EDITOR=editor \\\n  CC='$(CC)' CFLAGS='$(CFLAGS)' LDFLAGS='$(LDFLAGS)' \\\n  HOST_CPU='$(HOST_CPU)'\nDOCS =html\nDOC_OPTS =prefix=/usr htmldir=/usr/share/doc/git/html \\\n  ASCIIDOC8=1 ASCIIDOC_NO_ROFF=1\n\n# https://wiki.debian.org/ReproducibleBuilds/TimestampsInDocumentationGeneratedByAsciidoc\nDOC_OPTS += ASCIIDOC='TZ=UTC asciidoc'\n\nifeq (,$(findstring terse,$(DEB_BUILD_OPTIONS)))\n  OPTS += V=1\n  DOC_OPTS += V=1\n  TEST_OPTS = --verbose\nendif\nifneq (,$(findstring nocheck,$(DEB_BUILD_OPTIONS)))\n  TEST =\nendif\nifneq (,$(findstring nodoc,$(DEB_BUILD_OPTIONS)))\n  DOCS =\nendif\nifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))\n  NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))\n  MAKEFLAGS += -j$(NUMJOBS)\n  # Setting this with a pattern-specific rule prevents -O from\n  # affecting the top-level make, which would break realtime build\n  # output (unless dh is run as +dh, which causes other problems).\n  %: MAKEFLAGS += -O\nendif\nifneq (,$(shell dpkg-query -f '$${Version}' -W libpcre2-dev))\n  OPTS += USE_LIBPCRE2=1\nelse\n  OPTS += USE_LIBPCRE1=1\nendif\n----\n\nThose options tell us how your package is configured and what Makefile\noptions you're using.\n\n> Username for 'http://127.0.0.1:5003':\n> Password for 'http://127.0.0.1:5003':\n> \n> Here are the contents of a related .out file for this t5003 . Please\n> note that not so long ago I did chmod -R 755 on this\n> /dev/shm/git-test/ just in case, so I am not sure why this is failing\n> \n> ok 81 - remote archive does not work with protocol v1\n> expecting success of 5003.82 'archive remote http repository':\n>     git archive --remote=\"$HTTPD_URL/auth/smart/bare.git\" \\\n>         --output=remote-http.zip HEAD &&\n>     test_cmp_bin d.zip remote-http.zip\n> \n> fatal: cannot exec '/dev/shm/git-test/trash\n> directory.t5003-archive-zip/askpass': Permission denied\n> \n> fatal: cannot exec '/dev/shm/git-test/trash\n> directory.t5003-archive-zip/askpass': Permission denied\n> fatal: cannot exec '/dev/shm/git-test/trash\n> directory.t5003-archive-zip/askpass': Permission denied\n> fatal: Authentication failed for 'http://127.0.0.1:5003/auth/smart/bare.git/'\n\nI think this is your problem.  First of all, `/dev/shm` is not a\ngeneral-purpose temporary directory and should not be used that way.\nIt's designed for shared-memory segments that live in the file system\n(usually POSIX shared-memory segments).\n\nMy guess is that you've specified `TEST_OUTPUT_DIRECTORY` to something\nunder `/dev/shm` and on your system that file system is marked `noexec`.\nGit's testsuite uses many shell scripts and the test directory will need\nto live on a fully functional file system according to the standards of\nthe OS.  Normally people run the tests under `t` in the repository root\nand the repository effectively cannot be `noexec`, since otherwise\nthe binaries would not work.\n-- \nbrian m. carlson (they/them)\nToronto, Ontario, CA\n"},{"id":"538046","messageId":"CAAaskFC0WETe7NaEfznW-h53Huee2sLLAQYWBA3moLpeULhtcA@mail.gmail.com","threadId":"65147","inReplyTo":"aao1DF3lXfHTMH30@fruit.crustytoothpaste.net","subject":"Re: Test \"t0300-credentials\" is failing on Arch/Artix: asks to enter the Username/Password in an infinite loop","fromName":"Ivan Ivanov","fromEmail":"qmastery16@gmail.com","sentAt":"2026-03-06T02:14:12Z","receivedAt":"2026-03-06T02:14:25Z","isPatch":false,"sender":{"key":"qmastery16@gmail.com","avatar":null},"body":"Brian, thank you very much for checking my logs: indeed, unfortunately\nmy system is Arch-based so we can't compare it directly with\nDebian/rules. Thank you for an idea about /dev/shm , although I would\nlike to clarify that while it *might* be what is failing this\nparticular test - the causes of failure at .out files are different as\nwe could see by the prior 0300/0301/0302 and some future tests (could\nshare more logs if needed). But the external appearance of these\nerrors (Username/Password prompts) is similar to a user and that may\nindicate some common pattern between the problems, i.e. maybe there is\nsome extra shell precaution needed on some systems (although I'm a bit\npuzzled why my distro's packager seemingly didn't have such an issue).\nI am still trying to build with skipping as few tests as possible, at\nthe moment I have to skip the following: t0300 t0301 t0302 t5003 t5411\nt5540 t5541 t5550 t5551 t5559 t5563 t5564 (adding them to\nGIT_SKIP_TESTS one-by-one, maybe there'd be more)\n"},{"id":"538047","messageId":"CAAaskFCNCE9tgoYOLQYJRjxreFjyw0jpvBkxADXJtwHYRx50rQ@mail.gmail.com","threadId":"65147","inReplyTo":"CAAaskFC0WETe7NaEfznW-h53Huee2sLLAQYWBA3moLpeULhtcA@mail.gmail.com","subject":"Re: Test \"t0300-credentials\" is failing on Arch/Artix: asks to enter the Username/Password in an infinite loop","fromName":"Ivan Ivanov","fromEmail":"qmastery16@gmail.com","sentAt":"2026-03-06T02:19:50Z","receivedAt":"2026-03-06T02:20:04Z","isPatch":false,"sender":{"key":"qmastery16@gmail.com","avatar":null},"body":"I.e. test 5564 \"t5564-http-proxy.out\" output may be interesting:\n(during that I got asked \"Password for\n'http://proxuser@127.0.0.1:5564\" on a prompt, after pressing enter the\ntests continued to the next ones)\n\nnot ok 5 - clone can prompt for proxy password\n#\n#        test_when_finished \"rm -rf clone\" &&\n#        test_config_global http.proxy http://proxuser@$HTTPD_DEST &&\n#        set_askpass nobody proxpass &&\n#        GIT_TRACE_CURL=$PWD/trace git clone $HTTPD_URL/smart/repo.git clone &&\n#        expect_askpass pass proxuser\n#\n\nchecking prerequisite: SOCKS_PROXY\n\nmkdir -p \"$TRASH_DIRECTORY/prereq-test-dir-SOCKS_PROXY\" &&\n(\n    cd \"$TRASH_DIRECTORY/prereq-test-dir-SOCKS_PROXY\" &&\n    test_have_prereq PERL &&\n    start_socks \"$TRASH_DIRECTORY/%30.sock\"\n\n)\nprerequisite SOCKS_PROXY ok\nexpecting success of 5564.6 'clone via Unix socket':\n    test_when_finished \"rm -rf clone\" &&\n    test_config_global http.proxy \"socks4://localhost$PWD/%2530.sock\" && {\n        {\n            GIT_TRACE_CURL=$PWD/trace \\\n            GIT_TRACE_CURL_COMPONENTS=socks \\\n            git clone \"$HTTPD_URL/smart/repo.git\" clone 2>err &&\n            grep -i \"SOCKS4 request granted\" trace\n        } ||\n        old_libcurl_error err\n    }\n\n== Info: [SOCKS] SOCKS4 request granted.\n\nOn Fri, Mar 6, 2026 at 5:14 AM Ivan Ivanov <qmastery16@gmail.com> wrote:\n>\n> Brian, thank you very much for checking my logs: indeed, unfortunately\n> my system is Arch-based so we can't compare it directly with\n> Debian/rules. Thank you for an idea about /dev/shm , although I would\n> like to clarify that while it *might* be what is failing this\n> particular test - the causes of failure at .out files are different as\n> we could see by the prior 0300/0301/0302 and some future tests (could\n> share more logs if needed). But the external appearance of these\n> errors (Username/Password prompts) is similar to a user and that may\n> indicate some common pattern between the problems, i.e. maybe there is\n> some extra shell precaution needed on some systems (although I'm a bit\n> puzzled why my distro's packager seemingly didn't have such an issue).\n> I am still trying to build with skipping as few tests as possible, at\n> the moment I have to skip the following: t0300 t0301 t0302 t5003 t5411\n> t5540 t5541 t5550 t5551 t5559 t5563 t5564 (adding them to\n> GIT_SKIP_TESTS one-by-one, maybe there'd be more)\n"},{"id":"538051","messageId":"20260306043821.GA3465674@coredump.intra.peff.net","threadId":"65147","inReplyTo":"CAAaskFC0WETe7NaEfznW-h53Huee2sLLAQYWBA3moLpeULhtcA@mail.gmail.com","subject":"Re: Test \"t0300-credentials\" is failing on Arch/Artix: asks to enter the Username/Password in an infinite loop","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2026-03-06T04:38:21Z","receivedAt":"2026-03-06T04:38:28Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Fri, Mar 06, 2026 at 05:14:12AM +0300, Ivan Ivanov wrote:\n\n> Brian, thank you very much for checking my logs: indeed, unfortunately\n> my system is Arch-based so we can't compare it directly with\n> Debian/rules. Thank you for an idea about /dev/shm , although I would\n> like to clarify that while it *might* be what is failing this\n> particular test - the causes of failure at .out files are different as\n> we could see by the prior 0300/0301/0302 and some future tests (could\n> share more logs if needed). But the external appearance of these\n> errors (Username/Password prompts) is similar to a user and that may\n> indicate some common pattern between the problems, i.e. maybe there is\n> some extra shell precaution needed on some systems (although I'm a bit\n> puzzled why my distro's packager seemingly didn't have such an issue).\n\nThe inability to exec scripts in the test directory is the cause of all\nof the username/password prompts. What's supposed to happen is:\n\n  1. The test script creates a script called \"askpass\" in the temporary\n     test directory, and sets its executable bit. That script just\n     returns a dummy response on its stdout.\n\n  2. It then sets the GIT_ASKPASS variable to point to that askpass\n     script.\n\n  3. When Git needs a username/password, it tries (and this is in the\n     git_prompt() function prompt.c):\n\n       a. It runs the askpass program specified by $GIT_ASKPASS.\n\n       b. If that doesn't return a password, it prompts on the terminal\n\t  using either getpass() or by opening /dev/tty directly\n\t  (depending on your platform).\n\nSince we've set $GIT_ASKPASS, we expect it to stop at 3a, returning that\nvalue.\n\nBut on your system, running askpass doesn't work (I agree with brian's\nguess that it is probably because /dev/shm is mounted with noexec). And\nso we jump to 3b, prompting on the terminal. If you just hit enter, then\nit will not get the expected value; while it may keep running, it's not\ngoing to work. If you manually typed the same response there that\naskpass would have provided, the test would probably succeed.\n\nBut of course that's silly. The right solution is to use a temporary\ndirectory that allows execution of scripts. And I would expect there to\nbe a ton of other test failures, too, as many of the tests write helper\nscripts and such.\n\nThe culprit is the use of --root=/dev/shm here in the package config:\n\n  https://gitlab.archlinux.org/archlinux/packaging/packages/git/-/blob/main/PKGBUILD?ref_type=heads#L71\n\nIt's reasonable to point it at a RAM disk (Git's test suite does a lot\nof file I/O that gets thrown away, so running on a RAM disk can be much\nfaster). But it has to be a fully capable filesystem, not one mounted\nwith noexec. You might want to alert the package maintainer.\n\n-Peff\n\nPS There's one other related tidbit I noticed. These days we have a\n   $GIT_TERMINAL_PROMPT variable that tells Git not to access the\n   terminal at all. If that were set to \"0\" then the broken tests would\n   not prompt you at all. They'd still be _broken_, because askpass\n   would not give the result they expected, but at least they wouldn't\n   spam your terminal with prompts.\n\n   It might be worth putting GIT_TERMINAL_PROMPT=0 in test-lib.sh, just\n   to prevent accidental breakage from becoming too annoying. We didn't\n   do it when t0300 and friends were written because GIT_TERMINAL_PROMPT\n   didn't exist back then.\n"},{"id":"538077","messageId":"CAAaskFD7wmtqppatb5T5GMTviieR0Ttk9y4+c3khuF3bZBfE=g@mail.gmail.com","threadId":"65147","inReplyTo":"20260306043821.GA3465674@coredump.intra.peff.net","subject":"Re: Test \"t0300-credentials\" is failing on Arch/Artix: asks to enter the Username/Password in an infinite loop","fromName":"Ivan Ivanov","fromEmail":"qmastery16@gmail.com","sentAt":"2026-03-06T14:14:45Z","receivedAt":"2026-03-06T14:14:59Z","isPatch":false,"sender":{"key":"qmastery16@gmail.com","avatar":null},"body":"Friends, thank you so much for your kind help! Indeed: it turned out\nthat if /dev/shm is mounted with noexec then \"--root=/dev/shm\" is\nfailing. If you would like to ensure that the git tests are succeeding\nregardless of what are the mount flags on some system or what some\ndistro's packagers are doing (more portability), maybe it is possible\nto modify the git test system - to make it so that \"askpass\" always\ngets launched from a native original directory, instead of being\ncopied to some \"root\" place where it could fail?\n\nBy the way I have completed a git packaging build: just these 12\nmentioned tests are failing, everything else is fine. So for me atm\nthe possible workarounds are either GIT_SKIP_TESTS='t0300 t0301 t0302\nt5003 t5411 t5540 t5541 t5550 t5551 t5559 t5563 t5564', or \"mkdir -p\n/tmp/git-test\" then GIT_TEST_OPTS=\"--root=/tmp/git-test --verbose-log\"\ninstead of a /dev/shm/git-test\n"},{"id":"538089","messageId":"20260306160131.GA3577004@coredump.intra.peff.net","threadId":"65147","inReplyTo":"CAAaskFD7wmtqppatb5T5GMTviieR0Ttk9y4+c3khuF3bZBfE=g@mail.gmail.com","subject":"Re: Test \"t0300-credentials\" is failing on Arch/Artix: asks to enter the Username/Password in an infinite loop","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2026-03-06T16:01:31Z","receivedAt":"2026-03-06T16:01:34Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Fri, Mar 06, 2026 at 05:14:45PM +0300, Ivan Ivanov wrote:\n\n> Friends, thank you so much for your kind help! Indeed: it turned out\n> that if /dev/shm is mounted with noexec then \"--root=/dev/shm\" is\n> failing. If you would like to ensure that the git tests are succeeding\n> regardless of what are the mount flags on some system or what some\n> distro's packagers are doing (more portability), maybe it is possible\n> to modify the git test system - to make it so that \"askpass\" always\n> gets launched from a native original directory, instead of being\n> copied to some \"root\" place where it could fail?\n\nit would be possible to do that, but introduce a lot of complexity.\nRight now test scripts are given a single temporary scratch directory\nwith a repo to do whatever they want with. If we gave each one _two_\ndirectories, one for putting executable things and one for repo\noperations, then the latter could be on a noexec filesystem.\n\nBut why do we want to support pointing --root to a noexec filesystem in\nthe first place? I think this falls into \"if it hurts, don't do it\".\n\n-Peff\n"},{"id":"538095","messageId":"CAAaskFBNBEiPW4tLRtPQqkntHFpDTgjwrx8Lqg-qax1Cb_mEhQ@mail.gmail.com","threadId":"65147","inReplyTo":"20260306160131.GA3577004@coredump.intra.peff.net","subject":"Re: Test \"t0300-credentials\" is failing on Arch/Artix: asks to enter the Username/Password in an infinite loop","fromName":"Ivan Ivanov","fromEmail":"qmastery16@gmail.com","sentAt":"2026-03-06T17:36:35Z","receivedAt":"2026-03-06T17:36:48Z","isPatch":false,"sender":{"key":"qmastery16@gmail.com","avatar":null},"body":"Sounds reasonable, but - if there is only an issue with askpass and\neverything else is fine, couldn't we just execute askpass from its\norigin - instead of copying it to the destination ./git-test/\ndirectory?\n\nOn Fri, Mar 6, 2026 at 7:01 PM Jeff King <peff@peff.net> wrote:\n>\n> On Fri, Mar 06, 2026 at 05:14:45PM +0300, Ivan Ivanov wrote:\n>\n> > Friends, thank you so much for your kind help! Indeed: it turned out\n> > that if /dev/shm is mounted with noexec then \"--root=/dev/shm\" is\n> > failing. If you would like to ensure that the git tests are succeeding\n> > regardless of what are the mount flags on some system or what some\n> > distro's packagers are doing (more portability), maybe it is possible\n> > to modify the git test system - to make it so that \"askpass\" always\n> > gets launched from a native original directory, instead of being\n> > copied to some \"root\" place where it could fail?\n>\n> it would be possible to do that, but introduce a lot of complexity.\n> Right now test scripts are given a single temporary scratch directory\n> with a repo to do whatever they want with. If we gave each one _two_\n> directories, one for putting executable things and one for repo\n> operations, then the latter could be on a noexec filesystem.\n>\n> But why do we want to support pointing --root to a noexec filesystem in\n> the first place? I think this falls into \"if it hurts, don't do it\".\n>\n> -Peff\n"},{"id":"538115","messageId":"aatEZfGPkZTVT4uJ@fruit.crustytoothpaste.net","threadId":"65147","inReplyTo":"CAAaskFBNBEiPW4tLRtPQqkntHFpDTgjwrx8Lqg-qax1Cb_mEhQ@mail.gmail.com","subject":"Re: Test \"t0300-credentials\" is failing on Arch/Artix: asks to enter the Username/Password in an infinite loop","fromName":"brian m. carlson","fromEmail":"sandals@crustytoothpaste.net","sentAt":"2026-03-06T21:17:25Z","receivedAt":"2026-03-06T21:17:27Z","isPatch":false,"sender":{"key":"sandals@crustytoothpaste.net","avatar":"https://avatars.githubusercontent.com/u/497054?v=4"},"body":"On 2026-03-06 at 17:36:35, Ivan Ivanov wrote:\n> Sounds reasonable, but - if there is only an issue with askpass and\n> everything else is fine, couldn't we just execute askpass from its\n> origin - instead of copying it to the destination ./git-test/\n> directory?\n\nWe actually do generate and run quite a few scripts in the testsuite\n(`git grep write_script`).  All of these will be generated in the trash\ndirectory we create for each test and some of them contain dynamic\ncomponents that cannot be generated before the testsuite is run.\n\nIt may be, for whatever reason, that only those tests happen to\nmalfunction in this case, but we're not willing to do the testing and\nmaintenance required to guarantee that the testsuite works in a noexec\nenvironment.  There are some cases where we accept patches to deal with\nuncommon cases (for instance, I send in patches to fix the testsuite\nwith zsh in sh mode from time to time), but I think this is a case where\nwe fully expect things to be very broken (at least I do) and the amount\nof effort required to fix it would be substantial.\n\nI am sympathetic to the downsides of noexec temporary directories\nbecause I've worked on systems where `/tmp` was noexec, but we assume\nthat most people on Unix systems have at least a home directory where\nthey can execute things (if for no other reason than the customary\n`~/bin` directory).\n-- \nbrian m. carlson (they/them)\nToronto, Ontario, CA\n"}]}