Fail to install python C extension properly in Python 3

Issue #229 on hold
BEN ZID ELGUEBSI Wael
created an issue

Description of problem:

When I try to install my Python C extension manually, it's ok. But when I run

tox -e py33

tox does not install the extension properly: It install an empty package:

(py33) >>> import mypackage.myextension
(py33) >>> dir(mypackage.myextension)
['__doc__', '__initializing__', '__loader__', '__name__', '__package__','__path__']

I expect to have something like:

(py33) >>> import mypackage.myextension
(py33) >>> dir(mypackage.myextension)
['__doc__', '__initializing__', '__loader__', '__name__', '__package__', '__path__', 'Parser']

However, If I run:

$ python3 setup.py test  # (1)

It works well and the strange thing is: If I run now:

$ tox -e py33

It will works well because command (1) created a shared library in the project directory

I have to notice that this works well in Python 2.6 & 2.7 and that my C extension is a submodule of my package

Comments (5)

  1. BEN ZID ELGUEBSI Wael reporter

    I fixed it by forcing tox to run python setup.py test before running tests. But, it seems ugly as a solution. Is there any technical documentation about tox workflow ? I'm interested to contribute on this project ?

  2. Log in to comment