Julian, sorry, but python-apt in get_release_filename_for_pkg()
hardcodes the string '_Release' to the path returned by the function
regardless of whether apt has downloaded a _Release or _InRelease file.
Here's a prototype patch I worked up to address that:

diff -Nru python-apt-1.0.1build1/apt/utils.py 
python-apt-1.0.1ubuntu0.1~test2/apt/utils.py
--- python-apt-1.0.1build1/apt/utils.py 2015-10-01 13:12:19.000000000 -0700
+++ python-apt-1.0.1ubuntu0.1~test2/apt/utils.py        2015-10-23 
16:06:36.000000000 -0700
@@ -82,7 +82,9 @@
                     indexfile.describe == m.describe and
                     indexfile.is_trusted):
                 dirname = apt_pkg.config.find_dir("Dir::State::lists")
-                name = (apt_pkg.uri_to_filename(metaindex.uri) +
-                        "dists_%s_Release" % metaindex.dist)
-                return dirname + name
+                for relfile in ['Release', 'InRelease']:
+                    name = (apt_pkg.uri_to_filename(metaindex.uri) +
+                           "dists_%s_%s" % (metaindex.dist, relfile))
+                    if os.path.exists(dirname + name):
+                        return dirname + name
     return None

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1503979

Title:
  ubuntu-support-status throws exeption No date tag found (regression)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/python-apt/+bug/1503979/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to