incompatible repository error messages are unhelpful

Bug #206258 reported by Benjamin Peterson
14
Affects Status Importance Assigned to Milestone
Bazaar
Fix Released
Medium
Martin Pool

Bug Description

I'm using Bazaar 1.3.
I made a repository for myself with bzr init-repo with the default format. I attempted to branch a remote repo over http and got this:
bzr: ERROR: Repository KnitPackRepository([where I am]) is not compatible with repository KnitPackRepository([branch url])
Eventually, I ran bzr info on the remote and found that it was rich-root-pack. It would have been very helpful if Bazaar told me this so I could reformat my repo.

Revision history for this message
Jeff Fortin Tam (kiddo) wrote :

How did you reformat your repo? If only I knew how to do that already...

Changed in bzr:
status: New → Confirmed
Revision history for this message
Benjamin Peterson (benjaminp) wrote :

It was empty, so I deleted the .bzr directory and reran init-repo. ;) Sorry for getting your hopes up.

Revision history for this message
Benjamin Peterson (benjaminp) wrote :

You can use bzr upgrade.

Revision history for this message
Jeff Fortin Tam (kiddo) wrote :

sadly no, it does not work, even worse, it *destroys* the repository when doing so (hopefully, I did this on a copy).

Revision history for this message
ChriS (christophe-troestler) wrote :

A collaborator of mine just got the same message and doing

bzr upgrade --rich-root-pack

solved the problem (bzr upgrade was not sufficient). Maybe running this command could be suggested in the error message, checking the format of the remote branch if necessary to provide the better help.

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

Patch sent to list.

Changed in bzr:
assignee: nobody → mbp
importance: Undecided → Medium
Revision history for this message
Martin Pool (mbp) wrote :

The patch changes the behaviour to be like this:

mbp@grace% ./bzr init --development-subtree /tmp/a
mbp@grace% ./bzr init --development /tmp/b
mbp@grace% ./bzr ci -m 'foo' /tmp/a --unchanged
Committing to: /tmp/a/
Committed revision 1.
mbp@grace% ./bzr pull -d /tmp/b /tmp/a
bzr: ERROR: KnitPackRepository('file:///tmp/b/.bzr/repository/')
is not compatible with
KnitPackRepository('file:///tmp/a/.bzr/repository/')
different rich-root support
zsh: exit 3 ./bzr pull -d /tmp/b /tmp/a

I would agree this is not the most helpful message possible as to what you should do next but at least it is giving a specific message about what is wrong. Perhaps we should include a suggestion.

Martin Pool (mbp)
Changed in bzr:
status: Confirmed → Fix Committed
Jelmer Vernooij (jelmer)
Changed in bzr:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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