[C++-sig] Re: to_python_converter error question ...

David Abrahams dave at boost-consulting.com
Thu Sep 11 16:21:47 CEST 2003


Pierre Barbier de Reuille <pierre.barbier at cirad.fr> writes:

> When I try to import a module I made, I have the error :
>
> RuntimeError: trying to register to_python_converter for a type which
> already has a registered to_python_converter
>
> But when I re-import it, it just works ... is it normal ??? 

I think the module only gets initialized once.

> Then another question : how to know which converter is duplicated ?

Nasty.  I have to improve that message.

> Is it possible to trace what python do when importing ?

Sure; use your favorite debugger.  Search the Boost.Python sources
for the error message and set a breakpoint.

-- 
Dave Abrahams
Boost Consulting
www.boost-consulting.com





More information about the Cplusplus-sig mailing list