hooks: print out more information when loading a python hook fails
When loading a python hook with file syntax fails, there is no
information that this happened while loading a hook. When the python
file does not exist even the file name is not printed. (Only that a
file is missing.)
This patch adds this information and a test for loading a non existing file and
a directory not being a python module.
perf: fix perfcca to work with new casecollisionauditor interface
A recent changeset,
afd75476939e, modified the caescollisionauditor interface
but did not update perf.py. This changeset remidies that.
checkheads: extract branchmap preprocessing
The checkheads function is far too complicated. This extract help to explicite
what part of the preprocessing are reused by the actual check.
This the first step toward a wider refactoring.
checkheads: take future obsoleted heads into account
If we push some successors they will likely create a new head on
remote. However as the obsoleted head will disappear after the push we
are not really increasing the number of heads.
There is several case which will lead to extra being actually pushed. But this
first changeset aims to be simple. See the inline comment for details.
Without this change, you need to push --force every time you want to
push a newer version which is very error prone.
The remote side still display +n heads on unbundle because it does not have the
obsolete marker at unbundle time.
obsolete: add an any successors function
This function yield every nodes which succeed to a group of nodes.
The first user will be checkheads who need to know if we push successors for
remote extra heads.
checkheads: extract bookmark computation from the branch loop
No branch specific data are used in the computation of the bookmarked heads. We
can only compute it once.
checkheads: simplify the structure build by preprocessing
All useful data are now gathered in a single dictionnary.
`branchmapsummary` is renamed to `headssummary` and its return value
is greatly simplified.