Control: found -1 2.9.14
Control: retitle -1 apt: "apt changelog" does not behave as documented and may 
fail because it tries to fetch an obsolete version

This is currently occurring again with binutils:

Err:1 https://metadata.ftp-master.debian.org binutils 2.43.50.20241126-1 
Changelog
  Changelog unavailable for binutils=2.43.50.20241126-1 (404  Not Found [IP: 
2a04:4e42:6a::644 443])
E: Failed to fetch 
https://metadata.ftp-master.debian.org/changelogs/main/b/binutils/binutils_2.43.50.20241126-1_changelog
  Changelog unavailable for binutils=2.43.50.20241126-1 (404  Not Found [IP: 
2a04:4e42:6a::644 443])

Because old versions for the distribution are systematically removed,
I don't think that it makes sense to try to fetch a fixed version.
Since metadata.ftp-master.debian.org contains <dist>_changelog files,
such a file should be fetched instead (for the default distribution,
use the same as what "apt-get install" does).

Related to this issue, the apt-get(8) man page says

  changelog
    changelog tries to download the changelog of a package and displays
    it through sensible-pager. By default it displays the changelog for
    the version that is installed. However, you can specify the same
    options as for the install command.

First, the "By default it displays the changelog for the version that
is installed." is incorrect: 2.43.1-5 is currently installed on my
machine, not 2.43.50.20241126-1 (the version apt tries to fetch).

BTW, since 2.43.1-5 is currently "testing", the changelog is still
available on metadata.ftp-master.debian.org.

Moreover, the "However, you can specify the same options as for the
install command." is incorrect too. Since the install command supports
the -t option (e.g. -t unstable), this should also be the case for the
changelog command. This seems to work for "testing", but neither for
"unstable" or "stable", e.g.

qaa:~> apt-get changelog -t stable binutils
Err:1 https://metadata.ftp-master.debian.org binutils 2.43.50.20241126-1 
Changelog
  Changelog unavailable for binutils=2.43.50.20241126-1 (404  Not Found [IP: 
2a04:4e42:6a::644 443])
E: Failed to fetch 
https://metadata.ftp-master.debian.org/changelogs/main/b/binutils/binutils_2.43.50.20241126-1_changelog
  Changelog unavailable for binutils=2.43.50.20241126-1 (404  Not Found [IP: 
2a04:4e42:6a::644 443])

while "apt-show-versions -a binutils" says that the stable version
is 2.40-2; so, fetching the 2.43.50.20241126-1 version does not make
sense at all.

-- 
Vincent Lefèvre <vinc...@vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)

Reply via email to