1
0
forked from VimPlug/jedi

Add a test to avoid encoding issues. Fixes #1003

This commit is contained in:
Dave Halter
2018-01-20 18:28:29 +01:00
parent 16b463a646
commit 877383b110
5 changed files with 20 additions and 10 deletions
+2 -1
View File
@@ -369,8 +369,9 @@ class Importer(object):
else:
module_path = get_init_path(module_path)
elif module_file:
code = module_file.read()
module_file.close()
with open(module_path, 'rb') as f:
code = f.read()
if isinstance(module_path, ImplicitNSInfo):
from jedi.evaluate.context.namespace import ImplicitNamespaceContext