[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#1052697: tech-ctte: proposed change to apt-listchanges algorithm needs expert consideration



A bit ago, I wrote:
On 9/26/23 08:33, Simon McVittie wrote:
If we disregard non-standardized files like changelog.Debian.devmapper.gz,
I think we can model changelog entries as being keyed by (source package,
source version) pairs.

Changing apt-listchanges so that it always uses the version number of the source package instead of the current logic which uses the "maximum" version number of all the binary packages in the group would solve the lvm2 / dmsetup problem but wouldn't solve a different problem: binary packages with different changelogs for the same source package version, installed at different times. ...

It occurs to me that there still might be a place for this... It might be a better way to handle the edge case of what to do with a changelog downloaded from the internet when there is no history in the seen database indicating what the user has seen before for that package.

My proposal in that case was to display the entire changelog, but there might be a better answer if we're comfortable assuming that Debian changelogs almost always use the source package's versioning scheme. In particular:

  1. Determine the version number of the source package for the installed version of the binary package being installed.
  2. Parse the downloaded changelog entries.
  3. Check if the parsed entries include both some whose version numbers sort before the version number and some that sort equal or greater than it, to confirm that the version numbering is using the source package's versioning.
  4. If the answer is yes, then just display the changelog entries that sort equal or greater. If the answer is no, i.e., we couldn't find any version numbers that sort equal or greater than the one from the currently installed package's source, then display all the changelog entries.

What do you think?

Thanks,

jik


Reply to: