Graham Dumpleton
Graham Dumpleton
It possibly relates to a deficiency in the Python C APIs whereby there is no equivalent to `hasattr()`. There are certain cases when accessing attributes that if an exception occurs...
Will have to do some more testing but I think it is this function: ``` static PyObject *WraptObjectProxy_getattro( WraptObjectProxyObject *self, PyObject *name) { PyObject *object = NULL; PyObject *result =...
I should clarify there does exist ``PyObject_HasAttr()`` but there must have been something about it which was problematic when used in this situation. Note that it isn't named ``PyObject_GenericHasAttr()`` and...
So as explained above, what I could do is: ``` object = PyObject_GenericGetAttr((PyObject *)self, name); if (object) return object; if (!PyErr_ExceptionMatches(PyExc_AttributeError)) return NULL; PyErr_Clear(); ``` but you would still get...
This is the ultimately the fault of the Python packaging system. Prior to wheels, when installing wrapt if the compilation of the C extension failed the setup.py would through some...
When I mean Python packaging I specifically mean setuptools. In distutils I could implement the fallback to pure Python, but not in setuptools. For performance differences see: * https://wrapt.readthedocs.io/en/latest/benchmarks.html
BTW, does pyodide have its own specific platform designator for Python wheels. So if PyPi hosted something like `wrapt-1.13.3-whatpyodieuses.whl` which was a source wheel, would it use it. Would be...
Not sure if that helps me at this point. I am assuming I would need a way from cibuildwheel infrastructure I use from GitHub actions to generate a specific wheel...
I guess I probably just need to do that distinct from cibuildwheel parts of build following something like: * https://stackoverflow.com/questions/66334450/how-to-build-py3-none-any-wheels-for-a-project-with-an-optional-c-extension I'll see if I can some time to play with...
See: * https://wrapt.readthedocs.io/en/latest/wrappers.html?highlight=_self_#proxy-object-attributes In other words use the convention: ``` bar._self_myattr = 1 ``` If you want the attribute on the wrapper and not the wrapped object.