Help with merging diverging work on HG

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Help with merging diverging work on HG

Filip Miletic-4
Hello all.

I was working on the Serbian translation of FF 3.1 in the Mercurial
repo.  I committed a few changes to the repo locally; and filed a
bugzilla ticket to get it approved.

Unfortunately, when I got the approval, the remote tip already went
forward with a couple of new tags added.  Now I can not commit my work
anymore, as a I have diverging branches locally, and I can not graft my
changes to the remote tip.  Merging, then pushing fails with:

$ hg push
pushing to ssh://hg.mozilla.org/releases/l10n-mozilla-1.9.1/sr/
searching for changes
remote: adding changesets
remote: adding manifests
remote: adding file changes
remote: added 2 changesets with 2 changes to 2 files
remote: Two heads detected on branch 'default'
remote: Only one head per branch is allowed!
remote: transaction abort!
remote: rollback completed
remote: abort: pretxnchangegroup.a_singlehead hook failed
abort: unexpected response: empty string


What to do?

f
_______________________________________________
dev-l10n mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-l10n
Reply | Threaded
Open this post in threaded view
|

Re: Help with merging diverging work on HG

Anas Husseini-2
You seem to have an updated local repo.

Try to hg pull, then hg update, then push again (using hg addremove,
hg commit then hg push).

Regards

- Anas

On 3/29/09, Filip Miletic <[hidden email]> wrote:

> Hello all.
>
> I was working on the Serbian translation of FF 3.1 in the Mercurial
> repo.  I committed a few changes to the repo locally; and filed a
> bugzilla ticket to get it approved.
>
> Unfortunately, when I got the approval, the remote tip already went
> forward with a couple of new tags added.  Now I can not commit my work
> anymore, as a I have diverging branches locally, and I can not graft my
> changes to the remote tip.  Merging, then pushing fails with:
>
> $ hg push
> pushing to ssh://hg.mozilla.org/releases/l10n-mozilla-1.9.1/sr/
> searching for changes
> remote: adding changesets
> remote: adding manifests
> remote: adding file changes
> remote: added 2 changesets with 2 changes to 2 files
> remote: Two heads detected on branch 'default'
> remote: Only one head per branch is allowed!
> remote: transaction abort!
> remote: rollback completed
> remote: abort: pretxnchangegroup.a_singlehead hook failed
> abort: unexpected response: empty string
>
>
> What to do?
>
> f
> _______________________________________________
> dev-l10n mailing list
> [hidden email]
> https://lists.mozilla.org/listinfo/dev-l10n
>


--
Experience is something you don't get until just after you need it.
_______________________________________________
dev-l10n mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-l10n
Reply | Threaded
Open this post in threaded view
|

Re: Help with merging diverging work on HG

Filip Miletic-4
In reply to this post by Filip Miletic-4
Anas Husseini schreef:
> You seem to have an updated local repo.
>
> Try to hg pull, then hg update, then push again (using hg addremove,
> hg commit then hg push).

Tried this, no changes.

f
_______________________________________________
dev-l10n mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-l10n
Reply | Threaded
Open this post in threaded view
|

Re: Help with merging diverging work on HG

Axel Hecht
On 29.03.2009 20:52 Uhr, Filip Miletic wrote:
> Anas Husseini schreef:
>> You seem to have an updated local repo.
>>
>> Try to hg pull, then hg update, then push again (using hg addremove,
>> hg commit then hg push).
>
> Tried this, no changes.

Giving the right answer depends on your local revision graph. How to get
that sadly depends largely on your version of hg.

If you're on a current version of hg (1.2, 1.1 might work), glog would
help, or view, or tortoise hg in a current revision.

On plain hg, make sure to have graphlog added to your extensions in ~/.hgrc,

[extensions]
graphlog =

is enough.

The output of the last 10 revisions or so should be good enough,

hg glog -l 10

Axel
_______________________________________________
dev-l10n mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-l10n
Reply | Threaded
Open this post in threaded view
|

Re: Help with merging diverging work on HG

Filip Miletic-4
Axel Hecht schreef:
> Giving the right answer depends on your local revision graph. How to get
> that sadly depends largely on your version of hg.
>
> If you're on a current version of hg (1.2, 1.1 might work), glog would
> help, or view, or tortoise hg in a current revision.
>
> On plain hg, make sure to have graphlog added to your extensions in
> ~/.hgrc,

I poked around a bit and found the cause of the initial problem.

It turns out that, while firefox build tagging was applied on the remote
end, also a thunderbird build tag was applied;  the latter ended up in a
separate branch, thus creating two heads in my local repo when I pulled.
  I suppose that the commit hook scripts prevented me from committing
back anything that had two heads, thus the error I saw.

I merged the two branches so that only one branch remains and pushed
that with success.  I don't know if the thunderbird l10n branch would
suffer because of this, but so far I've been OK.

Thanks for the efforts to explain what was going on.

f
_______________________________________________
dev-l10n mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-l10n
Reply | Threaded
Open this post in threaded view
|

Re: Help with merging diverging work on HG

Axel Hecht
On 06.04.2009 12:50 Uhr, Filip Miletic wrote:

> Axel Hecht schreef:
>> Giving the right answer depends on your local revision graph. How to get
>> that sadly depends largely on your version of hg.
>>
>> If you're on a current version of hg (1.2, 1.1 might work), glog would
>> help, or view, or tortoise hg in a current revision.
>>
>> On plain hg, make sure to have graphlog added to your extensions in
>> ~/.hgrc,
>
> I poked around a bit and found the cause of the initial problem.
>
> It turns out that, while firefox build tagging was applied on the remote
> end, also a thunderbird build tag was applied;  the latter ended up in a
> separate branch, thus creating two heads in my local repo when I pulled.
>    I suppose that the commit hook scripts prevented me from committing
> back anything that had two heads, thus the error I saw.
>
> I merged the two branches so that only one branch remains and pushed
> that with success.  I don't know if the thunderbird l10n branch would
> suffer because of this, but so far I've been OK.
>
> Thanks for the efforts to explain what was going on.
>
> f

Actually, the thunderbird ones don't add on a branch at all, but on
default, thus you need to merge the two heads on default.

Axel
_______________________________________________
dev-l10n mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-l10n