Run mlock_report under python3
psutil is only installed under python3 for the 3.5 gate jobs. Call
mlock_report.py with $PYTHON so we support both environments.
Updates to mlock_report.py for python3 compatability
Change-Id: If7926ce6a2996b766c49b010a7f6640ae624f860
diff --git a/tools/mlock_report.py b/tools/mlock_report.py
index 1d23af9..2169cc2 100755
--- a/tools/mlock_report.py
+++ b/tools/mlock_report.py
@@ -8,14 +8,15 @@
import psutil
-SUMMARY_REGEX = re.compile(r".*\s+(?P<locked>[\d]+)\s+KB")
+SUMMARY_REGEX = re.compile(b".*\s+(?P<locked>[\d]+)\s+KB")
def main():
try:
- print _get_report()
+ print(_get_report())
except Exception as e:
- print "Failure listing processes locking memory: %s" % str(e)
+ print("Failure listing processes locking memory: %s" % str(e))
+ raise
def _get_report():