Fix a potential issue with the loading of settings.
This commit is contained in:
1 parent
42bf193af8
commit
cd9a8705a2
1 file changed
+3
-1
@@ -507,7 +507,9 @@ def get_modules_containing_name(evaluator, mods, name):
|
|||||||
paths = set(settings.additional_dynamic_modules)
|
paths = set(settings.additional_dynamic_modules)
|
||||||
for p in mod_paths:
|
for p in mod_paths:
|
||||||
if p is not None:
|
if p is not None:
|
||||||
d = os.path.dirname(p)
|
# We need abspath, because the seetings paths might not already
|
||||||
|
# have been converted to absolute paths.
|
||||||
|
d = os.path.dirname(os.path.abspath(p))
|
||||||
for entry in os.listdir(d):
|
for entry in os.listdir(d):
|
||||||
if entry not in mod_paths:
|
if entry not in mod_paths:
|
||||||
if entry.endswith('.py'):
|
if entry.endswith('.py'):
|
||||||
|
|||||||
Reference in new issue
Block a user