git-annex/doc/bugs/sync_does_not_propagate_forgetfulness.mdwn
Joey Hess 6992250d63
fix obviously wrong attoparsec parser
takeByteString can only be used at the end of a parser, not before other
input. This was a dumb enough mistake that I audited the rest of the
code base for similar mistakes. Pity that attoparsec cannot avoid it at
the type level.

Fixes git-annex forget propagation between repositories. (reversion
introduced in version 7.20190122)

Sponsored-by: Brock Spratlen on Patreon
2022-02-07 14:15:17 -04:00

35 lines
596 B
Markdown

After a `git-annex forget`, syncing with a remote that still has the
forgotten data in its git-annex branch merges that data right back in.
Reproduction script:
chmod -R +w bench 2>/dev/null
rm -rf bench 2>/dev/null
mkdir bench
cd bench
git init a
cd a
git-annex init
touch foo
git-annex add foo
git commit -m add
cd ..
git clone a b
cd b
git-annex get
git-annex drop
git-annex get
git-annex drop
cd ../a
git-annex sync
git-annex forget --force
git-annex sync
git-annex log foo
cd ../b
git-annex sync
cd ../a
git-annex log foo
--[[Joey]]
> [[fixed|done]] --[[Joey]]