Locust: Installing 0.12.1 requires "pipenv lock --pre"

Created on 22 Oct 2019  路  17Comments  路  Source: locustio/locust

The latest release of locustio cannot really be managed using pipenv. It includes a dependency of geventhttpclient-wheels, which has only pre-release versions available.

As such, it is not possible to generate a Pipfile.lock file without using pipenv lock --pre.

Doing this will install pre-release versions of other packages, which is problematic. (In my case, it installed a 5.0dev version of coverage, which uses a different coverage file format).

bug

Most helpful comment

That's unfortunate. I could issue a non pre-release version of the geventhttpclient-wheels package, though I'd prefer not to, since I think it'd be better to follow the same version number as the official geventhttpclient package.

Gevent 1.5 fixes fixes a bug which would cause Locust's Web UI to crash on Python 3.8 (#1154), so I don't think we'd want to downgrade to gevent 1.4 (the latest non pre-release version).

Therefore, I don't see a good fix for this at the moment, except from maybe documenting it.

All 17 comments

(It's possible that this was also present in earlier versions: my last lock file that worked correctly indicated that it worked fine with 0.11.0).

Thanks for reporting this! I'll try to issue a non pre-release version of geventhttoclient-wheels today.

If we pinned the version to the prerelease one, would that solve the problem?

I鈥檓 not sure: I think maybe Pipenv would still complain.

I just tried installing geventhttpclient-wheels using pipenv:

pipenv install geventhttpclient-wheels

Which failed because I didn't use the --pre flag. However the installation succeeded when I ran:

pipenv install geventhttpclient-wheels==1.3.1.dev2

Wouldn't that indicate that it would work if we pinned the version locust's setup.py? I haven't used pipenv much, and not sure how to test it.

I pinned the version in master, and now pipenv install -e git+https://github.com/locustio/locust.git#egg=locustio succeeds, so I'm assuming it fixed it.

I'm not sure this has fixed things. The version of gevent being specified for locust is 1.5a2. This is a pre-release version. When I pipenv install locustio I get the same errors as the original poster.

Same, I get the same errors. @heyman Can you re-open this?

That's unfortunate. I could issue a non pre-release version of the geventhttpclient-wheels package, though I'd prefer not to, since I think it'd be better to follow the same version number as the official geventhttpclient package.

Gevent 1.5 fixes fixes a bug which would cause Locust's Web UI to crash on Python 3.8 (#1154), so I don't think we'd want to downgrade to gevent 1.4 (the latest non pre-release version).

Therefore, I don't see a good fix for this at the moment, except from maybe documenting it.

@heyman You reopened this, but say there is no good solution :) I guess we are stuck waiting for a new release on geventhttpclient? Or should we "solve" the ticket by just documenting it?

@cyberw We currently also pin the gevent version to 1.5a2 (to fix a crash on Python 3.8 (#1154)) which also is a pre-release version, so just releasing a non pre-release version of geventhttpclient-wheels won't resolve it.

I think we should wait with a fix until gevent 1.5 is released. Until then I think it's a good idea to leave this open so that it's more discoverable for people running into the issue.

I encountered the same problem with locustio 0.4.5 version

Could not find a version that matches gevent==1.5a3,>=0.13

The only way i was able to install properly with pipenv is to use :

pipenv install --pre locustio

Hope this helped someone trying to install with pipenv

Also does locustio use grpcio 1.28.0 pre release version too ? as i see grpcio in my piplock file updated from version 1.27.2 to 1.28.0rc3(it's the only one beside gevent that got updated to pre release version

This has affected me too, used workaround thanks @linhnvhicts

@heyman Now that there is a gevent 1.5 release, I guess we could build a non-prerelease eventhttpclient-wheels version?

@cyberw Yes, we could do that. Only problem is that the version numbers in our geventhttpclient-wheels package would diverge from geventhttpclient, but maybe that's okay.

@linhnvhicts
@cyberw

IMO using the pre-release flag is not a good solution, as it will cause ALL dependencies (not just locust deps) in your project to use the lastest pre-release versions, which are often unstable and could cause things to break in unpredictable ways.

You are better of adding a pinned version of geventhttpclient-wheels to your Pipfile as @heyman suggested.

pipenv install geventhttpclient-wheels==1.3.1.dev3

@farridav
Try clearing your pipenv cache and re-locking.
pipenv lock --clear
https://pipenv.pypa.io/en/latest/diagnose/#your-dependencies-could-not-be-resolved

Having said all that...
I haven't had any issues using the latest version of locust in my pipenv managed projects. Pinning geventhttpclient-wheels in setup.py __should__ have fixed that.

Fixed (a while back)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ShaolongHu picture ShaolongHu  路  3Comments

dolohow picture dolohow  路  3Comments

kowalcj0 picture kowalcj0  路  3Comments

wosc picture wosc  路  3Comments

gboorse picture gboorse  路  3Comments