[ET Trac] #2943: Formaline rejects valid symlinks in GRHayLib

Zach Etienne trac-noreply at einsteintoolkit.org
Thu May 14 12:47:12 CDT 2026


#2943: Formaline rejects valid symlinks in GRHayLib

 Reporter: Zach Etienne
   Status: new
Milestone: 
  Version: 
     Type: bug
 Priority: major
Component: 

Formaline emits warnings while creating/updating the configuration git repository when a thorn contains symbolic links, for example in `GRHayL/GRHayLib/src`:

```text
Formaline: Creating configuration git repository...
Formaline: Updating files in git repository...
WARNING: Refusing to add "arrangements/GRHayL/GRHayLib/src/Neutrinos" as it is not a regular file at Cactus/configs/etbhahaha/scratch/Formaline/bin/update-git-repo.pl line 202, <STDIN> line 6246.
...
fatal: bad revision 'HEAD'
Formaline: Committing source tree to git repository...
```

The full set of warnings occurs for the symlinked `GRHayLib/src` entries such as `Neutrinos`, `Induction`, `Flux_Source`, `Reconstruction`, `Atmosphere`, `EOS`, `include`, `GRHayL_Core`, and `Con2Prim`.

**Root Cause**

`Formaline/src/util/update-git-repo.pl` currently accepts only regular files before adding paths to the Formaline git repository:

```perl
if (! -e $file) {
  push @to_remove, $file;
  next;
} elsif (! -f $file) {
  warn "WARNING: Refusing to add \"$file\" as it is not a regular file";
  next;
}
```

This rejects valid symbolic links, including symlinks to directories. The listed `GRHayLib/src/*` entries are symlinks, not broken paths, so they should be represented in the Formaline git snapshot instead of being skipped.

Git represents symlinks as mode `120000` blobs containing the link target. Formaline’s fallback path already uses `git update-index --cacheinfo` when hard-link staging fails, so symlinks need corresponding handling there rather than being rejected by the regular-file check.

**Fix Available**

The issue is fixed by this pull request, which is ready for review:

https://bitbucket.org/cactuscode/cactusutils/pull-requests/46

**Expected Behavior**

Formaline should preserve valid symbolic links in its git source snapshot. Broken symlinks should still produce a warning.

**Suggested Resolution**

Review and merge:

https://bitbucket.org/cactuscode/cactusutils/pull-requests/46

--
Ticket URL: https://bitbucket.org/einsteintoolkit/tickets/issues/2943/formaline-rejects-valid-symlinks-in
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.einsteintoolkit.org/pipermail/trac/attachments/20260514/55b88c59/attachment.htm>


More information about the Trac mailing list