svn+ssh:// push: IntegrityError: columns max_revnum, min_revnum, path, scheme are not unique

Bug #165136 reported by Martin Pitt
4
Affects Status Importance Assigned to Milestone
Bazaar
Invalid
Low
Unassigned
Bazaar Subversion Plugin
Fix Released
Low
Jelmer Vernooij
bzr-svn (Ubuntu)
Fix Released
Low
Jelmer Vernooij

Bug Description

Binary package hint: bzr-svn

Until a few days ago bzr-svn worked just fine in Hardy. Now I get an exception when I try to push my cups branch to Alioth:

$ bzr push
Using saved location: svn+ssh://<email address hidden>/svn/pkg-cups/cupsys/branches/cups-1.2-ubuntu
bzr: ERROR: sqlite3.IntegrityError: columns max_revnum, min_revnum, path, scheme are not unique

Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/bzrlib/commands.py", line 802, in run_bzr_catch_errors
    return run_bzr(argv)
  File "/usr/lib/python2.5/site-packages/bzrlib/commands.py", line 758, in run_bzr
    ret = run(*run_argv)
  File "/usr/lib/python2.5/site-packages/bzrlib/commands.py", line 492, in run_argv_aliases
    return self.run(**all_cmd_args)
  File "/usr/lib/python2.5/site-packages/bzrlib/builtins.py", line 812, in run
    push_result = br_from.push(br_to, overwrite)
  File "/usr/lib/python2.5/site-packages/bzrlib/decorators.py", line 127, in read_locked
    return unbound(self, *args, **kwargs)
  File "/usr/lib/python2.5/site-packages/bzrlib/branch.py", line 1534, in push
    _override_hook_source_branch=_override_hook_source_branch)
  File "/usr/lib/python2.5/site-packages/bzrlib/branch.py", line 1576, in _push_with_bound_branches
    result = self._basic_push(target, overwrite, stop_revision)
  File "/usr/lib/python2.5/site-packages/bzrlib/branch.py", line 1595, in _basic_push
    target.update_revisions(self, stop_revision)
  File "/usr/lib/python2.5/site-packages/bzrlib/plugins/svn/branch.py", line 357, in update_revisions
    stop_revision)
  File "/usr/lib/python2.5/site-packages/bzrlib/plugins/svn/repository.py", line 312, in lhs_missing_revisions
    if self.has_revision(revid):
  File "/usr/lib/python2.5/site-packages/bzrlib/plugins/svn/repository.py", line 464, in has_revision
    (path, revnum, _) = self.lookup_revision_id(revision_id)
  File "/usr/lib/python2.5/site-packages/bzrlib/plugins/svn/repository.py", line 760, in lookup_revision_id
    str(scheme), entry_revno)
  File "/usr/lib/python2.5/site-packages/bzrlib/plugins/svn/revids.py", line 131, in insert_revid
    (revid, branch, min_revnum, max_revnum, scheme))
IntegrityError: columns max_revnum, min_revnum, path, scheme are not unique

bzr 0.92.0 on python 2.5.1.final.0 (linux2)
arguments: ['/usr/bin/bzr', 'push']
encoding: 'UTF-8', fsenc: 'UTF-8', lang: 'de_DE.UTF-8'
plugins:
  bzrtools /usr/lib/python2.5/site-packages/bzrlib/plugins/bzrtools [0.92.0]
  launchpad /usr/lib/python2.5/site-packages/bzrlib/plugins/launchpad [unknown]
  multiparent /usr/lib/python2.5/site-packages/bzrlib/plugins/multiparent.pyc [unknown]
  svn /usr/lib/python2.5/site-packages/bzrlib/plugins/svn [0.4.4]

$ bzr info
Standalone tree (format: dirstate-with-subtree)
Location:
  branch root: .

Related branches:
    push branch: svn+ssh://<email address hidden>/svn/pkg-cups/cupsys/branches/cups-1.2-ubuntu
  parent branch: svn+ssh://<email address hidden>/svn/pkg-cups/cupsys/branches/cups-1.2-ubuntu

Related branches

Revision history for this message
Martin Pitt (pitti) wrote :

The workaround is to remove the svn cache with

  rm -r ~/.bzr/svn-cache

This worked fine for me, thanks Jelmer!

Revision history for this message
Jelmer Vernooij (jelmer) wrote : Re: [Bug 165136] Re: svn+ssh:// push: IntegrityError: columns max_revnum, min_revnum, path, scheme are not unique

This bug also exists upstream, not just in Ubuntu.

  affects /products/bzr
  status triaged
  importance low
  tags +upgrade
--
Jelmer Vernooij <email address hidden> - http://samba.org/~jelmer/

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

  affects /products/bzr-svn
  status triaged
  importance low
  tags +upgrade

This is an upgrade issue - older versions create a unique version of the
following index:

        create index if not exists lookup_branch_revnum on revmap
(max_revnum, min_revnum, path, scheme);

bzr-svn should fix this or simply remove the old cache file when it
finds a unique lookup_branch_revnum index.

Unfortunately, launchpad won't let me change the status of the Ubuntu bit of this bug because I'm not a Ubuntu bug contact.

--
Jelmer Vernooij <email address hidden> - http://samba.org/~jelmer/

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

typo: bug in bzr-svn, not bzr

Changed in bzr:
status: Triaged → Invalid
Martin Pitt (pitti)
Changed in bzr-svn:
status: New → Triaged
importance: Undecided → Low
Jelmer Vernooij (jelmer)
Changed in bzr-svn:
assignee: nobody → jelmer
milestone: none → 0.4.7
status: Triaged → Fix Committed
assignee: nobody → jelmer
status: Triaged → Fix Committed
Jelmer Vernooij (jelmer)
Changed in bzr:
status: Invalid → Fix Released
Jelmer Vernooij (jelmer)
Changed in bzr-svn:
status: Fix Committed → Fix Released
Changed in bzr:
status: Fix Released → Invalid
Jelmer Vernooij (jelmer)
Changed in bzr-svn:
status: Fix Committed → Fix Released
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.