possibly solved issue 1617? thanks fredcy
This commit is contained in:
committed by
Michele Comitini
parent
a122215b41
commit
b13c2cf6e3
@@ -1 +1 @@
|
|||||||
Version 2.6.0-development+timestamp.2013.08.27.22.25.14
|
Version 2.6.0-development+timestamp.2013.08.28.09.56.28
|
||||||
|
|||||||
+8
-12
@@ -119,8 +119,6 @@ class TrackImporter(object):
|
|||||||
globals = globals or {}
|
globals = globals or {}
|
||||||
locals = locals or {}
|
locals = locals or {}
|
||||||
fromlist = fromlist or []
|
fromlist = fromlist or []
|
||||||
if not hasattr(self.THREAD_LOCAL, '_modules_loaded'):
|
|
||||||
self.THREAD_LOCAL._modules_loaded = set()
|
|
||||||
try:
|
try:
|
||||||
# Check the date and reload if needed:
|
# Check the date and reload if needed:
|
||||||
self._update_dates(name, globals, locals, fromlist, level)
|
self._update_dates(name, globals, locals, fromlist, level)
|
||||||
@@ -175,16 +173,14 @@ class TrackImporter(object):
|
|||||||
if reload_mod or not date or new_date > date:
|
if reload_mod or not date or new_date > date:
|
||||||
self._import_dates[file] = new_date
|
self._import_dates[file] = new_date
|
||||||
if reload_mod or (date and new_date > date):
|
if reload_mod or (date and new_date > date):
|
||||||
if module not in self.THREAD_LOCAL._modules_loaded:
|
if mod_to_pack:
|
||||||
if mod_to_pack:
|
# Module turning into a package:
|
||||||
# Module turning into a package:
|
mod_name = module.__name__
|
||||||
mod_name = module.__name__
|
del sys.modules[mod_name] # Delete the module
|
||||||
del sys.modules[mod_name] # Delete the module
|
# Reload the module:
|
||||||
# Reload the module:
|
NATIVE_IMPORTER(mod_name, globals, locals, [], level)
|
||||||
NATIVE_IMPORTER(mod_name, globals, locals, [], level)
|
else:
|
||||||
else:
|
reload(module)
|
||||||
reload(module)
|
|
||||||
self.THREAD_LOCAL._modules_loaded.add(module)
|
|
||||||
|
|
||||||
def _get_module_file(self, module):
|
def _get_module_file(self, module):
|
||||||
"""
|
"""
|
||||||
|
|||||||
Reference in New Issue
Block a user