From: "brian m. carlson" <sandals@crustytoothpaste.net>
To: Amogh Dambal <amoghdambal1@gmail.com>
Cc: Jeff King <peff@peff.net>, Michael Montalbo <mmontalbo@gmail.com>,
git@vger.kernel.org
Subject: Re: Expected test suite behavior
Date: Tue, 26 May 2026 00:41:48 +0000 [thread overview]
Message-ID: <ahTsTDhVPkHTEbB_@fruit.crustytoothpaste.net> (raw)
In-Reply-To: <4649049a-ded5-4cc6-bc2b-d5f543e6df99@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 2679 bytes --]
On 2026-05-25 at 22:25:11, Amogh Dambal wrote:
> > What are the OS and file system on the host? We tend to see
> > executable bits set when NTFS, FAT, or other Windows-adjacent file
> > systems are used on Linux and you're mounting `$(PWD)` into the
> > container as a volume.
>
> Ah, this is a smoking gun. I'm not on a Windows-adjacent file system; I'm
> running macOS Sequoia 15.5 on the host. Specifically:
>
> $ uname -msprsv
> Darwin 24.5.0 Darwin Kernel Version 24.5.0: Tue Apr 22 19:54:26 PDT 2025;
> root:xnu-11417.121.6~2/RELEASE_ARM64_T8112 arm64 arm
>
> But I am mounting $(PWD) into the container as a volume.
I wouldn't expect that to be a problem, then. macOS uses Unix-style
permissions and I've never seen odd permissions behaviour mounting a
macOS APFS file system into a container. I will, however, note that I
am using a case-sensitive APFS volume, but I cannot imagine how this
would occur with _any_ macOS APFS volume mounted into a Linux container.
> > Git doesn't use `/tmp` for most files in the tests. Those are stored
> > under `t/`, so you'd want to create your test directory there.
>
> ACK, good to know, thanks! I am still seeing the same behavior with a
> `debug` directory under `t/`:
>
> root@ec94ab1b260e:~/git/t/debug# /root/git/git init plain
> root@ec94ab1b260e:~/git/t/debug# ls -alhrt
> /root/git/t/debug/plain/.git/config
> -rw-r--r-- 1 root root 111 May 25 22:24 /root/git/t/debug/plain/.git/config
I think I know what the problem is: you're running as root. I suspect
`test -x` in the test says that you have permission to execute it
because you're root and root always ignores permissions. My guess is
that most of the tests you're failing have to do with permissions of
some sort that are being ignored because you're privileged.
In general, you would not want to run this as root. Use `adduser` to
create yourself a regular user and then use the `USER` directive in the
Dockerfile to change users. I don't run the tests as root and I'm sure
none of the other regular contributors do, either. Running unprivileged
in a container is a best practice anyway.
I'll just note that if you just want to do Git development, macOS is a
fully supported platform on which to do that. I will admit most of the
major contributors (with the notable exception of the Git for Windows
maintainer) do use Linux and of course I like and endorse Debian, but
macOS should build and run just fine if you prefer that.
But if you do want to use a container, I'd try unprivileged and see if
substantially more of the tests pass.
--
brian m. carlson (they/them)
Toronto, Ontario, CA
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 325 bytes --]
next prev parent reply other threads:[~2026-05-26 0:41 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-25 6:20 Expected test suite behavior Michael Montalbo
2026-05-25 7:27 ` Jeff King
2026-05-25 22:01 ` Amogh Dambal
2026-05-25 22:18 ` brian m. carlson
2026-05-25 22:25 ` Amogh Dambal
2026-05-26 0:41 ` brian m. carlson [this message]
2026-05-26 1:11 ` Junio C Hamano
-- strict thread matches above, loose matches on Subject: below --
2026-05-25 5:38 Amogh Dambal
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ahTsTDhVPkHTEbB_@fruit.crustytoothpaste.net \
--to=sandals@crustytoothpaste.net \
--cc=amoghdambal1@gmail.com \
--cc=git@vger.kernel.org \
--cc=mmontalbo@gmail.com \
--cc=peff@peff.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox