Importing rubicon.objs hangs on pypy
Describe the bug
When I try to import rubicon.objc using Pypy, the process hangs while it allocates more and more memory. I traced this down to this line, and it seems to be related to the PyDictObject:
https://github.com/beeware/rubicon-objc/blob/6c3d6b663b2a754506c3115dc37a769f832b6395/src/rubicon/objc/ctypes_patch.py#L121-L132
With "traced it down" I mean that I put 1/0 in the code to make it raise an exception. If the it hung instead of raising the exception, then the hangup occurred bedore it. The code above is where it hangs. And if I comment the field with the PyDictObject, then it does not hang, so it looks like it's related to that.
I tried with pypy3.8-7.3.11 and pypy3.9-7.3.11, both installed via pyenv.
Steps to reproduce
Run import ubicon.objc in a pypy interpreter. The process hangs, does not respond to ctrl-c.
Expected behavior
I would expect the import to work :)
Screenshots
No response
Environment
MacOS M1 pro Sonoma 14.3
Logs
Additional context
No response
Thanks for the report; we don't include PyPy in our testing, and I can't claim any particular expertise with PyPy, so I can't comment on what is going on here. If anyone is able to provide a patch, I'm happy to apply it.