From 9ff1b964d3b4ccb041eddfda9ad930db736769a1 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Mon, 11 Jun 2012 09:23:45 +0200 Subject: add test for utils.get_release_date_from_release_file and update code for more py3 friendliness --- apt/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'apt/utils.py') diff --git a/apt/utils.py b/apt/utils.py index 49e8bed5..08140258 100644 --- a/apt/utils.py +++ b/apt/utils.py @@ -48,7 +48,7 @@ def get_release_date_from_release_file(path): if not path or not os.path.exists(path): return None tag = apt_pkg.TagFile(open(path)) - section = tag.next() + section = next(tag) if not "Date" in section: return None date = section["Date"] -- cgit v1.2.3