Jani,
can you try what John Reid proposed but instead of
py::with_custodian_and_ward< 1, 2 >()
please try to use
py::with_custodian_and_ward< 2, 1 >()
or (more likely to work)
py::with_custodian_and_ward_postcall< 2, 1 >()
This should bind the lifetime of `self` to i
Ok, last suggestions were closest I could get: Now I see that data is
deleted within owner destructor but still I get error messages that data
objects are being deleted directly second time by Python.
So now I need some way to say to python that "data" classes are not
meant to be deleted by py