Control: tags -1 + patch Dear Marcus & python-debian co-maintainers,
> > If other tools/libraries are more tolerant, including python-apt, > > would it make sense for python-debian to be more tolerant when using > > the in-built parser? In that case, the two parser implementations > > would be more consistent. > > The problem is that iter_paragraphs is used in situations where that > construct should be a paragraph separator, such as in debian/control. > > https://bugs.debian.org/715558 (and many duplicates) > > Perhaps the internal parser needs a 'strict'ness parameter that controls > this behaviour. I'll look at that next. Some code that: * allows the caller to explicitly say whether whitespace-only lines delimit paragraphs (`whitespace-separates-paragraphs`) * implicitly sets `whitespace-separates-paragraphs=True` if called through generic Deb822.iter_paragraphs (the `debian/control` / wrap-and-sort case; #715558) * implicitly sets `whitespace-separates-paragraphs=False` if called through specific Packages.iter_paragraphs or Sources.iter_paragraphs (the emulating python-apt case; #913274) https://salsa.debian.org/python-debian-team/python-debian/merge_requests/9 Comments and reviews needed! cheers Stuart -- Stuart Prescott http://www.nanonanonano.net/ stu...@nanonanonano.net Debian Developer http://www.debian.org/ stu...@debian.org GPG fingerprint 90E2 D2C1 AD14 6A1B 7EBB 891D BBC1 7EBB 1396 F2F7