Revision not present errors due to push creating stacked 2a repositories with format 6 (unstacked) branches

Bug #390951 reported by Tim Penhey
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Bazaar
Confirmed
High
Unassigned

Bug Description

Branches are sometimes created with format 6 even though the initial push code thought it would be stacked and seeded it like a stacked branch.

Workarounds
===========

Before pushing make sure branches are in branch 7 format (run 'bzr upgrade --2a' on them)

After pushing, if a branch is affected

bzr upgrade --2a sftp://bazaar.launchpad.net/USER/PROJECT/BRANCH
python
import bzrlib.branch
b = bzrlib.branch.Branch.open('sftp://bazaar.launchpad.net/USER/PROJECT/BRANCH')
b.set_stacked_on_url('sftp://bazaar.launchpad.net/<trunk for project>')

Causes
======

Still being analyzed

Details
======

Somehow several different users with format 2a repositories are pushing broken branches to Launchpad. Specifically they have created stacked repositories, but format 6 branches, so when accessing history outside of the stacked repository the user (and Launchpad internals like the scanner) get RevisionNotPresent errors. This may be caused by #390431.

Example branches affected by this:

lp:~danilo/launchpad/bug-389391
lp:~julian-edwards/launchpad/team-join-sub-email-bug-382687
lp:~jml/launchpad/fix-run-all

Tags: stacking
Revision history for this message
Andrew Bennetts (spiv) wrote :

The traceback shows it is failing in iter_reverse_revision_history, on a revision from PQM. I assume these are stacked branches. Perhaps the stacked-on branch isn't branch/repository isn't working properly?

Hmm:

$ bzr revision-history lp:~jml/launchpad/fix-run-all
bzr: ERROR: Server sent an unexpected error: ('error', 'Revision {<email address hidden>} not present in "CHKInventoryRepository(\'lp-140472760815824:///~jml/launchpad/fix-run-all/.bzr/repository\')".')

Same via SFTP.

Oh, interesting... "bzr info -v" on that branch shows:

        branch: Branch format 6

So, I think this is a recurrence of a bug we used to have where a stacked repository gets pushed up, then a format 6 (and thus unstacked) branch gets created on that repository.

Changed in bzr:
importance: Undecided → High
status: New → Triaged
tags: added: stacking
Revision history for this message
Andrew Bennetts (spiv) wrote :
description: updated
Andrew Bennetts (spiv)
summary: - Revision not present errors in Launchpad's scanner
+ Revision not present errors due to push creating stacked 2a repositories
+ with format 6 (unstacked) branches
description: updated
Revision history for this message
Jonathan Lange (jml) wrote :

See OOPS-1283SMS1, OOPS-1283SMS10, OOPS-1283SMS100, OOPS-1283SMS1000, OOPS-1283SMS1003, OOPS-1283SMS1001, OOPS-1283SMS1004, OOPS-1283SMS1007, OOPS-1283SMS101, OOPS-1283SMS1010, OOPS-1283SMS1002, OOPS-1283SMS1005, OOPS-1283SMS1008, OOPS-1283SMS1011 and OOPS-1283SMS1014 for examples.

Martin Pool (mbp)
Changed in bzr:
status: Triaged → Confirmed
Jelmer Vernooij (jelmer)
tags: added: check-for-breezy
Jelmer Vernooij (jelmer)
tags: removed: check-for-breezy
Changed in brz:
status: New → Triaged
importance: Undecided → High
no longer affects: brz
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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