[SciPy-User] Hacking scipy and running the tests
Mon Feb 25 14:17:40 CST 2013
On Mon, Feb 25, 2013 at 8:51 PM, Skipper Seabold <email@example.com>wrote:
> On Mon, Feb 25, 2013 at 2:36 PM, Lars Buitinck <L.J.Buitinck@uva.nl>wrote:
>> Hi all,
>> I've submitted several patches to Scipy so far, am I've hit this
>> problem every time: you can't import Scipy from within the source dir,
>> so you can't run the tests without building and installing. But that
>> takes a long time, and then when you edit a file, you either have to
>> edit it in the installation and not forget to copy it back (without
>> help from Git), or you must rebuild and reinstall.
>> Is there a smarter way to do all this? How do the Scipy core developers
>> do this?
> AFAIK, you don't have to rebuild unless you're editing the C/Cython
> sources. In this case I often use (or make) the existing subpackage
> setup.py to only rebuild what I need.
> If you've built the source in place
> python setup.py build_ext --inplace
In-place build is what I use as well. Plus a second git repo (which pulls
from upstream and my main repo) for multi-python-version testing of PRs and
my own changes with "tox -e py27,py33".
> then you can just edit the python sources and run nosetests in the source
> directory without rebuilding. Alternatively, I think you can use
> python setup.py develop
> which I believe builds in place and adds the source to your python path,
> though I rarely do this.
> I'd be interested to hear if there are better ways.
> SciPy-User mailing list
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the SciPy-User