Mercurial > evolve
view docs/troubles-handling.rst @ 5487:7c543787d5c6
unstable-list: add a simple entry for the simplest orphan case
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Fri, 14 Aug 2020 18:01:53 +0200 |
parents | 381df06460e8 |
children | 9920e8b4756d |
line wrap: on
line source
.. Copyright 2020 Sushil Khanchi <sushilkhanchi97@gmail.com> .. Octobus SAS <contact@octobus.net> ----------------------------------------------------------- Possible troubles in rewriting history and their resolution ----------------------------------------------------------- Rewriting history, and especially rewriting draft history that have been exchanged can lead to "unstable" situation. This document is intended for developer of the changeset evolution concept. It cover through the technical aspects of each "instability" a changeset can get into. A aims at building an exhaustive list of each cases and sub-cases and the status of automatic resolution for these cases. Public changeset are part of the permanent history and are never considered unstable. Orphan ######### Basics ****** A changeset is orphan when there is at least one obsolete ancestor. As a resolution, we need to find a new appropriate parents for the changeset and rebase the orphan there. If the parents of an orphan changeset are orphan themself, they will have to be "stabilised" fist. Cause of trouble **************** Orphan can appears because the use locally rewrite changeset with descendants. In this case the orphan are created when the command run. Orphan can also happens when the users created new changeset on draft that got rewritten in another repository. The orphan are then "discovered" when the obsolescence information of the ancestors is pulled in the local repository. Source of Complexity ******************** There can be different situations we need to take care of when dealing with resolution of an orphan changeset, like: * parents might not be obsolete (yet) and orphan themself. They will need to be resolved first. * obsolete parent has conflicting rewrites (content-divergence), so there might not be an obvious "good spot" to rebase the changeset too. * obsolete parent could have been prune, so it has not direct successors, * obsolete parent was split in multiple changesets. This comes with multiple variants: * successors could be linear of spread accross multiple branches, * successors could have been reordered after the initial split, * Some of the successors could have been pruned. * the orphan changeset can be a merge and orphan may come any numbers of parents * rebasing might lead to conflict. Details of Sub cases ******************** O-A: Linear changeset (one parent) ================================== O-A1: parent has a single successors ------------------------------------ Stabilisation Strategy """""""""""""""""""""" Solution is Clear. Relocate the orphan changeset onto the single successor of obsolete parent. Current Support Level """"""""""""""""""""" Good: current implementation is expected to perform the planed stabilisation. Phase-Divergence ################## Basics ****** Cause of trouble **************** Source of Complexity ******************** Details of Sub cases ******************** Content-Divergence ################## Basics ****** Cause of trouble **************** Source of Complexity ******************** Details of Sub cases ********************