Message3696
Here is my workarounds
in lib\os.py:
def makedirs(path, mode='ignored'):
"""makedirs(path [, mode=0777])
Super-mkdir; create a leaf directory and all intermediate ones.
Works like mkdir, except that any intermediate path segment (not
just the rightmost) will be created if it does not exist.
The optional parameter is currently ignored.
"""
sys_path = sys.getPath(path)
if File(sys_path).mkdirs():
return
if(sys_path[-1]=='\\'):
if File(sys_path[:-2]).mkdirs():
return
# if making a /x/y/z/., java.io.File#mkdirs inexplicably fails. So
we need
# to force it
# need to use _path instead of path, because param is hiding
# os.path module in namespace!
head, tail = _path.split(sys_path)
if tail == curdir:
if File(_path.join(head)).mkdirs():
return
if(_path.join(head)[-1]=='\\'):
if File(_path.join(head)[:-2]).mkdirs():
return
raise OSError(0, "couldn't make directories", path) |
|
Date |
User |
Action |
Args |
2008-10-20 00:27:41 | bupjae | set | messageid: <1224462461.64.0.570864647527.issue1110@psf.upfronthosting.co.za> |
2008-10-20 00:27:41 | bupjae | set | recipients:
+ bupjae, nriley, jy123 |
2008-10-20 00:27:41 | bupjae | link | issue1110 messages |
2008-10-20 00:27:41 | bupjae | create | |
|