diff options
Diffstat (limited to '')
-rw-r--r-- | portato/eix/__init__.py | 1 | ||||
-rw-r--r-- | portato/eix/exceptions.py | 2 | ||||
-rw-r--r-- | portato/eix/py_parser.py | 6 |
3 files changed, 4 insertions, 5 deletions
diff --git a/portato/eix/__init__.py b/portato/eix/__init__.py index 8fa1da6..ed86ec5 100644 --- a/portato/eix/__init__.py +++ b/portato/eix/__init__.py @@ -14,7 +14,6 @@ A module to parse the eix-cache files. """ -from __future__ import absolute_import, with_statement __docformat__ = "restructuredtext" from . import parser diff --git a/portato/eix/exceptions.py b/portato/eix/exceptions.py index 1ca05e1..95283ac 100644 --- a/portato/eix/exceptions.py +++ b/portato/eix/exceptions.py @@ -14,7 +14,7 @@ Different exceptions used in the eix module. """ -from __future__ import absolute_import, with_statement + __docformat__ = "restructuredtext" class EixError (Exception): diff --git a/portato/eix/py_parser.py b/portato/eix/py_parser.py index 231c206..a6927a1 100644 --- a/portato/eix/py_parser.py +++ b/portato/eix/py_parser.py @@ -17,7 +17,7 @@ In this module (nearly) all of these types have a corresponding function. For the exact way all the functions work, have a look at the eix format description. """ -from __future__ import absolute_import, with_statement + __docformat__ = "restructuredtext" import os @@ -53,7 +53,7 @@ def _get_bytes (file, length, expect_list = False): s = file.read(length) if len(s) != length: - raise EndOfFileException, file.name + raise EndOfFileException(file.name) if length == 1 and not expect_list: return ord(s) # is faster than unpack and we have a scalar @@ -187,7 +187,7 @@ def string (file, skip = False): s = file.read(nelems) if len(s) != nelems: - raise EndOfFileException, file.name + raise EndOfFileException(file.name) return s |