Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportError running make test in newly-cloned repo #65

Open
bhrutledge opened this issue Aug 22, 2016 · 1 comment
Open

ImportError running make test in newly-cloned repo #65

bhrutledge opened this issue Aug 22, 2016 · 1 comment

Comments

@bhrutledge
Copy link
Contributor

I started working on #64, but I immediately hit a wall running the tests before making any changes. I followed the "Hacking" instructions, and started getting errors like ImportError: 'test_factory' module incorrectly imported from '<project_dir>/.tox/py27-django18/lib/python2.7/site-packages/mail_factory/tests'. Expected '<project_dir>/mail_factory/tests'. Is this module globally installed?. This error showed up in all Tox environments for Django 1.6+. For Django 1.4 and 1.5, I didn't get the error, but I get Coverage.py warning: No data was collected.

I posted a Gist of a fresh clone and environment setup, using commands from the Makefile instead of make test to limit the output to py27-django18 and py27-django15. There's also some information about my system in there, but in short, I'm on a MacBook Air running El Capitan, with Python 2.7.12 installed via Homebrew. But, I've had the same results on another MacBook and an Ubuntu VM, both using Python 2.x and 3.x installed via pyenv.

A little Googling suggests that the ImportError might be related to symlinks in virtualenvs, but I haven't dug into it yet. I see the Travis builds are succeeding, so I'm assuming there's something about my environment that's messing things up. Have any other developers encountered this? What development environments are people using? It's worth noting that this is the first time I've attempted hacking on a PyPI package, so I'm not yet familiar with setuptools.

@bhrutledge
Copy link
Contributor Author

I'm having the same issue on a fresh ubuntu:precise Docker container plus apt-get install python-setuptools python-dev build-essential git and easy_install pip==6.0.7 (which is what Travis seems to use).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant