Closed Bug 701195 Opened 13 years ago Closed 12 years ago

run_tests and related modules should not use subshells when avoidable

Categories

(Testing :: Talos, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: BYK, Assigned: BYK)

References

Details

run_tests.py in Talos and other related modules use os.system calls and on some occasions they use os.system("python somescript.py parameters") calls which makes tracing, debugging and developing harder. It also prevents packaging systems like PyInstaller to perform accurately due to unpredictable run-time dependencies.
from 701795

In bcontroller we shell out to start/stop_xperf and etlparser.py. In ffprocess we shell out to run bcontroller.py and head and tail scripts.  At a casual glance, it looks like we can just import these things and call via an API versus shelling out and we should do this when we can.
This goes not just for os.system, but subprocess calls, spawn, etc.  In general, subshells should only be used when there is a reason to be used.  Really, we should have and use an API
Summary: run_tests and related modules should not use os.system calls → run_tests and related modules should not use subshells when avoidable
Assignee: nobody → madbyk
Status: NEW → ASSIGNED
we have redone the xperf stuff and minimized some of our other usages.  Can we close this?
Yep.  I think all of the issues are separately ticketed and/or fixed. If not, particular issues should be separately ticketed.
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.