fix --all to include not yet committed files from the journal
authorJoey Hess <joeyh@joeyh.name>
Wed, 21 Apr 2021 19:40:32 +0000 (15:40 -0400)
committerJoey Hess <joeyh@joeyh.name>
Wed, 21 Apr 2021 19:40:32 +0000 (15:40 -0400)
commit653b7194727a27dfd185cdb0b752f8e190250fc4
treed0aa08db2aa5ebfa3f8fff7b98b1d3106e5b0679
parent74acf17a3158938c8034fdf58e5b05cfdabb8b9f
fix --all to include not yet committed files from the journal

Fix bug caused by recent optimisations that could make git-annex not see
recently recorded status information when configured with
annex.alwayscommit=false.

This does mean that --all can end up processing the same key more than once,
but before the optimisations that introduced this bug, it used to also behave
that way. So I didn't try to fix that; it's an edge case and anyway git-annex
behaves well when run on the same key repeatedly.

I am not too happy with the use of a MVar to buffer the list of files in the
journal. I guess it doesn't defeat lazy streaming of the list, if that
list is actually generated lazily, and anyway the size of the journal is
normally capped and small, so if configs are changed to make it huge and
this code path fire, git-annex using enough memory to buffer it all is not a
large problem.
Annex/Branch.hs
CmdLine/Seek.hs
doc/bugs/git-annex_branch_caching_bug.mdwn
doc/todo/hiding_a_repository.mdwn