Commit 5cc606e4 authored by Jérome Perrin's avatar Jérome Perrin

promise_plugin: fix dictionary changed size during iteration

parent 63131789
......@@ -47,7 +47,7 @@ extra_config_dict = %(config)s
# The solution is to delete all cached 'slapos' modules as well as all cached
# 'pkg_resources' modules which is responsible of namespace declaration.
# They will be re-imported again using the updated sys.path
for module in sys.modules.keys():
for module in list(sys.modules):
if 'slapos' in module or 'pkg_resources' in module:
del sys.modules[module]
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment