autowrap icon indicating copy to clipboard operation
autowrap copied to clipboard

22.9 chokes on templated vector

Open poshul opened this issue 2 years ago • 6 comments

https://github.com/OpenMS/autowrap/blob/26dc527b449c45f89c135337cd59a037a88fe76b/autowrap/CodeGenerator.py#L1069

The latest master chokes building OpenMS trying to wrap: libcpp_vector[ String ] colTypes

Traceback (most recent call last): File "/home/samuel/.local/lib/python3.9/site-packages/autowrap-0.22.9-py3.9.egg/autowrap/CodeGenerator.py", line 671, in create_wrapper_for_class pyx_code, stub_code = self._create_wrapper_for_attribute(attribute) File "/home/samuel/.local/lib/python3.9/site-packages/autowrap-0.22.9-py3.9.egg/autowrap/CodeGenerator.py", line 1069, in _create_wrapper_for_attribute access_stmt = converter.call_method(t, "self.inst.get().%s" % name, False) TypeError: call_method() takes 3 positional arguments but 4 were given

poshul avatar May 02 '22 14:05 poshul

The interface for ConversionProviders changed. Please adapt their methods.

jpfeuffer avatar May 02 '22 15:05 jpfeuffer

So I've just had another look at this. It's something internal to autowrap, the call_method function has been updated in ConversionProvider in b9809a3752cf75cd40a9d3a988ad734611382ae9, but it's also been updated in CodeGenerator. No idea why I'm seeing a mismatch in the number of positional arguments.

poshul avatar May 10 '22 14:05 poshul

You need to update the inherited functions of the conversion providers. The call_method function of the abstract interface has a new Parameter

jpfeuffer avatar May 10 '22 14:05 jpfeuffer

~Hey @poshul I was just looking through the autorwrap issues and looking at this one. Did you ever get through this problem? I have a theory about what is going on but I don't want to go too far down a rabbit hole if you have already figured it out.~

Never mind, my theory ended up being incorrect 😅 .

erik-whiting avatar Jun 25 '22 20:06 erik-whiting

I've not followed up on this. I'd be happy to hear your theory.

On Sat, Jun 25, 2022 at 10:24 PM Erik Whiting @.***> wrote:

Hey @poshul https://github.com/poshul I was just looking through the autorwrap issues and looking at this one. Did you ever get through this problem? I have a theory about what is going on but I don't want to go too far down a rabbit hole if you have already figured it out.

— Reply to this email directly, view it on GitHub https://github.com/OpenMS/autowrap/issues/155#issuecomment-1166356084, or unsubscribe https://github.com/notifications/unsubscribe-auth/AABD3C6BJMLFISULMDADNALVQ5TJRANCNFSM5U4FUI4A . You are receiving this because you were mentioned.Message ID: @.***>

poshul avatar Jun 27 '22 12:06 poshul

You need to update the inherited functions of the conversion providers. The call_method function of the abstract interface has a new Parameter

Have you tried this?

jpfeuffer avatar Jun 27 '22 13:06 jpfeuffer