I have a Mercurial repository that is converted from Subversion using hgsubversion
. This is a continuous process that happens by cron
job.
Since the Subversion repo is still authoritative, all of the Mercurial clones are considered read-only (which is enforced via hooks as well).
I can clone/pull from this converted repo without problems. However, due to certain constraints in bandwidth, we also put up a clone of the initial conversion (originally created via a bundle) at a remote site.
In addition I have a local clone of the converted repo from which I attempt to push to my remote clone of the original.
Roughly:
["Original"] --------> [My local clone] --------> [Remote clone from bundle]
^
|
|
[SVN]
Now, whenever I try to push to Remote clone from bundle
, I get (redacted for privacy reasons):
$ hg push --new-branch shortname
pushing to ssh://user@server//hg/repo
searching for changes
searching for changes
abort: push creates multiple headed new branch 'branch_name'
(merge or see "hg help push" for details about pushing new heads)
If I package the changes present at the remote end into a conventional bundle, using hg bundle
and scp
them over to the remote site and apply them there, this works without problem as well.
Questions
- Why does this fail?
- How do I overcome the problem in order to push successfully?
With --force
I get, btw:
$ hg push --force --new-branch shortname
pushing to ssh://user@server//hg/repo
searching for changes
searching for changes
abort: Invalid argument
Exception IOError: (22, 'Invalid argument') in <bound method lfileswirerepository.cleanup of <hgext.largefiles.proto.lfileswirerepository object at 0x00000000025BE5C0>> ignored