[TIP] coverage regression on Windows when visual studio not available

Chris Withers chris at simplistix.co.uk
Sat Dec 15 10:58:38 PST 2012


Hi Ned,

On 17/10/2012 07:16, Chris Withers wrote:
> Hi Ned,
>
> With 3.5.2, if the extensions couldn't be compiled on Windows, I got:
>
> Getting distribution for 'coverage>=3.4'.
> no previously-included directories found matching 'test'
> **
> ** Couldn't install with extension module, trying without it...
> ** you can try compiling with MingW32, by passing "-c mingw32" to setup.py.
> **
> no previously-included directories found matching 'test'
> Got coverage 3.5.2.
>
> (eg:
> http://jenkins.simplistix.co.uk/job/checker-buildout/46/PYTHON=2.5,label=windows/console)
>
>
> ...but with 3.5.3, this happens with Python 2.5:
>
> no previously-included directories found matching 'test'
> error: Setup script exited with error: Python was built with Visual
> Studio 2003;
> extensions must be built with a compiler than can generate compatible
> binaries.
> Visual Studio 2003 was not found on this system. If you have Cygwin
> installed,
> you can try compiling with MingW32, by passing "-c mingw32" to setup.py.
> An error occurred when trying to install coverage 3.5.3. Look above this
> message for any errors that were output by easy_install.
> While:
>    Installing py.
>    Getting distribution for 'coverage>=3.4'.
> Error: Couldn't install: coverage 3.5.3
>
> (eg:
> http://jenkins.simplistix.co.uk/job/checker-buildout/50/PYTHON=2.5,label=windows/console)
>
>
> This happens with Python 2.7:
>
> Getting distribution for 'coverage>=3.4'.
> no previously-included directories found matching 'test'
> error: Setup script exited with error: Unable to find vcvarsall.bat
> An error occurred when trying to install coverage 3.5.3. Look above this
> message for any errors that were output by easy_install.
> While:
>    Installing py.
>    Getting distribution for 'coverage>=3.4'.
> Error: Couldn't install: coverage 3.5.3

I can't remember if we ever got anywhere on this. I probably dropped the 
ball :-S

As an update, I did a horrible thing:

https://github.com/Simplistix/testfixtures/commit/45f29750ba03b8c9434397af1f793db5b7933b2b

...to get around this problem here:

http://jenkins.simplistix.co.uk/job/testfixtures-buildout/

I'd love to be using the latest coverage version. What changed in 3.5.3 
that seems to be giving Windows-based build tools (setuptools in this 
case) the idea that installing coverage failed because the C extension 
couldn't be installed?

cheers,

Chris

-- 
Simplistix - Content Management, Batch Processing & Python Consulting
            - http://www.simplistix.co.uk



More information about the testing-in-python mailing list