Closed Bug 543825 Opened 15 years ago Closed 14 years ago

use of __import__ needs to be removed from automation.py

Categories

(Testing :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: jmaher, Assigned: jmaher)

References

Details

Attachments

(2 files, 1 obsolete file)

Attached patch WIP patch, testing now (obsolete) — Splinter Review
remove the use of __import__ from automation.py and move the calls out of the class.
Assignee: nobody → jmaher
remove the use of __import__ from automation.py
Attachment #424850 - Attachment is obsolete: true
Attachment #425061 - Flags: review?(ted.mielczarek)
Comment on attachment 425061 [details] [diff] [review] remove use of __import__ >diff --git a/build/automation.py.in b/build/automation.py.in >--- a/build/automation.py.in >+++ b/build/automation.py.in >@@ -46,16 +46,20 @@ import re > import select > import shutil > import signal > import subprocess > import sys > import threading > import tempfile > >+SCRIPT_DIR = os.path.abspath(os.path.realpath(os.path.dirname(sys.argv[0]))) >+sys.path.insert(0, SCRIPT_DIR) >+import automationutils >+ I think I'd prefer __file__ to sys.argv[0], if that still works. (__file__ will be automation.py instead of runtests.py or whatever argv[0] is.) Looks fine otherwise.
Attachment #425061 - Flags: review?(ted.mielczarek) → review+
updated for bitrot, this passes on try server.
Attachment #432811 - Flags: review+
Landed as changeset d24c14dfea78
Status: NEW → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
Comment on attachment 432811 [details] [diff] [review] remove use of __import__ (1.2) >- self.ctypes.windll.kernel32.GetExitCodeProcess(pHandle, self.ctypes.byref(pExitCode)) >- self.ctypes.windll.kernel32.CloseHandle(pHandle) >+ ctypes.windll.kernel32.GetExitCodeProcess(pHandle, self.ctypes.byref(pExitCode)) Did you miss a self.ctypes here?
it does appear so, good catch.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
That got filed as bug 574912 and fixed there.
Status: REOPENED → RESOLVED
Closed: 15 years ago14 years ago
Resolution: --- → FIXED
Depends on: 574912
Component: Infrastructure → General
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: