Python popen2 function rewrite (php-mail-parsing) – Plesk
i try to rewrite popen2 to subprocess.Popen. And I get error. My code: cmd = '/usr/sbin/sendmail -t -i' if len(sys.argv) == 3: cmd += " -f%s" % sys.argv[2] # OLD CODE ======================= #(out, s) = popen2(cmd) #s.write(data) #s.close() # ================================…