Simon Josefsson via "Development of GNU Guix and the GNU System distribution." <[email protected]> writes:
>> It's true that for example if you had the repo cloned, did `git pull` >> with a commit that doesn't authenticate, then there is a force push, >> afterwards `git pull` won't work anymore. Is this what you mean, is >> there more maybe? > > Yes, I meant what happens if a user runs 'git pull' in this situation. > What the error messages are, and how to recover. In case this happens > again, maybe a small example would help. Given that my mirror is still > stuck on the broken commit, I can see if I can experiment with what > happens and how to recover for future reference. If someone managed to pull the bad commit, here is what would happen: jas@kaka:~$ guix pull --url=https://gitlab.com/debdistutils/guix/mirror.git Updating channel 'guix' from Git repository at 'https://gitlab.com/debdistutils/guix/mirror.git'... guix pull: error: aborting update of channel 'guix' to commit a3a14c569380b4eefa33b7712d73efde87344110, which is not a descendant of c3d5c20b2c50c5f35721e62caa1cf35b9eb6fc68 hint: This could indicate that the channel has been tampered with and is trying to force a roll-back, preventing you from getting the latest updates. If you think this is not the case, explicitly allow non-forward updates. jas@kaka:~$ The error message doesn't say which parameter to use, and I couldn't find anything that allow non-forward updates so I tried --allow-downgrades which worked: jas@kaka:~$ guix pull --url=https://gitlab.com/debdistutils/guix/mirror.git --allow-downgrades Updating channel 'guix' from Git repository at 'https://gitlab.com/debdistutils/guix/mirror.git'... guix pull: warning: moving channel 'guix' from c3d5c20b2c50c5f35721e62caa1cf35b9eb6fc68 to unrelated commit a3a14c569380b4eefa33b7712d73efde87344110 Authenticating channel 'guix', commits 9edb3f6 to a3a14c5 (83 new commits)... guix pull: warning: pulled channel 'guix' from a mirror of https://git.guix.gnu.org/guix.git, which might be stale Building from this channel: guix https://gitlab.com/debdistutils/guix/mirror.git a3a14c5 substitute: updating substitutes from 'https://ci.guix.gnu.org'... 100.0% substitute: updating substitutes from 'https://ci.guix.gnu.org'... 100.0% ... So the recovery path seems to be --allow-downgrades if someone is stuck on a badly pushed commits that is overrided by a force push. /Simon
signature.asc
Description: PGP signature
