Problem with svn cache when using Python 2.6

Bug #296868 reported by Rocky Burt
2
Affects Status Importance Assigned to Milestone
Bazaar Subversion Plugin
Fix Released
Medium
Jelmer Vernooij

Bug Description

Error trying to branch remote svn project. Confirmed that this problem does NOT occur with same bzr versions and python 2.5.

Versions:
  bzr: 1.9
  bzr-svn: 0.4.19
  Python: 2.6

rocky@zebrax:~/dev/envs/zest/xm/buildout-trunk/src$ bzr branch https://svn.plone.org/svn/collective/Products.eXtremeManagement/trunk Products.eXtremeManagementInitialising Subversion metadata cache in /home/rocky/.bazaar/svn-cache/db7f04ef-aaf3-0310-a811-c281ed44c4ad
bzr: ERROR: sqlite3.ProgrammingError: You must not use 8-bit bytestrings unless you use a text_factory that can interpret 8-bit bytestrings (like text_factory = str). It is highly recommended that you instead just switch your application to Unicode strings.

Traceback (most recent call last):
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzr-1.9-py2.6-linux-i686.egg/bzrlib/commands.py", line 893, in run_bzr_catch_errors
    return run_bzr(argv)
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzr-1.9-py2.6-linux-i686.egg/bzrlib/commands.py", line 839, in run_bzr
    ret = run(*run_argv)
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzr-1.9-py2.6-linux-i686.egg/bzrlib/commands.py", line 539, in run_argv_aliases
    return self.run(**all_cmd_args)
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzr-1.9-py2.6-linux-i686.egg/bzrlib/builtins.py", line 953, in run
    from_location)
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzr-1.9-py2.6-linux-i686.egg/bzrlib/bzrdir.py", line 889, in open_tree_or_branch
    return bzrdir._get_tree_branch()
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzr-1.9-py2.6-linux-i686.egg/bzrlib/bzrdir.py", line 874, in _get_tree_branch
    branch = self.open_branch()
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzrlib/plugins/svn/remote.py", line 176, in open_branch
    branch = SvnBranch(repos, self.branch_path)
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzrlib/plugins/svn/branch.py", line 71, in __init__
    self.mapping = self.repository.get_mapping()
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzrlib/plugins/svn/repository.py", line 329, in get_mapping
    self._default_mapping = get_default_mapping().from_repository(self, self._hinted_branch_path)
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzrlib/plugins/svn/mapping3/__init__.py", line 249, in from_repository
    (guessed_scheme, actual_scheme) = repository_guess_scheme(repository, last_revnum, _hinted_branch_path)
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzrlib/plugins/svn/mapping3/__init__.py", line 196, in repository_guess_scheme
    repository._log.iter_changes(None, last_revnum, max(0, last_revnum-SCHEME_GUESS_SAMPLE_SIZE), pb=pb), last_revnum, branch_path)
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzrlib/plugins/svn/mapping3/scheme.py", line 488, in guess_scheme_from_history
    for (revpaths, revnum, revprops) in changed_paths:
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzrlib/plugins/svn/logwalker.py", line 310, in iter_changes
    self.fetch_revisions(max(from_revnum, to_revnum), pb=pb)
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzrlib/plugins/svn/logwalker.py", line 466, in fetch_revisions
    self.actual._transport.get_log(rcvr, [""], self.saved_revnum, to_revnum, 0, True, True, False, todo_revprops)
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzrlib/plugins/svn/transport.py", line 341, in get_log
    revprops)
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzrlib/plugins/svn/logwalker.py", line 450, in rcvr
    self.cache.insert_path(revision, p.strip("/"), orig_paths[p][0], copyfrom_path, orig_paths[p][2])
  File "/data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzrlib/plugins/svn/logwalker.py", line 205, in insert_path
    self.cachedb.execute("replace into changed_path (rev, path, action, copyfrom_path, copyfrom_rev) values (?, ?, ?, ?, ?)", (rev, path, action, copyfrom_path, copyfrom_rev))
ProgrammingError: You must not use 8-bit bytestrings unless you use a text_factory that can interpret 8-bit bytestrings (like text_factory = str). It is highly recommended that you instead just switch your application to Unicode strings.

bzr 1.9 on python 2.6 (linux2)
arguments: ['/home/rocky/bin/bzr', 'branch', 'https://svn.plone.org/svn/collective/Products.eXtremeManagement/trunk', 'Products.eXtremeManagement']
encoding: 'UTF-8', fsenc: 'UTF-8', lang: 'en_CA.UTF-8'
plugins:
  launchpad /data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzr-1.9-py2.6-linux-i686.egg/bzrlib/plugins/launchpad [unknown]
  svn /data/usr/misc/apps/bzr-1.9/lib/python2.6/site-packages/bzrlib/plugins/svn [0.4.15dev0]
*** Bazaar has encountered an internal error.
    Please report a bug at https://bugs.launchpad.net/bzr/+filebug
    including this traceback, and a description of what you
    were doing when the error occurred.

Revision history for this message
Jelmer Vernooij (jelmer) wrote : Re: [Bug 296868] [NEW] Problem with svn cache when using Python 2.6

Thanks!

  status triaged
  importance medium
--
Jelmer Vernooij <email address hidden> - http://samba.org/~jelmer/
Jabber: <email address hidden>

Changed in bzr-svn:
importance: Undecided → Medium
status: New → Triaged
Jelmer Vernooij (jelmer)
Changed in bzr-svn:
milestone: none → 0.5.0
Jelmer Vernooij (jelmer)
Changed in bzr-svn:
assignee: nobody → jelmer
status: Triaged → 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.