¡@

Home 

python Programming Glossary: proc2

Python on Windows - how to wait for multiple child processes?

http://stackoverflow.com/questions/100624/python-on-windows-how-to-wait-for-multiple-child-processes

works for me proc1 subprocess.Popen 'python' 'mytest.py' proc2 subprocess.Popen 'python' 'mytest.py' proc1.wait print 1 finished.. 'python' 'mytest.py' proc1.wait print 1 finished proc2.wait print 2 finished The problem is that when proc2 finishes.. proc2.wait print 2 finished The problem is that when proc2 finishes before proc1 the parent process will still wait for..

Why does not the + operator change a list while .append() does?

http://stackoverflow.com/questions/10748158/why-does-not-the-operator-change-a-list-while-append-does

1 2 3 4 list2 1 2 3 4 def proc mylist mylist mylist 6 def proc2 mylist mylist.append 6 # Can you explain the results given by.. to check. print list1 proc list1 print list1 print list2 proc2 list2 print list2 The output is 1 2 3 4 6 1 2 3 4 6 1 2 3 4.. by list1 is not changed. What happens when you call proc2 Everything changes when you call proc2 . At first it is the..

How to get environment from a subprocess in Python

http://stackoverflow.com/questions/1214496/how-to-get-environment-from-a-subprocess-in-python

subprocess.call 'proc1' # this set env. variables for proc2 subprocess.call 'proc2' # this must have env. variables set.. # this set env. variables for proc2 subprocess.call 'proc2' # this must have env. variables set by proc1 to work but the.. and run both programs @echo off call proc1.bat proc2 The script will run and set its environment variables. Both..