diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-05-09 14:05:09 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-05-09 17:32:13 +0100 |
commit | 58304fcce9727fd89564436771356c033ecd22a3 (patch) | |
tree | 88daa489e0e67245dca71a8d1daf783cf5a00308 /lib/toaster/toastermain/management/commands/perf.py | |
parent | b60261bf8ade14aca31238b50c243c01adcabc59 (diff) | |
download | bitbake-58304fcce9727fd89564436771356c033ecd22a3.tar.gz |
bin, toaster: Fix print and exception syntax
This updates the print "" syntax to print() and fixes some exception
handling syntax such that its compatible with python v2 and v3.
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'lib/toaster/toastermain/management/commands/perf.py')
-rw-r--r-- | lib/toaster/toastermain/management/commands/perf.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/toaster/toastermain/management/commands/perf.py b/lib/toaster/toastermain/management/commands/perf.py index 71a48e95d..6b450bbdf 100644 --- a/lib/toaster/toastermain/management/commands/perf.py +++ b/lib/toaster/toastermain/management/commands/perf.py @@ -25,7 +25,7 @@ class Command(BaseCommand): info = self.url_info(full_url) status_code = info[0] load_time = info[1] - print 'Trying \'' + full_url + '\', ' + str(status_code) + ', ' + str(load_time) + print('Trying \'' + full_url + '\', ' + str(status_code) + ', ' + str(load_time)) def get_full_url(self, url_patt, url_root_res): full_url = str(url_patt).split('^')[1].replace('$>', '').replace('(?P<file_path>(?:/[', '/bin/busybox').replace('.*', '') @@ -54,5 +54,5 @@ class Command(BaseCommand): def error(self, *args): for arg in args: - print >>sys.stderr, arg, - print >>sys.stderr + print(arg, end=' ', file=sys.stderr) + print(file=sys.stderr) |