Comments (7)
It would help your cause (resolving this issue) if you provided more information:
- I don't know what "the movement" is, nor do I know whether this is relevant to the topic at hand;
- You're talking about two different virtual environments being involved, which sounds kind of fragile (although I assume you have your reasons);
- I'm familiar with tox as a user but I haven't seen it from the inside and I kind of don't like how it has its own way of setting up "the test environment", so indeed it could turn out to be tricky to solve this, but really it all depends on where and how and why tox is run.
pip-accel aims to be a drop in replacement to pip but it does have different semantics which sometimes makes the "drop in" part problematic :-). Also it requires both the Python pip package and the pip command to be installed (the second part is an implementation detail which I might try to solve).
Long story short: In order to help you with this issue I need a lot more information. If possible, something I can run myself to avoid remote debugging using GitHub messages as a proxy ;-).
from pip-accel.
Fixed up some of the Typos.
The trouble I'm having is installing pip-accel
so that Tox's "install_command" can run it.
here's an example tox.ini
# content of: tox.ini , put in same dir as setup.py
[tox]
install_command = pip-accel install --pre {opts} {packages}
envlist = py26,py27
[testenv]
deps=
pip-accel # not installed before install_command is run (to install pip-accel)
pytest # install pytest in the venvs
commands=py.test # or 'nosetests' or ...
from pip-accel.
Ah, s/movement/moment/. That makes more sense, thank you :-). I think I found something that works, although it's a bit of a (creative) hack.
First create the shell script ~/bin/pip-accel-for-tox
with the following contents (don't forget to make the file executable):
#!/bin/bash
BIN_DIR="$(echo $PATH | tr : '\n' | head -n1)"
export VIRTUAL_ENV="$(dirname "$BIN_DIR")"
if [ ! -x "$VIRTUAL_ENV/bin/pip-accel" ]; then
"$VIRTUAL_ENV/bin/pip" install pip-accel
fi
"$VIRTUAL_ENV/bin/pip-accel" install --pre "$@"
Then add the following install_command
definition to your tox.ini
:
install_command = pip-accel-for-tox {opts} {packages}
Tox will print a warning because the install command is located outside the test environment, but it will still execute the install command and this seems to work fine...
Does this help?
from pip-accel.
You can whitelist that command. This looks very useful.
I'll raise a PR with that bash script in the docs that fixes this issue.
On 8 Jul 2014 20:51, "Peter Odding" [email protected] wrote:
Ah, s/movement/moment/. That makes more sense, thank you :-). I think I
found something that works, although it's a bit of a (creative) hack.First create the shell script ~/bin/pip-accel-for-tox with the following
contents (don't forget to make the file executable):#!/bin/bash
BIN_DIR="$(echo$PATH | tr : '\n' | head -n1)"export VIRTUAL_ENV="$ (dirname "$BIN_DIR")"if [ ! -x "$VIRTUAL_ENV/bin/pip-accel" ]; then
"$VIRTUAL_ENV/bin/pip" install pip-accelfi"$VIRTUAL_ENV/bin/pip-accel" install --pre "$@"Then add the following install_command definition to your tox.ini:
install_command = pip-accel-for-tox {opts} {packages}
Tox will print a warning because the install command is located outside
the test environment, but it will still execute the install command and
this seems to work fine...Does this help?
Reply to this email directly or view it on GitHub
#30 (comment).
from pip-accel.
I'm closing this issue now because there's nothing more for me to do here. I did add a link to this issue in the readme (which is also the homepage on GitHub and PyPI) so that other users can more easily find how to do this.
from pip-accel.
I got the same issue a half year ago.
I fixed it with setting the VIRTUAL_ENV env variable in tox.ini:
[tox]
skipsdist = True
envlist = py34
toxworkdir = {toxinidir}/.tox
[testenv]
# on jenkins we always recreate the whole
# workspace, so tox will be implicitly recreated
recreate = False
whitelist_externals = make
setenv =
VIRTUAL_ENV={toxworkdir}/{envname}
DJANGO_CONFIGURATION=Jenkins
# run the commands in a Makefile target to exit if one command failes
# https://bitbucket.org/hpk42/tox/issue/124/ignore-command-exit-codes
commands = make ci_run_tests
from pip-accel.
tox 1.8+ should now export VIRTUAL_ENV. At least according to https://bitbucket.org/hpk42/tox/issues/152
from pip-accel.
Related Issues (20)
- Doesn't work with pip 7+ HOT 2
- Add option for terse logging. HOT 5
- Windows / Appveyor - same version of cached file - invalidated and built again HOT 5
- is_wheel fails when source_directory is None HOT 6
- Not able to use pip-accel both globally and inside a virtual environment HOT 4
- Support custom pip command HOT 7
- Upgrade to pip 8 HOT 4
- Disabling S3CacheBackend because it failed HOT 2
- pip-accel does not support running as a module HOT 6
- Is there any way to use pip-accel without installing to virtualenv?
- pip-accel is not compatible with `-e` editable installs of packages that use `setuptools_scm` HOT 2
- Why does `pip-accel` make an sdist (?) archive when I `pip-accel install -e .`? HOT 3
- pip-accel doesn't support the newest pip? HOT 4
- Not compatible with alternative install locations, e.g. `--user`? HOT 2
- [need advice] Do not cache development versions
- Failed to install some packages
- pip-accel should honor settings in pip.conf
- Is this project still alive? HOT 2
- Trying to install pip-accel, it insists on downgrading pip to 2.7. How can I get it to respect the current version, 21.1.2
- Not able to use pip-accel
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pip-accel.