[issue9394] shelve.open/bsddb.hashopen raise bsddb.db.DBNoSuchFileError: (2, 'No such file or directory') with Chinese Path

2010-07-28 Thread wjm251

New submission from wjm251 wjm...@gmail.com:

Windows XP Simple Chinese Version
in python2.5,Python 2.5.4 (r254:67916, Dec 23 2008, 15:10:54) [MSC v.1310 32 
bit (Intel)] on win32
I have a directory D:\你好新建文件夹
my code is as follows: 
#--
temppath = uD:\\你好新建文件夹\\a
import shelve
cache = shelve.open(temppath, 'c')
#--

when use temppath.encode(utf-8),it works,
but in python2.6,temppath can works properly

but I got a Error with such traceback

Traceback (most recent call last):
  File D:\eclipse_workspace\pytest\src\test.py, line 5, in module
cache = shelve.open(temppath, 'c')
  File 
D:\eclipse_workspace\omstarv5r6\linksvn\src\UNPPython\pywindows\Lib\shelve.py,
 line 225, in open
return DbfilenameShelf(filename, flag, protocol, writeback)
  File 
D:\eclipse_workspace\omstarv5r6\linksvn\src\UNPPython\pywindows\Lib\shelve.py,
 line 209, in __init__
Shelf.__init__(self, anydbm.open(filename, flag), protocol, writeback)
  File 
D:\eclipse_workspace\omstarv5r6\linksvn\src\UNPPython\pywindows\Lib\anydbm.py,
 line 83, in open
return mod.open(file, flag, mode)
  File 
D:\eclipse_workspace\omstarv5r6\linksvn\src\UNPPython\pywindows\Lib\dbhash.py,
 line 16, in open
return bsddb.hashopen(file, flag, mode)
  File 
D:\eclipse_workspace\omstarv5r6\linksvn\src\UNPPython\pywindows\Lib\bsddb\__init__.py,
 line 310, in hashopen
d.open(file, db.DB_HASH, flags, mode)
bsddb.db.DBNoSuchFileError: (2, 'No such file or directory')

--
components: Library (Lib)
messages: 111780
nosy: wjm251
priority: normal
severity: normal
status: open
title: shelve.open/bsddb.hashopen raise bsddb.db.DBNoSuchFileError: (2, 'No 
such file or directory') with Chinese Path
type: behavior
versions: Python 2.5

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9394
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9394] shelve.open/bsddb.hashopen raise bsddb.db.DBNoSuchFileError: (2, 'No such file or directory') with Chinese Path

2010-07-28 Thread Éric Araujo

Changes by Éric Araujo mer...@netwok.org:


--
resolution:  - duplicate
stage:  - committed/rejected
status: open - closed
superseder:  - shelve.open/bsddb.hashopen raise Exception'No such file or 
directory'for Chinese path

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9394
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com