[C++-sig] Calling reload() or PyImport_ReloadModule on modules implementing Boost.Python extensions
Brandon Kohn
blkohn at hotmail.com
Sat Apr 26 16:13:25 CEST 2008
Hello ladies and gents,
I've been struggling for a day trying to get a system I've built using
Boost.Python to be able to reload modules which hold python classes which
derive from a C++ class via Boost.Python. I've tried both the
PyImport_ReloadModule command and attempting to affect a reload internally
from python via reload(). Niether has resulted in success. My question to
the community is if anyone knows if this is even possible from a C++
extension with the current Boost.Python library? The code in question
doesn't involve a recompile of any C++ dlls.. I only want to be able to make
small changes to python scripts and then be able to reload them and
reinstantiate associated instances of their classes without restarting my
application. Is the answer to abandon Boost.Python and just go for a raw
implementation via the C API?
Cheers,
Brandon
More information about the Cplusplus-sig
mailing list