[Bioc-devel] Your branch and 'bioc/master' have diverged

Dan Tenenbaum dtenenba at fredhutch.org
Thu Mar 10 19:47:37 CET 2016



----- Original Message -----
> From: "Luca De Sano" <l.desano at campus.unimib.it>
> To: "Dan Tenenbaum" <dtenenba at fredhutch.org>
> Cc: "bioc-devel" <bioc-devel at r-project.org>
> Sent: Thursday, March 10, 2016 10:21:38 AM
> Subject: Re: [Bioc-devel] Your branch and 'bioc/master' have diverged

> On 10 March 2016 at 18:17, Dan Tenenbaum <dtenenba at fredhutch.org> wrote:
> 
>>
>>
>> ----- Original Message -----
>> > From: "Luca De Sano" <l.desano at campus.unimib.it>
>> > To: "bioc-devel" <bioc-devel at r-project.org>
>> > Sent: Thursday, March 10, 2016 3:22:14 AM
>> > Subject: [Bioc-devel] Your branch and 'bioc/master' have diverged
>>
>> > Hi all,
>> > I'm trying to update the devel branch of my package following the
>> > instruction found in
>> https://bioconductor.org/developers/how-to/git-mirrors/
>> > .
>> >
>> > The repo of my project is: https://github.com/BIMIB-DISCo/TRONCO
>> >
>> >>From devel I've first tried to do a git merge master, with no results.
>> I've
>> > then tried the cherry-pick method and all seemed to work well. However,
>> > during the git-svn dcommit, I've obtained a:
>> >
>> > svn: Commit blocked by pre-commit hook (exit code 1) with output:
>> > The y in the x.y.z version number should be even in release
>> > in file branches/RELEASE_3_2/madman/Rpacks/VegaMC/DESCRIPTION.
>> > See http://bioconductor.org/developers/how-to/version-numbering/
>> >
>>
>>
>> Did you really get this commit error message about trying to commit to the
>> devel branch of TRONCO? The message refers to the _release_ branch of
>> _VegaMC_. If you did get that error message in response to a commit of
>> TRONCO, then something is very wrong with that pre-commit hook.
>>
> 
> No. Sorry was just a cut&paste error, I was searching the mailing list for
> similar errors ... The message was like:
> 
> svn: Commit blocked by pre-commit hook (exit code 1) with output:
> The y in the x.y.z version number should be even in release
> in file [some path which I don't remember at the
> moment]/madman/Rpacks/TRONCO/DESCRIPTION.
> See http://bioconductor.org/developers/how-to/version-numbering/
> 
> 
> 
>>
>>
>>
>> > There has been a problem with a commit (a wrong version update which was
>> > rejected from svn).
>> >
>> > I've fixed this problem on my master removing the wrong commit as
>> described
>> > here http://www.clock.co.uk/blog/deleting-a-git-commit . I've then
>> tried to
>> > bring those changes on devel doing this:
>> >
>>
>> Which commit was 'wrong'?
>>
> 
> The problem was a wrong version update in a commit made one month ago. This
> commit triggered the pre-commit hook and, even If I've fixed it with a new
> commit, the problem has remained. So, following the instructions mentioned
> above, I've removed the commit from the history tree.
> 
> 
> 
>>
>>
>> >   - git reset --hard on devel to the last right commit
>> >   - git cherry-pick on the others commit from my master branch
>> >
>> > After the cherry-pick, on git, all worked well. The resul of git log is:
>> >
>> > dex at darthvader ~/project/TRONCO $ git log --graph --decorate
>> > --pretty=oneline --abbrev-commit --all
>> > *   2e27604 (HEAD, origin/master, origin/development, origin/HEAD,
>> master,
>> > development, devel) Merge pull request #47 from BIMIB-DISCo/development
>> >|\
>> >| * 340c809 date update
>> >|/
>> > * 4700191 dependencies update
>> > * 31c2cab regex problems
>> > [...]
>> >
>> > I've then tried to commit to svn, but the git svn dcommit
>> --add-author-from
>> > now isn't workig...
>> >
>> > dex at darthvader ~/project/TRONCO $ git svn dcommit --add-author-from
>> > Unable to determine upstream SVN information from HEAD history.
>> > Perhaps the repository is empty. at /usr/lib/git-core/git-svn line 856.
>> >
>> > And the result of a git status is:
>> >
>> > dex at darthvader ~/project/TRONCO $ git status
>> > On branch devel
>> > Your branch and 'bioc/master' have diverged,
>> > and have 615 and 25 different commits each, respectively.
>> >  (use "git pull" to merge the remote branch into yours)
>> >
>> > nothing to commit, working directory clean
>> >
>> >
>> > The situation at the moment is:
>> >
>> >
>> >   -
>> https://hedgehog.fhcrc.org/bioconductor/trunk/madman/Rpacks/TRONCO/R/
>> >   is a mix of old and new version... I don't know why. Some files are up
>> to
>> >   date with my master and some others no.
>> >
>> >   - My master ( https://github.com/BIMIB-DISCo/TRONCO/tree/master ) is
>> up
>> >   to date and I want to bring this on devel
>> >
>> > Any idea how to fix this?
>>
>>
>> Basically, cherry-pick any commit that is in master but not devel. Then
>> try git-svn dcommit.
>>
>> Dan
>>
> 
> This is not possible because some commits has been applyied not entirely to
> devel. In
> https://hedgehog.fhcrc.org/bioconductor/trunk/madman/Rpacks/TRONCO/ some
> files seem to be updated with master and some others no. For example open
> as.functions.R and caprese.algorith.R: both have been modified with
> https://github.com/BIMIB-DISCo/TRONCO/commit/44e3d7a3f361cbe38227d1c74029afb6e6449e3d
> , but only as.functions.R seems to be up to date.
> 
> Can you simply revert everything on svn and on the git mirror to this
> commit you made?
> https://github.com/BIMIB-DISCo/TRONCO/commit/af70ecaba498642e7e19697c51b856cbe3bba8be
> 
> 

I can but I am not sure it would solve your problem.

Another thing you could do is simply:

- check out the package using svn
- copy the contents of your git repository over the files
  in the svn working copy
- svn commit the svn working copy.

You might still have issues in the future when trying to merge from svn or commit from git. But this would solve your immediate problem.

Dan



> 
> 
> 
> 
> 
> 
> 
>>
>>
>> > Many thanks!
>> >
>> >
>> > --
>> > Luca De Sano
>> > Research Associate
>> >
>> > Department of Informatics, Systems and Communication
>> > University of Milan Bicocca
>> >
>> > Institute of Biomembranes and Bioenergetics of the Italian National
>> > Research Council (IBBE-CNR)
>> >
>> > email: l.desano at campus.unimib.it
>> > PEC: luca.desano at pec.it
>> >
>> >       [[alternative HTML version deleted]]
>> >
>> > _______________________________________________
>> > Bioc-devel at r-project.org mailing list
>> > https://stat.ethz.ch/mailman/listinfo/bioc-devel
>>
> 
> 
> 
> --
> Luca De Sano
> Research Associate
> 
> Department of Informatics, Systems and Communication
> University of Milan Bicocca
> 
> Institute of Biomembranes and Bioenergetics of the Italian National
> Research Council (IBBE-CNR)
> 
> email: l.desano at campus.unimib.it
> PEC: luca.desano at pec.it



More information about the Bioc-devel mailing list