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

Fixes #15522: zypper_pattern module does not work in python3 #1045

Conversation

Fdall
Copy link
Contributor

@Fdall Fdall commented Aug 20, 2019

@@ -65,7 +65,7 @@ def redirection_is_broken():

def subprocess_Popen(cmd, stdout=None, stderr=None):
if not redirection_is_broken() or (stdout is None and stderr is None) or stdout == subprocess.PIPE or stderr == subprocess.PIPE:
return subprocess.Popen(cmd, stdout=stdout, stderr=stderr)
return subprocess.Popen(cmd, stdout=stdout, stderr=stderr, universal_newlines=True)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is to force subprocess buffer to be text buffer and not bytes buffer

@Fdall Fdall requested a review from amousset August 20, 2019 09:50
@Normation-Quality-Assistant
Copy link
Contributor

OK, merging this PR

@Normation-Quality-Assistant Normation-Quality-Assistant merged commit 1da5a13 into Normation:branches/rudder/5.0 Aug 20, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants