Load module in function and make it globally available
I had the task to load a Pyhton-module within the ‘main’ function, but it must be globally available!
I found some solutions but they did not work…
…but finally, I found the correct solution:
exec("import my_module") in globals()
This implementation works great, solves my problem very good and I have not found any critical annotations!