authentication.conf with german "umlaut" gives a traceback

Bug #691642 reported by Peter Klötzer
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Bazaar
New
Undecided
Unassigned

Bug Description

Show Log crashes, if the line:

#test ÄäÖöÜüß

is present in file authentication.conf. All is O.K. if this line is deleted. I got the following Exeption, when i use the right mouse key and "Show Log". If I click on the clock Symbol on the main window, the "Show Log Window" disapears without any message.

bzr: ERROR: exceptions.UnicodeDecodeError: 'utf8' codec can't decode bytes in position 6-7: invalid data

Traceback (most recent call last):
  File "C:/Program Files (x86)/Bazaar/plugins\qbzr\lib\trace.py", line 300, in reports_exception_decorate
  File "C:/Program Files (x86)/Bazaar/plugins\qbzr\lib\log.py", line 231, in load
  File "C:/Program Files (x86)/Bazaar/plugins\qbzr\lib\logwidget.py", line 199, in load_branch
  File "C:/Program Files (x86)/Bazaar/plugins\qbzr\lib\loggraphprovider.py", line 322, in open_branch
  File "C:/Program Files (x86)/Bazaar/plugins\qbzr\lib\loggraphprovider.py", line 297, in branch_label
  File "bzrlib\branch.pyo", line 248, in _get_nick
  File "bzrlib\decorators.pyo", line 140, in read_locked
  File "bzrlib\branch.pyo", line 2694, in get_master_branch
  File "bzrlib\branch.pyo", line 167, in open
  File "bzrlib\bzrdir.pyo", line 911, in open
  File "bzrlib\bzrdir.pyo", line 941, in open_from_transport
  File "bzrlib\transport\__init__.pyo", line 1657, in do_catching_redirections
  File "bzrlib\bzrdir.pyo", line 928, in find_format
  File "bzrlib\bzrdir.pyo", line 1949, in find_format
  File "bzrlib\bzrdir.pyo", line 1959, in probe_transport
  File "bzrlib\transport\sftp.pyo", line 435, in get_bytes
  File "bzrlib\transport\sftp.pyo", line 425, in get
  File "bzrlib\transport\sftp.pyo", line 397, in _get_sftp
  File "bzrlib\transport\sftp.pyo", line 389, in _create_connection
  File "bzrlib\transport\ssh.pyo", line 321, in connect_sftp
  File "bzrlib\transport\ssh.pyo", line 317, in _connect
  File "bzrlib\transport\ssh.pyo", line 543, in _paramiko_auth
  File "bzrlib\config.pyo", line 1215, in get_password
  File "bzrlib\config.pyo", line 1043, in get_credentials
  File "bzrlib\config.pyo", line 986, in _get_config
  File "bzrlib\config.pyo", line 144, in ConfigObj
  File "bzrlib\util\configobj\configobj.pyo", line 1223, in __init__
  File "bzrlib\util\configobj\configobj.pyo", line 1276, in _load
  File "bzrlib\util\configobj\configobj.pyo", line 1412, in _handle_bom
  File "bzrlib\util\configobj\configobj.pyo", line 1472, in _decode
  File "encodings\utf_8.pyo", line 16, in decode
UnicodeDecodeError: 'utf8' codec can't decode bytes in position 6-7: invalid data

bzr 2.2.1 on python 2.6.4 (win32)
arguments: ['C:\\Program Files (x86)\\Bazaar\\bzrw.exe', 'explorer']
encoding: 'cp1252', fsenc: 'mbcs', lang: None
plugins:
  bzrtools C:\Program Files (x86)\Bazaar\plugins\bzrtools [2.2.0]
  colo C:\Program Files (x86)\Bazaar\plugins\colo [0.1.0]
  explorer C:\Program Files (x86)\Bazaar\plugins\explorer [1.1.1]
  fastimport C:\Program Files (x86)\Bazaar\plugins\fastimport [0.9.0dev]
  launchpad C:\Program Files (x86)\Bazaar\plugins\launchpad [2.2.1]
  loom C:\Program Files (x86)\Bazaar\plugins\loom [2.2.1dev]
  netrc_credential_store C:\Program Files (x86)\Bazaar\plugins\netrc_credential_store [2.2.1]
  news_merge C:\Program Files (x86)\Bazaar\plugins\news_merge [2.2.1]
  pipeline C:\Program Files (x86)\Bazaar\plugins\pipeline [unknown]
  qbzr C:\Program Files (x86)\Bazaar\plugins\qbzr [0.19.2]
  rewrite C:\Program Files (x86)\Bazaar\plugins\rewrite [0.6.1]
  svn C:\Program Files (x86)\Bazaar\plugins\svn [1.0.4]
  upload C:\Program Files (x86)\Bazaar\plugins\upload [1.0.0dev]
  xmloutput C:\Program Files (x86)\Bazaar\plugins\xmloutput [0.8.6]

Revision history for this message
Alexander Belchenko (bialix) wrote :

authentication.conf should be in UTF-8 encoding. It seems you've tried to see the log for remote branch and bzr itself tries to determine credentials for access to your branch.

Unfortunately I don't know what qbzr/explorer can do about it. The error comes from bzr itself.

affects: bzr-explorer → bzr
Revision history for this message
Vincent Ladeuil (vila) wrote : Re: [Bug 691642] [NEW] authentication.conf w/o german "umlaut"

>>>>> Launchpad Bug Tracker writes:

    > You have been subscribed to a public bug:
    > Show Log crashes, if the line:

    > #test ÄäÖöÜüß

    > is present in file authentication.conf. All is O.K. if this line is
    > deleted. I got the following Exeption, when i use the right mouse key
    > and "Show Log". If I click on the clock Symbol on the main window, the
    > "Show Log Window" disapears without any message.

This is very confusing...

I could understand if 'ÄäÖöÜüß' was *present* in the file in some
encoding that 'utf-8' *can't* decode.

Can you check that an *empty* authentication.conf doesn't trigger the
problem ?

If that's the case try adding various strings (with and without umlaut)
until you trigger the bug and attach the resulting file.

Revision history for this message
Vincent Ladeuil (vila) wrote : Re: authentication.conf w/o german "umlaut"

@mgz: Yeah, but I'd like confirmation that it's the *presence* of the chars not their *absence* that is triggering the bug.

Vincent Ladeuil (vila)
summary: - authentication.conf w/o german "umlaut"
+ authentication.conf with german "umlaut" gives a traceback
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.