zopefoundation / persistent

automatic persistence for Python objects
https://pypi.org/project/persistent/
Other
46 stars 28 forks source link

Add the ability to force use of C extensions. #132

Closed jamadden closed 4 years ago

jamadden commented 4 years ago

With PURE_PYTHON=0, like in zope.interface.

Also always require all three extensions. This solves mysterious issues you can get if you wind up mixing and matching (#124).

Fixes #131

Add travis and tox tests for this.

jamadden commented 4 years ago

Rebased on master.

icemac commented 4 years ago

TravisCI is green now (after restarting some jobs). Is there still something that needs to be done?

jamadden commented 4 years ago

Awaiting review.

mgedmin commented 4 years ago

I still don't have the energy for reviewing this, sorry!

icemac commented 4 years ago

Same here, sorry, too.

jamadden commented 4 years ago

I found a way to make the diff much smaller and simpler by avoiding the need to rename Persistent to PersistentPy. (use_c_impl updates the globals of the Python functions so that the name the class is defined by is still the name the class bodies see when they execute.) Hopefully that helps.