equal
deleted
inserted
replaced
39 |
39 |
40 def exec_module(self, module): |
40 def exec_module(self, module): |
41 """Make the module load lazily.""" |
41 """Make the module load lazily.""" |
42 with tracing.log('demandimport %s', module): |
42 with tracing.log('demandimport %s', module): |
43 if _deactivated or module.__name__ in ignores: |
43 if _deactivated or module.__name__ in ignores: |
|
44 # Reset the loader on the module as super() does (issue6725) |
|
45 module.__spec__.loader = self.loader |
|
46 module.__loader__ = self.loader |
|
47 |
44 self.loader.exec_module(module) |
48 self.loader.exec_module(module) |
45 else: |
49 else: |
46 super().exec_module(module) |
50 super().exec_module(module) |
47 |
51 |
48 |
52 |