[FIX] tools,addons: increased support for installation paths containing non-ascii characters
lp bug: https://launchpad.net/bugs/563029 fixed bzr revid: odo@openerp.com-20101230014831-jefjtmgy0a10a4mk
This commit is contained in:
@@ -47,8 +47,8 @@ import logging
|
||||
|
||||
logger = netsvc.Logger()
|
||||
|
||||
_ad = os.path.abspath(opj(tools.config['root_path'], 'addons')) # default addons path (base)
|
||||
ad_paths= map(lambda m: os.path.abspath(m.strip()),tools.config['addons_path'].split(','))
|
||||
_ad = os.path.abspath(opj(tools.ustr(tools.config['root_path']), u'addons')) # default addons path (base)
|
||||
ad_paths= map(lambda m: os.path.abspath(tools.ustr(m.strip())), tools.config['addons_path'].split(','))
|
||||
|
||||
sys.path.insert(1, _ad)
|
||||
|
||||
|
||||
+1
-1
@@ -262,7 +262,7 @@ def file_open(name, mode="r", subdir='addons', pathinfo=False):
|
||||
return fo
|
||||
if os.path.splitext(name)[1] == '.rml':
|
||||
raise IOError, 'Report %s doesn\'t exist or deleted : ' %str(name)
|
||||
raise IOError, 'File not found : '+str(name)
|
||||
raise IOError, 'File not found : %s' % name
|
||||
|
||||
|
||||
#----------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user