Fixes for Py3:
* class Delayed(): file not defined; also an error for pylint -E
* Inconsistent use of tabs and spaces for indentation (in one block)
Signed-off-by: Bernhard Kaindl <bernhard.kaindl@citrix.com>
---
tools/xenmon/xenmon.py | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/tools/xenmon/xenmon.py b/tools/xenmon/xenmon.py
index 175eacd2cb..3a81e43edf 100644
--- a/tools/xenmon/xenmon.py
+++ b/tools/xenmon/xenmon.py
@@ -533,7 +533,7 @@ def show_livestats(cpu):
# simple functions to allow initialization of log files without actually
# physically creating files that are never used; only on the first real
# write does the file get created
-class Delayed(file):
+class Delayed():
def __init__(self, filename, mode):
self.filename = filename
self.saved_mode = mode
@@ -677,8 +677,8 @@ def main():
if os.uname()[0] == "SunOS":
xenbaked_cmd = "/usr/lib/xenbaked"
- stop_cmd = "/usr/bin/pkill -INT -z global xenbaked"
- kill_cmd = "/usr/bin/pkill -KILL -z global xenbaked"
+ stop_cmd = "/usr/bin/pkill -INT -z global xenbaked"
+ kill_cmd = "/usr/bin/pkill -KILL -z global xenbaked"
else:
# assumes that xenbaked is in your path
xenbaked_cmd = "xenbaked"
--
2.34.1
On 02/02/2023 5:13 pm, Bernhard Kaindl wrote: > Fixes for Py3: > * class Delayed(): file not defined; also an error for pylint -E > * Inconsistent use of tabs and spaces for indentation (in one block) > > Signed-off-by: Bernhard Kaindl <bernhard.kaindl@citrix.com> Acked-by: Andrew Cooper <andrew.cooper3@citrix.com> I'll add this to my pending queue while staging is blocked. ~Andrew
On 02/02/2023 5:18 pm, Andrew Cooper wrote: > On 02/02/2023 5:13 pm, Bernhard Kaindl wrote: >> Fixes for Py3: >> * class Delayed(): file not defined; also an error for pylint -E >> * Inconsistent use of tabs and spaces for indentation (in one block) >> >> Signed-off-by: Bernhard Kaindl <bernhard.kaindl@citrix.com> > Acked-by: Andrew Cooper <andrew.cooper3@citrix.com> > > I'll add this to my pending queue while staging is blocked. Actually, on second thoughts. Class DomainInfo and Delayed need to inherit from object for Py2 reasons. Inheriting from file did this previously. I can fix up on commit, if you're happy. ~Andrew
On 02/02/2023 6:34 pm, Andrew Cooper wrote: > On 02/02/2023 5:18 pm, Andrew Cooper wrote: >> On 02/02/2023 5:13 pm, Bernhard Kaindl wrote: >>> Fixes for Py3: >>> * class Delayed(): file not defined; also an error for pylint -E >>> * Inconsistent use of tabs and spaces for indentation (in one block) >>> >>> Signed-off-by: Bernhard Kaindl <bernhard.kaindl@citrix.com> >> Acked-by: Andrew Cooper <andrew.cooper3@citrix.com> >> >> I'll add this to my pending queue while staging is blocked. > Actually, on second thoughts. Class DomainInfo and Delayed need to > inherit from object for Py2 reasons. Inheriting from file did this > previously. > > I can fix up on commit, if you're happy. Yes, thanks! -- cu, Bernhard
© 2016 - 2024 Red Hat, Inc.