diff options
| -rw-r--r-- | apt/package.py | 5 | ||||
| -rw-r--r-- | debian/changelog | 2 |
2 files changed, 6 insertions, 1 deletions
diff --git a/apt/package.py b/apt/package.py index 73f68c87..29eec909 100644 --- a/apt/package.py +++ b/apt/package.py @@ -545,7 +545,10 @@ class Version(object): .. versionadded:: 0.7.10 """ - return iter(self._uris()).next() + try: + return iter(self._uris()).next() + except StopIteration: + return None def fetch_binary(self, destdir='', progress=None): """Fetch the binary version of the package. diff --git a/debian/changelog b/debian/changelog index b193ed71..6d03a2d7 100644 --- a/debian/changelog +++ b/debian/changelog @@ -14,6 +14,8 @@ python-apt (0.8.4) UNRELEASED; urgency=low * python/tag.cc, tests/test_tagfile.py: - add support a filename argument in apt_pkg.TagFile() (in addition to the file object currently supported) + * apt/package.py: + - if there is no Version.uri return None [Julian Andres Klode ] * python/apt_pkgmodule.cc: |
