Bug 811053

Summary: Stop using "shell=True" when invoking the subprocess module
Product: [Community] PulpDist Reporter: Nick Coghlan <ncoghlan>
Component: Pulp PluginsAssignee: Nick Coghlan <ncoghlan>
Status: CLOSED NEXTRELEASE QA Contact:
Severity: urgent Docs Contact:
Priority: urgent    
Version: unspecified   
Target Milestone: 0.1.0   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-04-10 06:12:33 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Nick Coghlan 2012-04-10 00:58:08 UTC
To eliminate some early compatibility problems with the rsync invocation, the current subprocess invocation code relies on the system shell to parse the created rsync command line.

The test suite is now sufficiently comprehensive that this workaround should be eliminated - it was an acceptable quick fix to avoid stalling development, but needs to be eliminated before the code can be considered ready for deployment.

Comment 1 Nick Coghlan 2012-04-10 06:12:33 UTC
Fixed for 0.0.11

It turned out some arguments were already being manually quoted, which were then getting quoted *again* by the subprocess module when using "shell=False". This then confused rsync, which refused to run due to unrecognised filtering commands. Removing the manual quoting and relying entirely on the automatic quoting appears to have resolved the problem.