| Q | A |
|---|
| OS | macOS (aarch64-apple-darwin25.3.0) |
| Shell & version | bash 5.3.9(1)-release (nix-shell) |
| bashunit version | 0.43.0 |
Summary
7 test failures under nix-shell --pure on macOS with Bash 5.3. CI passes because macOS runners use Apple's Bash 3.2. Three bugs:
render_diff calls git diff without --no-ext-diff. This breaks for anyone with diff.external configured, e.g. I have difftastic configured. (2 failures)shell_time() uses LC_ALL=C inside $(). This results in a SIGSEGV on Bash 5.3 macOS (5 failures)- Syntax error test uses
LC_ALL=C inside $(). Same SIGSEGV (1 failure)
Bugs 2 and 3 share a root cause: Bash 5.3 on macOS segfaults when LC_ALL=C or LANG=C is used as a temporary env prefix inside a command substitution. Minimal reproducer:
# Bash 5.3.9(1)-release, aarch64-apple-darwin25.3.0
bash -c 'x=$(LC_ALL=C echo hello); echo exit=$?'# → exit=139 (SIGSEGV)
Current behavior
Tests: 7 failed, 1515 total
How to reproduce
nix-shell --pure --run "./bashunit --simple --parallel"
Requires the shell.nix in the repo root. The key ingredient is Bash 5.3 on macOS. Any setup that provides that will hit bugs 2 and 3. Bug 1 requires diff.external in git config (e.g. difftastic).
Expected behavior
All tests pass.
Summary
7 test failures under
nix-shell --pureon macOS with Bash 5.3. CI passes because macOS runners use Apple's Bash 3.2. Three bugs:render_diffcallsgit diffwithout--no-ext-diff. This breaks for anyone withdiff.externalconfigured, e.g. I have difftastic configured. (2 failures)shell_time()usesLC_ALL=Cinside$(). This results in a SIGSEGV on Bash 5.3 macOS (5 failures)LC_ALL=Cinside$(). Same SIGSEGV (1 failure)Bugs 2 and 3 share a root cause: Bash 5.3 on macOS segfaults when
LC_ALL=CorLANG=Cis used as a temporary env prefix inside a command substitution. Minimal reproducer:Current behavior
How to reproduce
nix-shell --pure --run "./bashunit --simple --parallel"Requires the
shell.nixin the repo root. The key ingredient is Bash 5.3 on macOS. Any setup that provides that will hit bugs 2 and 3. Bug 1 requiresdiff.externalin git config (e.g. difftastic).Expected behavior
All tests pass.