bzr add fails on evil file name

Bug #239006 reported by Peter Hodge
2
Affects Status Importance Assigned to Milestone
Bazaar
New
Undecided
Unassigned

Bug Description

Running Python 2.5.2 on OS X 10.4, it seems that either the backslash or parenthesis are not supported by bzr. Yes, I am trying to commit my home folder ...

peter$ bzr add
[snipped adding many files]
added ".Trash/Recovered files #25/TextMate/TextMate.app/Contents/SharedSupport/Bundles/Latex.tmbundle/Snippets/Math mode \( \).plist"
bzr: ERROR: bzrlib.errors.InvalidEntryName: Invalid entry name: Math mode \( \).plist

Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/commands.py", line 846, in run_bzr_catch_errors
    return run_bzr(argv)
  File "/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/commands.py", line 797, in run_bzr
    ret = run(*run_argv)
  File "/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/commands.py", line 499, in run_argv_aliases
    return self.run(**all_cmd_args)
  File "/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/builtins.py", line 373, in run
    no_recurse, action=action, save=not dry_run)
  File "/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/mutabletree.py", line 52, in tree_write_locked
    return unbound(self, *args, **kwargs)
  File "/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/mutabletree.py", line 406, in smart_add
    _add_one(self, inv, parent_ie, directory, kind, action)
  File "/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/mutabletree.py", line 574, in _add_one
    file_id=file_id)
  File "/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/inventory.py", line 985, in make_entry
    return make_entry(kind, name, parent_id, file_id)
  File "/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/inventory.py", line 1312, in make_entry
    return factory(file_id, name, parent_id)
  File "/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/inventory.py", line 545, in __init__
    super(InventoryFile, self).__init__(file_id, name, parent_id)
  File "/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/inventory.py", line 215, in __init__
    raise errors.InvalidEntryName(name=name)
InvalidEntryName: Invalid entry name: Math mode \( \).plist

bzr 1.5 on python 2.5.2 (darwin)
arguments: ['/usr/bin/bzr', 'add']
encoding: 'US-ASCII', fsenc: 'utf-8', lang: None
plugins:
  bzrtools /Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/plugins/bzrtools [1.5.0]
  email /Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/plugins/email [unknown]
  extmerge /Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/plugins/extmerge [unknown]
  launchpad /Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/plugins/launchpad [unknown]
  qbzr /Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/plugins/qbzr [0.9.0]
  rebase /Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib/plugins/rebase [0.3.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.

=====

peter$ bzr version
Bazaar (bzr) 1.5
  Python interpreter: /Library/Frameworks/Python.framework/Versions/2.5/Resources/Python.app/Contents/MacOS/Python 2.5.2
  Python standard library: /Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5
  bzrlib: /Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/site-packages/bzrlib
  Bazaar configuration: /Users/peter/.bazaar
  Bazaar log file: /Users/peter/.bzr.log

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.