The Boost documentation does not specify this. When I use boost::python::import, where exactly is the specified module imported? My guess would be in '__main__'
(just to make sure).
Also, what happens when the module object goes out of scope? Given the wording in Boost's docs — "Returns: An instance of object which holds a reference to the imported module" — I would guess only the reference goes out of scope, the module object is still found within '__main__'
(or wherever it was imported).