error using process module Process class

E

Earl Eiland

When executing the following code snippet

import process
....
....
for x in Files:
Command_String = 'C:\Program Files\WinRK\WinRK.exe -create ' +
os.path.join(InputDirectory, os.path.splitext(x)[0]) + ' -set
compression_method ppmz -setg include_paths none -add ' +
os.path.join(InputDirectory, x) + ' -apply -quit'
PROC = process.Process(Command_String)
PROC.wait()

from the command line

C:\Documents and Settings\eeiland\Desktop>Thesis_Programs\Compressor2.py
Test_Da
ta\sliceX12 Test_Output\Test

generates the following error:

Traceback (most recent call last):
File "C:\Documents and
Settings\eeiland\Desktop\Thesis_Programs\Compressor2.py
", line 61, in ?
PROC = process.Process(Command_String)
File "C:\Python24\Lib\site-packages\process.py", line 839, in __init__
self._startOnWindows()
File "C:\Python24\Lib\site-packages\process.py", line 913, in
_startOnWindows
cmd = _whichFirstArg(cmd, self._env)
File "C:\Python24\Lib\site-packages\process.py", line 303, in
_whichFirstArg
import which
ImportError: No module named which
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,470
Messages
2,571,807
Members
48,797
Latest member
PeterSimpson
Top