Package: python3-debian Version: 0.1.30 Severity: normal Tags: patch
Hi,Using deb822.PkgRelation with exiv2 (0.26-1) I noticed that it drops the archqual fields.
A simple test case could be: import debian.deb822 as d b = 'python:native' print (d.PkgRelation.str(d.PkgRelation.parse_relations(b))) The fix is quite straight forward: diff --git a/lib/debian/deb822.py b/lib/debian/deb822.py index 7d67b3f..26f4b68 100644 --- a/lib/debian/deb822.py +++ b/lib/debian/deb822.py @@ -1011,6 +1011,8 @@ class PkgRelation(object): def pp_atomic_dep(dep): s = dep['name'] + if dep.get('archqual') is not None: + s += ':%s' % dep['archqual'] if dep.get('version') is not None: s += ' (%s %s)' % dep['version'] if dep.get('arch') is not None: Please consider applying this fix. -- System Information: Debian Release: 9.0 APT prefers stable-debug APT policy: (600, 'stable-debug'), (600, 'proposed-updates'), (600, 'stable'), (500, 'oldstable'), (60, 'testing-debug'), (60, 'testing'), (50, 'unstable-debug'), (50, 'unstable'), (1, 'experimental') Architecture: amd64 (x86_64) Foreign Architectures: i386, armhf Kernel: Linux 4.9.0-2-amd64 (SMP w/4 CPU cores) Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8), LANGUAGE=en_GB:en (charmap=UTF-8) Shell: /bin/sh linked to /bin/bash Init: systemd (via /run/systemd/system) Versions of packages python3-debian depends on: ii python3 3.5.3-1 ii python3-chardet 2.3.0-2 ii python3-six 1.10.0-4 Versions of packages python3-debian recommends: ii python3-apt 1.4.0~beta3 Versions of packages python3-debian suggests: ii gpgv 2.1.18-6 -- no debconf information -- "Anytime you have a fifty-fifty chance of getting something right, there's a 90 percent probability you'll get it wrong." -- The 50-50-90 rule Saludos /\/\ /\ >< `/
commit f928f6857e17efd6c00053f7c585366798efe708 Author: Maximiliano Curia <m...@debian.org> Date: Thu Jul 13 20:16:52 2017 +0200 deb822.PkgRelation.str handle archqual diff --git a/lib/debian/deb822.py b/lib/debian/deb822.py index 7d67b3f..26f4b68 100644 --- a/lib/debian/deb822.py +++ b/lib/debian/deb822.py @@ -1011,6 +1011,8 @@ class PkgRelation(object): def pp_atomic_dep(dep): s = dep['name'] + if dep.get('archqual') is not None: + s += ':%s' % dep['archqual'] if dep.get('version') is not None: s += ' (%s %s)' % dep['version'] if dep.get('arch') is not None:
signature.asc
Description: PGP signature