您的位置:首页 > 其它

subprocess的实例不能pickle

2010-09-19 20:41 381 查看
#!/usr/bin/env python#encoding=utf-8from subprocess import Popen, PIPE, STDOUTcmd = '/home/mlzboy/my/ide/test/time_sleep.py'p = Popen(cmd, shell=False, stdin=PIPE, stdout=PIPE, stderr=STDOUT, close_fds=True)print type(p)import picklepickle.dump(p,open("./p.pickle","wb"))print "done!"
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: