You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm experiencing an issue with pyobjus in a Kivy project, from which I need to use the iOS content sharing API (UIKit framework), and I'm stuck because calls to this method from python causes a random malloc error.
I managed to isolate the issue, with the following minimum reproductible example:
Let's define a dummy class in ObjectiveC, with two dummy methods that take a single CGRect argument, and only logs the rect value.
One method takes its argument as a pointer, and the other as a value:
When I try to access these methods from python, I have no issue with the rect_pointer method, but rect_value produces a random malloc error.
Python code:
from pyobjus import autoclass, NSRect, NSPoint, NSSize
foo = autoclass("foo")
f = foo.alloc().init()
pos = NSPoint(0,0)
size = NSSize(100, 100)
rect = NSRect(pos, size)
# this works perfectly
for i in range(10):
f.rect_pointer_(rect)
# this fails after a random number of iterations
for i in range(10):
f.rect_value_(rect)
I'm executing it on iOS, either on a real device (iPad mini 6th generation) or a simulator.
Hello everyone,
I'm experiencing an issue with pyobjus in a Kivy project, from which I need to use the iOS content sharing API (UIKit framework), and I'm stuck because calls to this method from python causes a random malloc error.
I managed to isolate the issue, with the following minimum reproductible example:
Let's define a dummy class in ObjectiveC, with two dummy methods that take a single CGRect argument, and only logs the rect value.
One method takes its argument as a pointer, and the other as a value:
When I try to access these methods from python, I have no issue with the
rect_pointer
method, butrect_value
produces a random malloc error.Python code:
I'm executing it on iOS, either on a real device (iPad mini 6th generation) or a simulator.
The text was updated successfully, but these errors were encountered: