support for colocated branches

Bug #380871 reported by Philipp Kern
144
This bug affects 25 people
Affects Status Importance Assigned to Milestone
Bazaar
Fix Released
High
Jelmer Vernooij
Bazaar Git Plugin
Fix Released
Medium
Jelmer Vernooij
Bazaar Hg Plugin
Fix Released
Medium
Jelmer Vernooij
Launchpad itself
Fix Released
Medium
Jelmer Vernooij

Bug Description

Please allow imports of non-master branches from git. First of all there are cases where the current HEAD is not in master, but in another branch. And on the other hand because branches in git are so cheap there will be development happening in release branches that also should be accessible in a sane way.

Related branches

Jonathan Lange (jml)
tags: added: code-import
Revision history for this message
Michael Hudson-Doyle (mwhudson) wrote :

This is mostly waiting on a not-completely-technical decision from the bazaar folks -- it's not actually hard.

Changed in launchpad-code:
importance: Undecided → Medium
status: New → Triaged
Revision history for this message
Jelmer Vernooij (jelmer) wrote :

not entirely sure about importance, setting to wishlist for now

Changed in bzr-git:
importance: Undecided → Wishlist
status: New → Triaged
assignee: nobody → Jelmer Vernooij (jelmer)
Changed in bzr:
importance: Undecided → Wishlist
status: New → Triaged
Revision history for this message
Jelmer Vernooij (jelmer) wrote :

fwiw "bzr git-import" can import these other branches, but there's no way to do so using the Bazaar API.

Revision history for this message
Tim Penhey (thumper) wrote : Re: [Bug 380871] Re: Allow imports of non-master branches when pulling from git repositories

On Tue, 02 Jun 2009 14:46:46 Jelmer Vernooij wrote:
> fwiw "bzr git-import" can import these other branches, but there's no
> way to do so using the Bazaar API.

What is missing in the Bazaar API?

Revision history for this message
Robert Collins (lifeless) wrote :

On Tue, 2009-06-02 at 03:30 +0000, Tim Penhey wrote:
> On Tue, 02 Jun 2009 14:46:46 Jelmer Vernooij wrote:
> > fwiw "bzr git-import" can import these other branches, but there's no
> > way to do so using the Bazaar API.
>
> What is missing in the Bazaar API?

The bzr command line has no way to talk about groups of branches; the
underlying API can query and sync multiple branches *one at a time*.

So jelmer may mean 'no efficient way' or 'no way to ask for this from
the command line'.

See the multi-{push,pull} plugins that have been written for examples.

-Rob

Revision history for this message
Jelmer Vernooij (jelmer) wrote : Re: Allow imports of non-master branches when pulling from git repositories

There is no way to deal with colocated branches in the Bazaar API at the moment, so it would be impossible for launchpad to open (and pull from) any of the colocated branches of a Git repository URL.

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

We've discussed colocated branches at the sprint in Strasbourg last week and have agreed on a way forward. I'm going to update the spec for colocated branches in bzr.dev, and hopefully we can work on moving it forward after that.

Revision history for this message
Martin Pool (mbp) wrote : Re: [Bug 380871] Re: Allow imports of non-master branches when pulling from git repositories

On 1 February 2010 04:04, Jelmer Vernooij <email address hidden> wrote:
> We've discussed colocated branches at the sprint in Strasbourg last week
> and have agreed on a way forward. I'm going to update the spec for
> colocated branches in bzr.dev, and hopefully we can work on moving it
> forward after that.

For those following this bug: the syntax was agreed so this should now
be unblocked.

--
Martin <http://launchpad.net/~mbp/>

Jelmer Vernooij (jelmer)
Changed in bzr:
assignee: nobody → Jelmer Vernooij (jelmer)
Revision history for this message
Jelmer Vernooij (jelmer) wrote : Re: Allow imports of non-master branches when pulling from git repositories

The bzr-git side of this is now implemented, the main thing remaining is support for colocated branches in URLs in bzrlib.

Changed in bzr-git:
status: Triaged → Fix Released
Changed in bzr:
status: Triaged → In Progress
Revision history for this message
Maia Everett (linneris) wrote :

Any progress on this?

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

Not much. I didn't get it finished in time before the 2.2 freeze so I've postponed working on it for a bit, as it will probably have to wait until 2.3.

Revision history for this message
Tim Penhey (thumper) wrote :

Jelmer, why does the importing of non-master branches require colocated branch support in bzrlib?

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

We need some way to specify what colocated (because that's effectively what non-master branches are) branch to import in the URL; this is what colocated branches are all about.

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

This is almost done but I never quite finished it. Now that I'm on Bazaar I've picked it back up again.

Jelmer Vernooij (jelmer)
Changed in bzr-git:
importance: Wishlist → Undecided
importance: Undecided → Medium
Changed in bzr:
importance: Wishlist → Medium
Revision history for this message
Barry Warsaw (barry) wrote :

I'm tracking this bug now because I'm interested in importing Python's shiny new Mercurial repository at http://hg.python.org/cpython. I've got an import running for the 'default' branch, which will always be the next version of Python 3, but the repo has named branches for all recent released versions of Python.

Once I get imports of all named branches, I'll delete the svn imports, since those have gone read-only.

Jelmer Vernooij (jelmer)
summary: - Allow imports of non-master branches when pulling from git repositories
+ support for colocated branches
Changed in bzr:
importance: Medium → High
Changed in bzr-hg:
status: New → Triaged
importance: Undecided → Medium
Jelmer Vernooij (jelmer)
Changed in bzr-hg:
status: Triaged → In Progress
assignee: nobody → Jelmer Vernooij (jelmer)
Revision history for this message
Jelmer Vernooij (jelmer) wrote :

Being able to address colocated branches in the API and the UI is close to being finished and will fix Philipp's original bug and imports in Launchpad.

Perhaps we should file separate bugs about the further work after this. There are several related issues:

 * the UI surrounding collections of branches - fetching multiple branches at once, cloning multiple branches, etc.
 * formats in Bazaar that support colocated branches

Revision history for this message
John C Barstow (jbowtie) wrote :

Will there a summary of the API changes somewhere for authors of other foreign VCS plugins, or will we have to inspect the source?

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

Most of the API changes have actually already landed in bzr 2.3 and consist of extra optional name arguments to ControlDir.open_branch() / ControlDir.create_branch() / ControlDir.destroy_branch().

If you need more information, please let me know.

Revision history for this message
Martin Pool (mbp) wrote : Re: [Bug 380871] Re: support for colocated branches

Jelmer, if you didn't already, could you please add a paragraph or two
to the architecture guide, and perhaps to the 'what's new'?

Martin

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

On Wed, 2011-03-23 at 01:19 +0000, Martin Pool wrote:
> Jelmer, if you didn't already, could you please add a paragraph or two
> to the architecture guide, and perhaps to the 'what's new'?
Will do, I wasn't actually aware we had an architecture guide. :)

Cheers,

Jelmer

Jelmer Vernooij (jelmer)
Changed in bzr-hg:
milestone: none → 0.2
Revision history for this message
Jelmer Vernooij (jelmer) wrote :

On Wed, 2011-03-23 at 01:19 +0000, Martin Pool wrote:
> Jelmer, if you didn't already, could you please add a paragraph or two
> to the architecture guide, and perhaps to the 'what's new'?
Looks like I did actually write documentation earlier, then forgot I
did. :)

See doc/developers/colocated-branches.txt in bzr.dev.

revno: 3995 [merge]
committer: Canonical.com Patch Queue Manager <email address hidden>
branch nick: +trunk
timestamp: Tue 2009-02-10 04:54:18 +0000
message:
  (Jelmer) Add specification for colocated branches.
------------------------------------------------------------

I've verified it's still current.

Cheers,

Jelmer

Revision history for this message
Martin Pool (mbp) wrote :

way to go.

Jelmer Vernooij (jelmer)
Changed in bzr-hg:
status: In Progress → Fix Committed
Revision history for this message
John A Meinel (jameinel) wrote :

What is still needed in the Bazaar side?

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

On Wed, 2011-04-20 at 09:20 +0000, John A Meinel wrote:
> What is still needed in the Bazaar side?
lp:~jelmer/bzr/transport-segments needs to be finished and landed. That's the only thing on the bzr side AFAICT.

Cheers,

Jelmer

Revision history for this message
Per Johansson (per.j) wrote :

It also seems quite important that bzr switch is made aware of colocated branches. But perhaps that is another issue.

Revision history for this message
Per Johansson (per.j) wrote :

Is the linked branch still relevant? There seems to have been some progress on this issue in lp:bzr already?

Revision history for this message
Jelmer Vernooij (jelmer) wrote :

On Sat, 2011-07-30 at 11:29 +0000, Per Johansson wrote:
> Is the linked branch still relevant? There seems to have been some
> progress on this issue in lp:bzr already?
There has been some progress towards this in lp:bzr, but it is all to
make it possible to merge the attached branch.

Cheers,

Jelmer

Jelmer Vernooij (jelmer)
Changed in launchpad:
assignee: nobody → Jelmer Vernooij (jelmer)
Revision history for this message
Jelmer Vernooij (jelmer) wrote :

There now is a merge proposal that adds the required bits to Bazaar to allow addressing colocated branches in URLs:

bzr log file:///tmp/etckeeper,branch=foo

Revision history for this message
Jelmer Vernooij (jelmer) wrote :
Changed in bzr:
status: In Progress → Fix Released
milestone: none → 2.5b1
Changed in launchpad:
status: Triaged → In Progress
Revision history for this message
Launchpad QA Bot (lpqabot) wrote :
tags: added: qa-needstesting
Changed in launchpad:
status: In Progress → Fix Committed
Jelmer Vernooij (jelmer)
tags: added: qa-ok
removed: qa-needstesting
William Grant (wgrant)
Changed in launchpad:
status: Fix Committed → Fix Released
Revision history for this message
Boris Dušek (dusek) wrote :

I still don't see an option to import a custom branch in git import (only option is a "Repo URL") on launchpad web ui (URL e.g. https://code.launchpad.net/gnome-orca/+new-import). Am I missing something? Thanks.

Revision history for this message
William Grant (wgrant) wrote :

There's no special UI for it yet, but you can import a custom git branch by adding ",branch=somecustombranch" to the end of the URL.

Jelmer Vernooij (jelmer)
Changed in bzr-hg:
status: Fix Committed → Fix Released
milestone: 0.2 → 0.1.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Related questions

Remote bug watches

Bug watches keep track of this bug in other bug trackers.