complications

This commit is contained in:
Joey Hess 2021-05-21 14:18:38 -04:00
parent 1d9bad51d2
commit df0b75cdc4
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
2 changed files with 34 additions and 0 deletions

View file

@ -0,0 +1,9 @@
[[!comment format=mdwn
username="joey"
subject="""comment 10"""
date="2021-05-21T18:14:18Z"
content="""
There must also be the same problem for required content, and that should
also be fixed. Will be easy to do once the information is gathered
into the keys database.
"""]]

View file

@ -0,0 +1,25 @@
[[!comment format=mdwn
username="joey"
subject="""comment 9"""
date="2021-05-21T17:53:21Z"
content="""
There is overlap in the above plan with Database.Keys.reconcileStaged.
That already stats the index, and updates associated files for changes
made in the index. It does not handle locked files, and it only diffs
from the index to HEAD, so when git checkout is used, it does not
see those changes. (git runs the git-annex clean filter for those,
and that updates the associated files database, but that also only handles
unlocked files, not locked files).
reconcileStaged is run every time the keys db is opened,
so it runs perhaps more frequently than is needed for this. Although it
does not run in every command, or even most commands. Eg, find and whereis
do not use the keys db. It might be acceptable performance to do the
additional work there.
Also, handleDropsFrom queries the keys database for associated files
already, and actually already checks if the key is preferred content of
other files. So `git-annex sync --content`, which uses that, already
avoids the problem for unlocked files, but not for locked files.
`git annex drop` does not use that.
"""]]