Hudson not able to run python with os.system(cmd) in Win 2003 Server

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Hudson not able to run python with os.system(cmd) in Win 2003 Server

kiangoh
Hi,

I have a python script which is triggered by Hudson, and the script will then call another python script. It has been working well in my Win 2008 Server environment. However, when I set up the same environment in Win 2003, I notice that after the first script been triggered by hudson, the second script never been triggered by the first script. The problem is seen in 2 of my Win 2003 servers. I am using os.system(command) in my code.

Same python versions used in 3 servers: Python 2.3.5 (#62, Feb 8 2005, 16:23:02)
Same Hudson versions used in all 3 servers: Hudson ver. 1.346

I've the simplified version of my python script below. I was hoping somebody might have idea what is missing here.

Thanks,
Kian


test.py
=====
import os
print 'kk testing here in test.py'
os.system('echo echo here')


DOS Output (Expected)
==========
E:\Automation\bin>python test.py
kk testing here in test.py
echo here



Hudson Output from Win2008 Server (Expected)
===============================
Started by user anonymous
[workspace] $ cmd /c call C:\Users\relqc\AppData\Local\Temp\hudson1297633292840159415.bat

D:\Automation\bin\hudson\jobs\test\workspace>D:\Automation\bin\test.py
echo here
kk testing here in test.py


D:\Automation\bin\hudson\jobs\test\workspace>exit 0
Finished: SUCCESS


Hudson Output from Win2003 Server (Unexpected - missing "echo here")
==============================
Started by user gohk
[workspace] $ cmd /c call C:\DOCUME~1\relqc\LOCALS~1\Temp\hudson2087230603324335703.bat

E:\Automation\bin\hudson\jobs\test\workspace>E:\Automation\bin\test.py
kk testing here in test.py

E:\Automation\bin\hudson\jobs\test\workspace>exit 0
Finished: SUCCESS