Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:seife:Factory
dstat
0001-Use-python3-compatible-way-of-checking-ins...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0001-Use-python3-compatible-way-of-checking-instance-type.patch of Package dstat
From 4afc0e352640bb278755beaab81cb2e935f5f1c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20Br=C3=BCns?= <stefan.bruens@rwth-aachen.de> Date: Tue, 2 Jul 2019 16:28:07 +0200 Subject: [PATCH] Use python3 compatible way of checking instance type Previously, "dstat --output file ..." failed on python3. --- dstat | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dstat b/dstat index 9359965..df37911 100755 --- a/dstat +++ b/dstat @@ -541,12 +541,12 @@ class dstat: line = '' for i, name in enumerate(self.vars): - if isinstance(self.val[name], types.ListType) or isinstance(self.val[name], types.TupleType): + if isinstance(self.val[name], (list, type)): for j, val in enumerate(self.val[name]): line = line + printcsv(val) if j + 1 != len(self.val[name]): line = line + char['sep'] - elif isinstance(self.val[name], types.StringType): + elif isinstance(self.val[name], str): line = line + self.val[name] else: line = line + printcsv(self.val[name]) -- 2.22.0
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor