I am loading objects (configuration really) from a file into some special module like this:
import importlib modname = "__config__" spec = importlib