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

fix #18 #19

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

fix #18 #19

wants to merge 1 commit into from

Conversation

felschr
Copy link
Contributor

@felschr felschr commented Jan 28, 2019

Fixes error caused by new python 2.7 deprecation warning.

Fixes error caused by new python 2.7 deprecation warning.
@@ -318,7 +318,8 @@ pip3 install -U virtualenv && ${runPy}
this.log(ret.stderr.toString());
this.log(ret.stdout.toString());

var isNotPipWarning = ret.stderr.indexOf('You are using pip version') < 0;
var isNotPipWarning = ret.stderr.indexOf('You are using pip version') < 0 &&
ret.stderr.indexOf('DEPRECATION:') < 0;
if (ret.error || (ret.stderr.length != 0 && isNotPipWarning)) {
this.log('Unhandled error in pip, not deploying to AWS.');
return BbPromise.reject(ret.error)

Choose a reason for hiding this comment

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

One could consider to change the reject message for errors that is not a warning (undefined when from ret.stderr) .
return BbPromise.reject(ret.error || ret.stderr.toString())

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Ah, I briefly searched for how to differentiate errors from warnings in node.js but couldn't find the solution.
I guess it would be even better to not do the rejection for warnings at all?

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.

2 participants