summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorErnst Sjostrand <ernst.sjostrand@sonymobile.com>2012-03-08 13:02:21 +0100
committerDavid Pursehouse <david.pursehouse@sonymobile.com>2012-07-24 14:50:13 +0900
commit4545f54ce9fe792125cb16635405adbc741d3d41 (patch)
tree28d5b3178f64d4379746d5d4c764829f3bb74c7c
parentfaa51ba5971785956e4d1248d983cd922d61b0b3 (diff)
downloadpygerrit-4545f54ce9fe792125cb16635405adbc741d3d41.tar.gz
Python cleanup: inherit from object
Classes in Python should always inherit from object these days.
-rwxr-xr-xgerrit_stream.py14
1 files changed, 7 insertions, 7 deletions
diff --git a/gerrit_stream.py b/gerrit_stream.py
index 23e0112..67c891a 100755
--- a/gerrit_stream.py
+++ b/gerrit_stream.py
@@ -22,7 +22,7 @@ class GerritStreamError(Exception):
'''
-class GerritAccount:
+class GerritAccount(object):
''' Representation of the Gerrit user account (name and email address)
described in `json_data`.
Raise GerritStreamError if name or email address field is missing.
@@ -39,7 +39,7 @@ class GerritAccount:
raise GerritStreamError("GerritAccount: %s" % e)
-class GerritChange:
+class GerritChange(object):
''' Representation of the Gerrit change described in `json_data`.
Raise GerritStreamError if any of the required fields is missing.
'''
@@ -57,7 +57,7 @@ class GerritChange:
raise GerritStreamError("GerritChange: %s" % e)
-class GerritPatchset:
+class GerritPatchset(object):
''' Representation of the Gerrit patch set described in `json_data`.
Raise GerritStreamError if any of the required fields is missing.
'''
@@ -72,7 +72,7 @@ class GerritPatchset:
raise GerritStreamError("GerritPatchset: %s" % e)
-class GerritApprovals:
+class GerritApprovals(object):
''' Representation of the Gerrit approvals (verification and code review)
described in `json_data`.
Raise GerritStreamError if a required field is missing or has an
@@ -93,7 +93,7 @@ class GerritApprovals:
raise GerritStreamError("GerritApprovals: %s" % e)
-class GerritRefUpdate:
+class GerritRefUpdate(object):
''' Representation of the Gerrit "ref update" described in `json_data`.
Raise GerritStreamError if any of the required fields is missing.
'''
@@ -108,7 +108,7 @@ class GerritRefUpdate:
raise GerritStreamError("GerritRefUpdate: %s" % e)
-class GerritEvent:
+class GerritEvent(object):
''' Gerrit event base class.
'''
@@ -221,7 +221,7 @@ class GerritRefUpdatedEvent(GerritEvent):
raise GerritStreamError("GerritRefUpdatedEvent: %s" % e)
-class GerritStream:
+class GerritStream(object):
''' Gerrit stream handler.
'''