diff options
| author | Adrian Torres <adt@odoo.com> | 2018-11-08 15:27:30 +0000 |
|---|---|---|
| committer | Adrian Torres <adt@odoo.com> | 2018-11-29 09:28:17 +0000 |
| commit | 52f5528cfb6d1152ee226e268247dc685a8ba329 (patch) | |
| tree | b44ecfa477b50dd3e488f09f623eecc8bc8e9d7d /odoo/tools/appdirs.py | |
| parent | e5c864a596b72515837f0ed1e07550398ecc1ab0 (diff) | |
[REF] *: replace deprecated pycompat helpers for builtins
This commit replaces calls to pycompat helpers that were intended for
python 2 <-> python 3 interoperability for python 3 builtins, as python
2 is no longer officially supported by Odoo.
This includes:
* calls to imap/izip/ifilter replaced by map/zip/filter
* uses of text_type replaced by str
* uses of unichr replaced by chr
* calls to implements_to_string, implements_iterator removed
* string_types and integer_types replaced by str, int respectively
* calls to to_native replaced by calls to to_text
This is done in preparation to the removal of these deprecated helpers
in the following commit.
Diffstat (limited to 'odoo/tools/appdirs.py')
| -rw-r--r-- | odoo/tools/appdirs.py | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/odoo/tools/appdirs.py b/odoo/tools/appdirs.py index 5bd5afb11cb..67ba75625c1 100644 --- a/odoo/tools/appdirs.py +++ b/odoo/tools/appdirs.py @@ -13,7 +13,6 @@ from __future__ import print_function # http://support.microsoft.com/default.aspx?scid=kb;en-us;310294#XSLTH3194121123120121120120 # - Mac OS X: http://developer.apple.com/documentation/MacOSX/Conceptual/BPFileSystem/index.html # - XDG spec for Un*x: http://standards.freedesktop.org/basedir-spec/basedir-spec-latest.html -from . import pycompat __version_info__ = (1, 3, 0) __version__ = '.'.join(str(v) for v in __version_info__) @@ -392,7 +391,7 @@ def _get_win_folder_with_pywin32(csidl_name): # not return unicode strings when there is unicode data in the # path. try: - dir = pycompat.text_type(dir) + dir = str(dir) # Downgrade to short path name if have highbit chars. See # <http://bugs.activestate.com/show_bug.cgi?id=85099>. |
