Merge branch 'master' of ssh://git-annex.branchable.com

This commit is contained in:
Joey Hess 2025-03-26 10:03:03 -04:00
commit 00cd389161
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
6 changed files with 120 additions and 0 deletions

View file

@ -0,0 +1,62 @@
When building git-annex 10.20250320 under `-f-assistant`, I hit into
the following error:
```
[363 of 647] Compiling Annex.ChangedRefs ( Annex/ChangedRefs.hs, /git-annex/dist-newstyle/build/x86_64-linux/ghc-9.8.4/git-annex-10.20250320/build/git-annex/git-annex-tmp/Annex/ChangedRefs.o, /git-annex/dist-newstyle/build/x86_64-linux/ghc-9.8.4/git-annex-10.20250320/build/git-annex/git-annex-tmp/Annex/ChangedRefs.dyn_o )
Annex/ChangedRefs.hs:96:48: error: [GHC-83865]
• Couldn't match type OS.ByteString with [Char]
Expected: FilePath
Actual: System.Posix.ByteString.FilePath.RawFilePath
• In the first argument of watchDir, namely refdir
In the second argument of ($), namely
watchDir refdir (const False) True hooks id
In a stmt of a 'do' block:
h <- liftIO $ watchDir refdir (const False) True hooks id
|
96 | h <- liftIO $ watchDir refdir
| ^^^^^^
```
If I drop the `-f-assistant`, the build completes successfully.
Alternatively, I was able to keep `-f-assistant` by un-indenting this
block from git-annex.cabal one level:
```
if os(linux)
Build-Depends: hinotify (>= 0.3.10)
CPP-Options: -DWITH_INOTIFY
Other-Modules: Utility.DirWatcher.INotify
else
if os(darwin)
Build-Depends: hfsevents
CPP-Options: -DWITH_FSEVENTS
Other-Modules:
Utility.DirWatcher.FSEvents
else
if os(windows)
Build-Depends: Win32-notify
CPP-Options: -DWITH_WIN32NOTIFY
Other-Modules: Utility.DirWatcher.Win32Notify
else
if (! os(solaris) && ! os(gnu) && ! os(linux))
CPP-Options: -DWITH_KQUEUE
C-Sources: Utility/libkqueue.c
Includes: Utility/libkqueue.h
Other-Modules: Utility.DirWatcher.Kqueue
```
I suspect that this is a general issue that anyone compiling without
the assistant feature enabled would encounter. Here are other details
of the setup in case they turn out to be relevant:
* Alpine Linux v3.21 image [*] with GHC 9.8.4
(<https://gitlab.com/benz0li/ghc-musl>)
* `cabal build` called with these flags:
- `--enable-executable-static`
- `--ghc-options="-j$n +RTS -A256m -RTS -split-sections -optc-Os -optl=-pthread"`
Full setup is at <https://git.kyleam.com/static-annex/>.

View file

@ -0,0 +1,23 @@
I have a fleet of some headless systems and some desktop machines. In the git tree there are somethimes commits like these. Time between the two commits is always more or less 10 seconds.
git diff c69f4ffee8d288174abe34db03e572c04bc8ba8b 5aceafda84e2d737a97f1e6b8f647adc6b787789
diff --git a/Dokumente/Gesamtrechnung.pdf b/Dokumente/Gesamtrechnung.pdf
deleted file mode 100644
index ace4b282de7..00000000000
--- a/Dokumente/Gesamtrechnung.pdf
+++ /dev/null
@@ -1 +0,0 @@
-/annex/objects/SHA256E-s22050--e1551117820028dc66e8c4d2e834857664535a4297ce9649a5cf40f7b9fafc66.pdf
git diff 5aceafda84e2d737a97f1e6b8f647adc6b787789 d3c6388f50e06a5dfae94cd2431c6b3827cee05a
diff --git a/Dokumente/Gesamtrechnung.pdf b/Dokumente/Gesamtrechnung.pdf
new file mode 100644
index 00000000000..ace4b282de7
--- /dev/null
+++ b/Dokumente/Gesamtrechnung.pdf
@@ -0,0 +1 @@
+/annex/objects/SHA256E-s22050--e1551117820028dc66e8c4d2e834857664535a4297ce9649a5cf40f7b9fafc66.pdf
Random files (one at a time) on random machines at random times are deleted and instantly recommitted. At least I think it happens randomly.
What happens here?

View file

@ -0,0 +1,8 @@
[[!comment format=mdwn
username="jnkl"
avatar="http://cdn.libravatar.org/avatar/2ab576f3bf2e0d96b1ee935bb7f33dbe"
subject="comment 1"
date="2025-03-23T11:20:31Z"
content="""
I looked at the timestamps and these commits could be the result of me doing something (I worked at these times), I don't know what I did to these files though. At least they didn't change (checksum din't change?).
"""]]

View file

@ -0,0 +1,8 @@
[[!comment format=mdwn
username="nobodyinperson"
avatar="http://cdn.libravatar.org/avatar/736a41cd4988ede057bae805d000f4f5"
subject="only for unlocked files?"
date="2025-03-24T18:37:31Z"
content="""
I also see this very frequently in our shared family documents folder. Several people having the assistant running. I have a feeling it only happens for unlocked files, suggesting git clean/smudge filter nonsense is causing this. Looks like your files are also unlocked. Do you see any of this with locked files?
"""]]

View file

@ -0,0 +1,8 @@
[[!comment format=mdwn
username="jnkl"
avatar="http://cdn.libravatar.org/avatar/2ab576f3bf2e0d96b1ee935bb7f33dbe"
subject="comment 3"
date="2025-03-25T07:44:00Z"
content="""
I think you are right. Only unlocked files.
"""]]

View file

@ -0,0 +1,11 @@
[[!comment format=mdwn
username="octvs@17a99a7aaeb0c0e0a2375e14807b138740ba34e9"
nickname="octvs"
avatar="http://cdn.libravatar.org/avatar/e31212348b6392eb67daddf78fadfb1b"
subject="failing with `Operation not petmitted`"
date="2025-03-24T17:56:39Z"
content="""
I also found the answer on my own.
The trick was hidden under my redaction. The filenames had special characters which are problematic under Android. Removing them solved the issue.
"""]]