Skip to content
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

Remove empty args from argument_list in SubprocessCompiler #590

Merged
merged 2 commits into from
Aug 30, 2016
Merged

Remove empty args from argument_list in SubprocessCompiler #590

merged 2 commits into from
Aug 30, 2016

Conversation

solkaz
Copy link
Contributor

@solkaz solkaz commented Aug 27, 2016

argument_list does not check if the first element is empty, which is problematic because, by default, that is the program that will be executed by subprocess.Popen, so, for example, if the first element in argument_list is an empty string, then a PermissionError will be raised. This came up when working with django-pipeline-browserify, because the first element in the command BrowserifyCompiler passes to execute_command is BROWSERIFY_VARS, which defaults to ''. This commit will filter out empty elements in argument_list to prevent issues like this.

@solkaz solkaz closed this Aug 27, 2016
@solkaz solkaz reopened this Aug 27, 2016
@cyberdelia
Copy link
Member

Could you add a test case?

@solkaz
Copy link
Contributor Author

solkaz commented Aug 29, 2016

Test case added

@cyberdelia
Copy link
Member

Thanks :bowtie:

@frewsxcv
Copy link
Contributor

Is that test failure legit?

@cyberdelia cyberdelia merged commit 1e73c24 into jazzband:master Aug 30, 2016
@solkaz
Copy link
Contributor Author

solkaz commented Aug 30, 2016

Travis CI tests seem to not be consistent, but I can test it out on some other machines.

@cyberdelia
Copy link
Member

It's just that our build were not reliable, I fixed it in master.

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.

3 participants