Skip to content
Permalink
Browse files

framework: Use subprocess.check_output() with a sequence of program a…

…rguments

All subprocess.get*output() should be replaced with either
subprocess.Popen or subprocess.check_output now.

String args were converted to sequences of program arguments.
  • Loading branch information...
bachradsusi committed Jun 21, 2016
1 parent e69378d commit dda55aa50db95a25f0d919c3a0d5871827cdc40f
Showing with 3 additions and 3 deletions.
  1. +3 −3 framework/src/SetroubleshootFixit.py
@@ -14,9 +14,9 @@ def __init__ (self, *p, **k):

@dbus.service.method ("org.fedoraproject.SetroubleshootFixit", in_signature='ss', out_signature='s')
def run_fix(self, local_id, analysis_id):
import commands
command = "sealert -f %s -P %s" % ( local_id, analysis_id)
return commands.getoutput(command)
import subprocess
command = ["sealert", "-f", local_id, "-P", analysis_id]
return subprocess.check_output(command, universal_newlines=True)

if __name__ == "__main__":
mainloop = gobject.MainLoop ()

0 comments on commit dda55aa

Please sign in to comment.
You can’t perform that action at this time.