Skip to content

Call python scripts as argument to virtualenv python command #1559

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 12, 2015

Conversation

agjohnson
Copy link
Contributor

This fixes #994, where the 127 character limit on shebang line lengths was
triggering failures of commands inside virtualenvs that had long names or
long branch names. This PR adds some path environment variable handling to
allow for shorter commands, and makes all python script call wrapped by a
call to the virtual env symlinked python binary.

This depends on the pending pull request #1524, for adding docker
containerization and should be rebased after that PR is merged.

@agjohnson agjohnson added the Status: blocked Issue is blocked on another issue label Aug 12, 2015
This fixes #994, where the 127 character limit on shebang line lengths was
triggering failures of commands inside virtualenvs that had long names or
long branch names. This PR adds some path environment variable handling to
allow for shorter commands, and makes all python script call wrapped by a
call to the virtual env symlinked python binary.
@agjohnson agjohnson force-pushed the build-command-shebang branch from 970521b to 23d2859 Compare August 12, 2015 22:13
@agjohnson agjohnson added PR: ready for review and removed Status: blocked Issue is blocked on another issue labels Aug 12, 2015
@@ -485,6 +485,14 @@ def single_version_symlink_path(self):
#

def venv_bin(self, version=LATEST, bin='python'):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might make sense to just kill the python default here, so that we don't have to pass None everywhere

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd prefer this, yes. I didn't want to have to refactor all of the calls, but searching again it looks like there aren't any calling python this way anyways.

@ericholscher
Copy link
Member

👍 other than the above nit.

@ericholscher
Copy link
Member

🚢

ericholscher added a commit that referenced this pull request Aug 12, 2015
Call python scripts as argument to virtualenv python command
@ericholscher ericholscher merged commit f54d78b into master Aug 12, 2015
@gregmuellegger
Copy link
Contributor

Very concise PR which makes it easy to review. 👍 Good work.

@stsewd stsewd deleted the build-command-shebang branch August 6, 2018 23:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Long project names fail with shell error.
3 participants