Re: [Python-Dev] PyCapsule_Import semantics, relative imports, module names etc.

2015-07-26 Thread Nick Coghlan
On 27 July 2015 at 01:21, Larry Hastings la...@hastings.org wrote: PyCapsule_Import() is a simple helper function, a slightly-updated analogue to PyCObject_Import(). It's not particularly sophisticated, and I'm not surprised it's bewildered by complicated scenarios like relative imports in

Re: [Python-Dev] PyCapsule_Import semantics, relative imports, module names etc.

2015-07-26 Thread Larry Hastings
PyCapsule_Import() is a simple helper function, a slightly-updated analogue to PyCObject_Import(). It's not particularly sophisticated, and I'm not surprised it's bewildered by complicated scenarios like relative imports in subpackages. For now all I can recommend is that you not try and torture

[Python-Dev] PyCapsule_Import semantics, relative imports, module names etc.

2015-07-24 Thread John Dennis
While porting several existing CPython extension modules that form a package to be 2.7 and 3.x compatible the existing PyObject_* API was replaced with PyCapsule_*. This introduced some issues the existing CPython docs are silent on. I'd like clarification on a few issues and wish to raise