This commit is contained in:
jacksondm33@cf6e91518a0fa6a05945d5d4e03ae770f6383615 2023-06-14 22:06:10 +00:00 committed by admin
parent 80106ad534
commit 276c964a9f

View file

@ -0,0 +1,69 @@
### Please describe the problem.
The git annex assistant committer stops working and crashes under certain circumstances when dealing with small files.
This seems to occur when a small file is in the committer queue but is deleted before the queue is flushed.
### What steps will reproduce the problem?
Set the `annex.largefiles` option to exclude certain files from the annex: `git config annex.largefiles 'exclude=*.txt'`.
Create and immediately delete some file that is excluded from the annex:
[[!format sh """
touch somefile.txt && rm somefile.txt
"""]]
This will cause a "user error" to occur every time the committer thread tries to do a commit, essentially causing it to stop working.
In addition, if no file activity occurs for 5 minutes, creating another file will cause the committer to crash:
[[!format sh """
sleep 310
touch someotherfile.txt
"""]]
### What version of git-annex are you using? On what operating system?
Operating system: Arch Linux x86_64
git-annex version: 10.20230329
### Please provide any additional information below.
[[!format sh """
# .git/annex/daemon.log
[2023-06-14 17:32:42.652269404] (Watcher) add somefile.txt
[2023-06-14 17:32:42.652761285] (Watcher) add somefile.txt
[2023-06-14 17:32:42.652832039] (Watcher) file deleted somefile.txt
[2023-06-14 17:32:42.663222161] (Utility.Process) process [1178267] read: lsof ["-F0can","+d",".git/annex/watchtmp/"]
[2023-06-14 17:32:42.830892116] (Utility.Process) process [1178267] done ExitFailure 1
[2023-06-14 17:32:42.831219136] (Utility.Process) process [1178269] feed: git ["--git-dir=.git","--work-tree=.","--literal-pathspecs","-c","annex.debug=true","update-index","-z","--index-info"]
[2023-06-14 17:32:42.832078397] (Utility.Process) process [1178269] done ExitSuccess
[2023-06-14 17:32:42.832140832] (Committer) committing 2 changes
(recording state in git...)
[2023-06-14 17:32:42.832442128] (Utility.Process) process [1178270] feed: xargs ["-0","git","--git-dir=.git","--work-tree=.","--literal-pathspecs","-c","annex.debug=true","add","--force","--"]
fatal: pathspec 'somefile.txt' did not match any files
[2023-06-14 17:32:42.833714128] (Utility.Process) process [1178270] done ExitFailure 123
[2023-06-14 17:33:10.166497909] (Utility.Process) process [1178219] done ExitSuccess
[2023-06-14 17:33:10.167361436] (Utility.Process) process [1178207] done ExitSuccess
[2023-06-14 17:33:10.168264148] (Utility.Process) process [1178218] done ExitSuccess
[2023-06-14 17:33:10.16909154] (Utility.Process) process [1178238] done ExitSuccess
[2023-06-14 17:33:10.169892592] (Utility.Process) process [1178240] done ExitSuccess
[2023-06-14 17:33:10.170694357] (Utility.Process) process [1178227] done ExitFailure 1
[2023-06-14 17:33:40.185689237] (Utility.Process) process [1178330] read: git ["--git-dir=.git","--work-tree=.","--literal-pathspecs","-c","annex.debug=true","ls-tree","--full-tree","-z","--","refs/heads/git-annex","uuid.log","remote.log","trust.log","group.log","numcopies.log","mincopies.log","schedule.log","preferred-content.log","required-content.log","group-preferred-content.log"]
[2023-06-14 17:33:40.189177926] (Utility.Process) process [1178330] done ExitSuccess
[2023-06-14 17:37:52.65735194] (Utility.Process) process [1178648] chat: git ["--git-dir=.git","--work-tree=.","--literal-pathspecs","-c","annex.debug=true","cat-file","--batch-check=%(objectname) %(objecttype) %(objectsize)"]
[2023-06-14 17:37:52.660710625] (Utility.Process) process [1178649] chat: git ["--git-dir=.git","--work-tree=.","-c","annex.debug=true","check-ignore","-z","--stdin","--verbose","--non-matching"]
[2023-06-14 17:37:52.663100743] (Watcher) add someotherfile.txt
[2023-06-14 17:37:52.663984987] (Watcher) add someotherfile.txt
[2023-06-14 17:37:52.674996448] (Utility.Process) process [1178650] read: lsof ["-F0can","+d",".git/annex/watchtmp/"]
[2023-06-14 17:37:52.825736165] (Utility.Process) process [1178650] done ExitFailure 1
[2023-06-14 17:37:52.826111004] (Utility.Process) process [1178652] feed: xargs ["-0","git","--git-dir=.git","--work-tree=.","--literal-pathspecs","-c","annex.debug=true","add","--force","--"]
fatal: pathspec 'somefile.txt' did not match any files
[2023-06-14 17:37:52.82750231] (Utility.Process) process [1178652] done ExitFailure 123
Committer crashed: user error (xargs ["-0","git","--git-dir=.git","--work-tree=.","--literal-pathspecs","-c","annex.debug=true","add","--force","--"] exited 123)
# End of transcript or log.
"""]]