Locust: Mac install locust by pip in error of gevent

Created on 26 May 2016  ·  6Comments  ·  Source: locustio/locust

My Mac is 10.11.4, and install libevent with brew was OK, but install lucust with commands below are all failed in gevent.

pip install locustio

or

sudo pip install locustio

and the error message, please check below.

Command "/usr/bin/python -u -c "import setuptools, tokenize;__file__='/private/tmp/pip-build-yqcZWg/gevent/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-MKMr18-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/tmp/pip-build-yqcZWg/gevent/

any others I missed to install locust?

thanks.

Most helpful comment

That gevent version lock is causing problems with OSX. I have run locust without any problems with gevent versions 1.1.1 and 1.1X in OSX but maybe that 1.1b4 had some bugs that was causing problems with locust. https://github.com/locustio/locust/pull/335

You can try this before installing locust 0.7.4 CFLAGS='-std=c99' pip install gevent==1.0.1
https://github.com/gevent/gevent/issues/656

All 6 comments

That gevent version lock is causing problems with OSX. I have run locust without any problems with gevent versions 1.1.1 and 1.1X in OSX but maybe that 1.1b4 had some bugs that was causing problems with locust. https://github.com/locustio/locust/pull/335

You can try this before installing locust 0.7.4 CFLAGS='-std=c99' pip install gevent==1.0.1
https://github.com/gevent/gevent/issues/656

@molsky
After the code you provided to install specify gevent version, installed Locust succeeded.
Thanks Molsky.

sudo CFLAGS='-std=c99' pip install gevent==1.0.1

Please help to close this issue.

Re #335: Yes, there was a brief backwards incompatibility introduced with gevent 1.1b4. It was fixed in 1.1b5 and subsequent. We've had other reports that gevent 1.1.1 works fine. Given that the version pin here (1.0.1) breaks on Python >= 2.7.9 due to the SSL changes, plus many other issues like this one, I would recommend installing 1.1.1 instead.

I just realized today that my benchmark jobs totally broke down with locustio 0.7.4 because of the gevent issue with python >= 2.7.9. I do think it is imperative that locustio specifies gevent 1.1.1 in its setup.py.

I've issued a new PyPI release which uses gevent 1.1.1.

centos 7.2 has this issue too

Command "/bin/python -u -c "import setuptools, tokenize;file='/tmp/pip-build-hvdDPL/gevent/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" install --record /tmp/pip-4XdmYt-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-hvdDPL/gevent/

Was this page helpful?
0 / 5 - 0 ratings