More unicode conversions
This commit is contained in:
1 parent
a117f9f2e7
commit
40f1354f67
4 files changed
+7
-8
No files matched your search
@@ -207,7 +207,7 @@ class DirectObjectAccess(object):
|
||||
return None
|
||||
|
||||
try:
|
||||
return cls.__name__
|
||||
return u(cls.__name__)
|
||||
except AttributeError:
|
||||
return None
|
||||
|
||||
@@ -311,8 +311,10 @@ class DirectObjectAccess(object):
|
||||
|
||||
def get_access_path_tuples(self):
|
||||
return [
|
||||
(getattr(o, '__name__', None), create_access(self._evaluator, o))
|
||||
for o in self._get_objects_path()
|
||||
(
|
||||
u(getattr(o, '__name__', None), errors='replace'),
|
||||
create_access(self._evaluator, o)
|
||||
) for o in self._get_objects_path()
|
||||
]
|
||||
|
||||
def _get_objects_path(self):
|
||||
|
||||
@@ -284,7 +284,7 @@ class AccessHandle(object):
|
||||
if name in ('id', 'access') or name.startswith('_'):
|
||||
raise AttributeError("Something went wrong with unpickling")
|
||||
|
||||
#print >> sys.stderr, name
|
||||
#if not is_py3: print >> sys.stderr, name
|
||||
#print('getattr', name, file=sys.stderr)
|
||||
return partial(self._workaround, name)
|
||||
|
||||
|
||||
@@ -17,8 +17,6 @@ def load_module(evaluator, **kwargs):
|
||||
|
||||
def get_compiled_method_return(evaluator, id, attribute, *args, **kwargs):
|
||||
handle = evaluator.compiled_subprocess.get_access_handle(id)
|
||||
# print >> sys.stderr, handle, attribute, args, kwargs
|
||||
# print(id, attribute, args, kwargs, file=sys.stderr)
|
||||
return getattr(handle.access, attribute)(*args, **kwargs)
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user