unisonweb/unison

externally updated `_head` isn't detected in `ucm`

Open

#886 ouverte le 23 oct. 2019

Voir sur GitHub
 (0 commentaires) (0 réactions) (0 assignés)Haskell (304 forks)batch import
bugcodebase-manager / ucmhelp wanted

Métriques du dépôt

Stars
 (6 624 stars)
Métriques de merge PR
 (Merge moyen 10j 2h) (5 PRs mergées en 30 j)

Description

This can cause weirdness if there are two instances of ucm running backed by the same codebase.

I think the code to do anything about it is commented out (which we should fix) but there is code to display a warning, which also isn't firing.

If the external change leaves multiple heads, ucm should first:

  • issue a message to the console, including the short hashes of the previous loopstate root hash, and of the newly detected heads (see reflog implementation for example of printing short hashes).
  • merge the multiple heads (Branch.merge?)

Then (multiple heads or single head), ucm should:

  • write the external change to the reflog
  • update LoopState

Guide contributeur