debugobsolete: catch ValueError that may be raised by obsstore.create

There are already a couple of errors that obsstore.create can raise and we are
going to introduce a cycle check too.

--HG--
branch : stable
obsstore.create: add a simple safeguard against cyclic markers

We detect when there is a cycle in the marker itself (precursors being listed
as successors).

--HG--
branch : stable
discovery: prevent crash on unknown remote heads with old repo (issue4337)

When a remote is not capable of the `branchmap` wireproto command, we denote
incoming heads with None. This leads to a crash in the code in charge of
displaying the list of unknown remote heads.

We now properly detect this case and display a shorter message in this case.

The reason for this  `set([None])` value is now documented.

--HG--
branch : stable
merge: show the scary multiple ancestor hint for merges only, not for updates

Updates with uncommited changes will always only have one ancestor - the parent
revision. Updates between existing revision should (and will) always give the
same result no matter which ancestor is used. The warning is thus only relevant
when doing a "real" merge.

--HG--
branch : stable
changectx: ancestor should only prefer merge.preferancestor if it is a revision

The value '*' currently designates that bid merge should be used. The best
way to test bid merge is to set preferancestor=* in the configuration file ...
but then it would abort with unknown revision '*' when other code paths ended
up in changectx.ancestor .

Instead, just skip and ignore the value '*' when looking for a preferred
ancestor.

--HG--
branch : stable
tests: improve test coverage for discovery and actual parameters for pulling

--HG--
branch : stable
incoming: don't request heads that already are common

Pull would send a getbundle command where common heads were sent both as common
and head, even though there is no reason to request a common head.
The request was thus twice as big as necessary and more likely to hit HTTP
header size limits.

Instead, don't request heads that already are common.

This is fixed in bundlerepo.getremotechanges . It could perhaps also have been
fixed in discovery.findcommonincoming but that would have a bigger impact.

--HG--
branch : stable