update
This commit is contained in:
parent
be8de26b68
commit
14c79373c4
2 changed files with 12 additions and 23 deletions
|
@ -60,8 +60,9 @@ have conflicting things pushed to it from different places. This mostly
|
||||||
works the same as any other git repository, eg a push that overwrites other
|
works the same as any other git repository, eg a push that overwrites other
|
||||||
work will be prevented unless forced. However, it is possible, when
|
work will be prevented unless forced. However, it is possible, when
|
||||||
conflicting pushes are being done at the same time, for one of the pushes
|
conflicting pushes are being done at the same time, for one of the pushes
|
||||||
to be overwritten by the other one. In this situation, the push will appear
|
to be overwritten by the other one. In this situation, the overwritten
|
||||||
to have succeeded, but pulling later will show the true situation.
|
push will appear to have succeeded, but pulling later will show the true
|
||||||
|
situation.
|
||||||
|
|
||||||
# SEE ALSO
|
# SEE ALSO
|
||||||
|
|
||||||
|
|
|
@ -37,26 +37,14 @@ This is implememented and working. Remaining todo list for it:
|
||||||
`datalad-annex::https://example.com?type=web&url={noquery}`
|
`datalad-annex::https://example.com?type=web&url={noquery}`
|
||||||
Supporting something like this would be good.
|
Supporting something like this would be good.
|
||||||
|
|
||||||
* Improve behavior in push races. A race can overwrite a change
|
* A push race can overwrite a manifest that had a GITBUNDLE added to it,
|
||||||
to the MANIFEST and lose work that was pushed from the other repo.
|
and so lose track of a GITBUNDLE. That will never get deleted.
|
||||||
From the user's perspective, that situation is the same as if one repo
|
|
||||||
pushed new work, then the other repo did a git push --force, overwriting
|
|
||||||
the first repo's push. In the first repo, another push will then fail as
|
|
||||||
a non fast-forward, and the user can recover as usual. This is probably
|
|
||||||
okish.
|
|
||||||
|
|
||||||
But.. a MANIFEST overwrite will leave bundle files in the remote that
|
Could git-annex detect this after the fact and clean it up? Eg,
|
||||||
are not listed in the MANIFEST. It seems likely that git-annex could
|
if it caches the last manifest it uploaded, the next time it downloads
|
||||||
detect that after the fact and clean it up. Eg, if it caches
|
the manifest it can check if there are bundle files in the old
|
||||||
the last MANIFEST it uploaded, next time it downloads the MANIFEST
|
one that are not in the new one. If so, it can add those to the
|
||||||
it can check if there are bundle files in the old one that are not
|
outManifest, to get dropped later.
|
||||||
in the new one. If so, it can drop those bundle files from the remote.
|
|
||||||
(May be unsafe, see below section on bundle deletion problems.)
|
|
||||||
|
|
||||||
* A push race can also appear to the user as if they pushed a ref, but then
|
This wouldn't fix the case where a push race happens and then the repo
|
||||||
it got deleted from the remote. This happens when two pushes are
|
whose manifest was overwritten gets deleted.
|
||||||
pushing different ref names. This might be harder for the user to
|
|
||||||
notice; git fetch does not indicate that a remote ref got deleted.
|
|
||||||
They would have to use git fetch --prune to notice the deletion.
|
|
||||||
Once the user does notice, they can re-push their ref to recover.
|
|
||||||
Can this be improved?
|
|
||||||
|
|
Loading…
Reference in a new issue