traceback running merge involving non-ascii filenames with ascii locale set

Bug #274100 reported by kir666
4
Affects Status Importance Assigned to Milestone
Bazaar
Confirmed
Low
Unassigned

Bug Description

traceback

bzr: ERROR: exceptions.UnicodeEncodeError: 'ascii' codec can't encode characters in position 54-62: ordinal not in range(128)

Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/bzrlib/commands.py", line 857, in run_bzr_catch_errors
    return run_bzr(argv)
  File "/usr/lib/python2.5/site-packages/bzrlib/commands.py", line 797, in run_bzr
    ret = run(*run_argv)
  File "/usr/lib/python2.5/site-packages/bzrlib/commands.py", line 499, in run_argv_aliases
    return self.run(**all_cmd_args)
  File "/usr/lib/python2.5/site-packages/bzrlib/builtins.py", line 1039, in run
    possible_transports=possible_transports)
  File "/usr/lib/python2.5/site-packages/bzrlib/workingtree.py", line 2133, in update
    return self._update_tree(old_tip, change_reporter)
  File "/usr/lib/python2.5/site-packages/bzrlib/mutabletree.py", line 52, in tree_write_locked
    return unbound(self, *args, **kwargs)
  File "/usr/lib/python2.5/site-packages/bzrlib/workingtree.py", line 2173, in _update_tree
    change_reporter=change_reporter)
  File "/usr/lib/python2.5/site-packages/bzrlib/merge.py", line 1209, in merge_inner
    return merger.do_merge()
  File "/usr/lib/python2.5/site-packages/bzrlib/merge.py", line 445, in do_merge
    self._do_merge_to(merge)
  File "/usr/lib/python2.5/site-packages/bzrlib/merge.py", line 417, in _do_merge_to
    merge.do_merge()
  File "/usr/lib/python2.5/site-packages/bzrlib/merge.py", line 529, in do_merge
    self._compute_transform()
  File "/usr/lib/python2.5/site-packages/bzrlib/merge.py", line 567, in _compute_transform
    file_status = self.merge_contents(file_id)
  File "/usr/lib/python2.5/site-packages/bzrlib/merge.py", line 840, in merge_contents
    self.other_tree, trans_id)
  File "/usr/lib/python2.5/site-packages/bzrlib/transform.py", line 2103, in create_by_entry
    tt.create_file(lines, trans_id, mode_id=mode_id)
  File "/usr/lib/python2.5/site-packages/bzrlib/transform.py", line 338, in create_file
    f = open(name, 'wb')
UnicodeEncodeError: 'ascii' codec can't encode characters in position 54-62: ordinal not in range(128)

bzr 1.7 on python 2.5.2 (linux2)
arguments: ['/usr/bin/bzr', 'update']
encoding: 'ANSI_X3.4-1968', fsenc: 'ANSI_X3.4-1968', lang: None
plugins:
  bzrtools /usr/lib/python2.5/site-packages/bzrlib/plugins/bzrtools [1.7.0]
*** 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
John A Meinel (jameinel) wrote :

Your system is telling us that paths are encoded in "ASCII", but you are trying to checkout a file which is not ASCII.

Probably it is just a configuration issue. I don't know your preferred language, but doing something like:

export LANG=en_US.UTF-8
bzr update

will cause it to work. As that tells us that things are actually encoded in UTF-8, and thus we can handle non-ascii characters.

Revision history for this message
kir666 (kir-exe) wrote :

Thanks. It works now with LANG=*UTF-8. But anyway traceback in this situation is not the best choice.

Jelmer Vernooij (jelmer)
Changed in bzr:
importance: Undecided → Low
status: New → Triaged
summary: - bzr v1.7.0 crashes on 'bzr update'
+ traceback running merge involving non-ascii filenames with ascii locale
+ set
Martin Pool (mbp)
Changed in bzr:
status: Triaged → Confirmed
Jelmer Vernooij (jelmer)
tags: added: encoding merge
Jelmer Vernooij (jelmer)
tags: added: check-for-breezy
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.