Package: python3-debian Version: 0.1.39 Severity: normal X-Debbugs-Cc: nthyk...@debian.org
When updating a field using the deb822 repro code, the existing field name casing is discarded and instead overriden by the user-provided casing. This is inconsistent with the way that the current code works, and makes it harder to make minimal changes to the existing file. >>> from debian._deb822_repro.parsing import parse_deb822_file >>> z = parse_deb822_file(["Source: blah", "Standards-version: 3.1.3"]) >>> list(z.iter_parts())[0]['Standards-Version'] = '1.2.3.4' >>> z.convert_to_text() 'Source: blah\nStandards-Version: 1.2.3.4\n' -- System Information: Debian Release: bookworm/sid APT prefers unstable APT policy: (500, 'unstable'), (500, 'testing') Architecture: amd64 (x86_64) Kernel: Linux 5.10.0-8-amd64 (SMP w/2 CPU threads) Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8), LANGUAGE not set Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) LSM: AppArmor: enabled Versions of packages python3-debian depends on: ii python3 3.9.2-3 ii python3-chardet 4.0.0-1 ii python3-six 1.16.0-2 Versions of packages python3-debian recommends: ii python3-apt 2.2.1 Versions of packages python3-debian suggests: ii gpgv 2.2.27-2 -- no debconf information