Skip to content
Discussion options

You must be logged in to vote

Tox does not support shell command substitution (backticks or $(...)) — commands are not run through a shell by default. Tox passes arguments directly to the executable.

Your workaround of writing a requirements file is a valid approach. Alternatively:

  1. Use a shell wrapper: commands_pre = bash -c 'pip install gdal==$(gdal-config --version).*' (and add bash to allowlist_externals)
  2. Use the tox-backtocks plugin which adds backtick substitution support
  3. Use a helper script that resolves the version and installs

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by gaborbernat
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants