Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.bugs.dist > #866280 > unrolled thread
| Started by | Simon McVittie <smcv@debian.org> |
|---|---|
| First post | 2017-12-01 10:10 +0100 |
| Last post | 2017-12-01 13:50 +0100 |
| Articles | 3 — 2 participants |
Back to article view | Back to linux.debian.bugs.dist
Bug#883242: aptitude: lists packages from non-Debian origins as "The main Debian archive" Simon McVittie <smcv@debian.org> - 2017-12-01 10:10 +0100
Bug#883242: [Aptitude-devel] Bug#883242: aptitude: lists packages from non-Debian origins as "The main Debian archive" Axel Beckert <abe@debian.org> - 2017-12-01 12:40 +0100
Bug#883242: [Aptitude-devel] Bug#883242: aptitude: lists packages from non-Debian origins as "The main Debian archive" Simon McVittie <smcv@debian.org> - 2017-12-01 13:50 +0100
| From | Simon McVittie <smcv@debian.org> |
|---|---|
| Date | 2017-12-01 10:10 +0100 |
| Subject | Bug#883242: aptitude: lists packages from non-Debian origins as "The main Debian archive" |
| Message-ID | <uRPuy-2oM-25@gated-at.bofh.it> |
Package: aptitude
Version: 0.8.10-1
Severity: normal
Steps to reproduce:
- Have an apt source for
"deb http://repo.steampowered.com/steam/ precise steam"
(plus some way to mark it as trusted)
- Observe how the steam-launcher package offered by that repository is
presented in the TUI
(It has Section: games, is in a component/archive area named steam,
and comes from Origin: Valve Software LLC, Label: Steam)
(Any other archive with similar structure can probably reproduce this,
that's just the first one I thought of)
Expected result:
- The package is presented as though it was in no particular archive
component, because aptitude presumably doesn't know what policies the
origin "Valve Software LLC" uses when marking packages with a Section
and putting them in a component
Actual result:
--\ New Packages (1)
--\ games Games, toys, and fun programs (1)
--\ main The main Debian archive (1)
p steam-launcher <none> 1.0.0.54
I assume this is because aptitude sees the unadorned Section: games
(as opposed to Section: steam/games or similar) and bases its UI on
that.
Compare with how aptitude presents the packages in Section: local/games
generated by game-data-packager, which seems fine:
--\ games Games, toys, and fun programs (77)
--- non-free Programs which are not free software (15)
--\ local (62)
i blakestone-v30-data 54 <none>
(This does not make any particular statement about the status of 'local').
synaptic has (or used to have) some mechanism for recognising Debian
'main' packages when run on Debian, and supported Ubuntu packages (for
some definition, perhaps main or main + restricted) when run on Ubuntu.
Ideally aptitude would behave similarly, perhaps by knowing which Origin
can be (or at least claims to be) the Debian main archive.
I suspect that if aptitude had the requested behaviour, it would have to
present packages that are no longer available via apt (Obsolete and Locally
Created) as having an unknown status, rather than being from
"The main Debian archive". This seems more correct - if I built a package
locally, it might be Free Software (or not) but is certainly not from
"The main Debian archive".
Regards,
smcv
-- Package-specific info:
Terminal: xterm-256color
$DISPLAY is set.
which aptitude: /usr/bin/aptitude
aptitude version information:
aptitude 0.8.10
Compiler: g++ 7.2.0
Compiled against:
apt version 5.0.2
NCurses version 6.0
libsigc++ version: 2.10.0
Gtk+ support disabled.
Qt support disabled.
Current library versions:
NCurses version: ncurses 6.0.20171125
cwidget version: 0.5.17
Apt version: 5.0.2
aptitude linkage:
linux-vdso.so.1 (0x00007ffc1ee90000)
libapt-pkg.so.5.0 => /usr/lib/x86_64-linux-gnu/libapt-pkg.so.5.0 (0x00007f48f4147000)
libncursesw.so.5 => /lib/x86_64-linux-gnu/libncursesw.so.5 (0x00007f48f3f17000)
libtinfo.so.5 => /lib/x86_64-linux-gnu/libtinfo.so.5 (0x00007f48f3ced000)
libsigc-2.0.so.0 => /usr/lib/x86_64-linux-gnu/libsigc-2.0.so.0 (0x00007f48f3ae6000)
libcwidget.so.3 => /usr/lib/x86_64-linux-gnu/libcwidget.so.3 (0x00007f48f37eb000)
libsqlite3.so.0 => /usr/lib/x86_64-linux-gnu/libsqlite3.so.0 (0x00007f48f34e3000)
libboost_iostreams.so.1.62.0 => /usr/lib/x86_64-linux-gnu/libboost_iostreams.so.1.62.0 (0x00007f48f32cb000)
libboost_filesystem.so.1.62.0 => /usr/lib/x86_64-linux-gnu/libboost_filesystem.so.1.62.0 (0x00007f48f30b2000)
libboost_system.so.1.62.0 => /usr/lib/x86_64-linux-gnu/libboost_system.so.1.62.0 (0x00007f48f2eae000)
libxapian.so.30 => /usr/lib/x86_64-linux-gnu/libxapian.so.30 (0x00007f48f2aa3000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f48f2885000)
libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f48f2506000)
libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f48f21f3000)
libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f48f1fdc000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f48f1c39000)
libresolv.so.2 => /lib/x86_64-linux-gnu/libresolv.so.2 (0x00007f48f1a23000)
libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007f48f1809000)
libbz2.so.1.0 => /lib/x86_64-linux-gnu/libbz2.so.1.0 (0x00007f48f15f9000)
liblzma.so.5 => /lib/x86_64-linux-gnu/liblzma.so.5 (0x00007f48f13d3000)
liblz4.so.1 => /usr/lib/x86_64-linux-gnu/liblz4.so.1 (0x00007f48f11c1000)
libudev.so.1 => /lib/x86_64-linux-gnu/libudev.so.1 (0x00007f48f0fa3000)
/lib64/ld-linux-x86-64.so.2 (0x00007f48f4b05000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f48f0d9f000)
librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007f48f0b97000)
libuuid.so.1 => /lib/x86_64-linux-gnu/libuuid.so.1 (0x00007f48f0992000)
-- System Information:
Debian Release: buster/sid
APT prefers unstable-debug
APT policy: (500, 'unstable-debug'), (500, 'unstable'), (500, 'testing'), (500, 'stable'), (1, 'experimental-debug'), (1, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 4.14.0-trunk-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_GB.utf8, LC_CTYPE=en_GB.utf8 (charmap=UTF-8), LANGUAGE=en_GB:en (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages aptitude depends on:
ii aptitude-common 0.8.10-1
ii libapt-pkg5.0 1.6~alpha5
ii libboost-filesystem1.62.0 1.62.0+dfsg-4+b2
ii libboost-iostreams1.62.0 1.62.0+dfsg-4+b2
ii libboost-system1.62.0 1.62.0+dfsg-4+b2
ii libc6 2.25-2
ii libcwidget3v5 0.5.17-6
ii libgcc1 1:7.2.0-16
ii libncursesw5 6.0+20171125-1
ii libsigc++-2.0-0v5 2.10.0-1
ii libsqlite3-0 3.21.0-1
ii libstdc++6 7.2.0-16
ii libtinfo5 6.0+20171125-1
ii libxapian30 1.4.5-1
Versions of packages aptitude recommends:
ii libparse-debianchangelog-perl 1.2.0-12
ii sensible-utils 0.0.11
Versions of packages aptitude suggests:
ii apt-xapian-index 0.49
ii aptitude-doc-en [aptitude-doc] 0.8.10-1
pn debtags <none>
ii tasksel 3.42
-- no debconf information
[toc] | [next] | [standalone]
| From | Axel Beckert <abe@debian.org> |
|---|---|
| Date | 2017-12-01 12:40 +0100 |
| Subject | Bug#883242: [Aptitude-devel] Bug#883242: aptitude: lists packages from non-Debian origins as "The main Debian archive" |
| Message-ID | <uRRPI-3OC-9@gated-at.bofh.it> |
| In reply to | #866280 |
Control: tag -1 + confirmed
Control: severity -1 minor
Hi Simon,
Simon McVittie wrote:
> --\ New Packages (1)
> --\ games Games, toys, and fun programs (1)
> --\ main The main Debian archive (1)
> p steam-launcher <none> 1.0.0.54
The string "The main Debian archive" is a static description string
for archives called "main" and does not handle any kind of "origin".
See
https://anonscm.debian.org/cgit/aptitude/aptitude.git/tree/section-descriptions#n83
for the place where the string comes from.
I can't tell you since when this is the case as this static string
hasn't changed since at least 2005 when the contents from old
Subversion repository has been imported (without history) into
Mercurial.
So this generally happens if some other repo also contains an archive
named "main" or if there is no archive name given[1].
[1] Couldn't find the actual code for that, but it's the case
according to the comment at
https://anonscm.debian.org/cgit/aptitude/aptitude.git/tree/src/pkg_grouppolicy.h#n129
So yes, this should be fixed as it's indeed wrong and confusing.
But it's the case like this since ages (at least nearly two decades)
and nobody bothered(*) until now. Hence downgrading the severity to
"minor". (Feel free to raise the severity again if you disagree with
my reasoning.)
And it's probably neither clear how to fix it (What logic should be
implemented given those static descriptions? Do we need a "main"
description for Debian and for Non-Debian?) nor if it will be trivial
to fix as the current method is dead simple.
(*) I'm actually aware of that shortcoming for years now, but it never
bothered me enough that I even thought about documenting it in a
bug report.
Regards, Axel
--
,''`. | Axel Beckert <abe@debian.org>, https://people.debian.org/~abe/
: :' : | Debian Developer, ftp.ch.debian.org Admin
`. `' | 4096R: 2517 B724 C5F6 CA99 5329 6E61 2FF9 CD59 6126 16B5
`- | 1024D: F067 EA27 26B9 C3FC 1486 202E C09E 1D89 9593 0EDE
[toc] | [prev] | [next] | [standalone]
| From | Simon McVittie <smcv@debian.org> |
|---|---|
| Date | 2017-12-01 13:50 +0100 |
| Subject | Bug#883242: [Aptitude-devel] Bug#883242: aptitude: lists packages from non-Debian origins as "The main Debian archive" |
| Message-ID | <uRSVr-4t3-13@gated-at.bofh.it> |
| In reply to | #866309 |
On Fri, 01 Dec 2017 at 12:35:39 +0100, Axel Beckert wrote:
> Simon McVittie wrote:
> > --\ New Packages (1)
> > --\ games Games, toys, and fun programs (1)
> > --\ main The main Debian archive (1)
> > p steam-launcher <none> 1.0.0.54
>
> The string "The main Debian archive" is a static description string
> for archives called "main"
I assume you mean archive areas (which is what Policy calls the conceptual
division between main, contrib and non-free) or components (which is what
apt calls the data layout that implements that conceptual division).
The component containing steam-launcher is called steam, and its Section
is games, so it can't be coming from an explicit mention of main.
Presumably aptitude is applying this pseudocode:
if '/' in Section:
archive-area, section = Section.split('/')
else:
archive-area = 'main'
section = Section
Debian Policy ยง2.4 does talk about how the Section field should reflect
the archive area, but non-Debian archives aren't bound by Policy.
In practice, I think third-party .deb distributors like Valve and GOG
will probably choose an unadorned Section like 'games' more often than
they choose one that encodes an archive area like 'non-free/games',
even if arguably they should be using 'non-free/games' or 'steam/games'
or similar.
I can see that the information available to aptitude doesn't make this
at all easy, because it can know which apt origin an available package
comes from (it's in the Release file), but cannot in general know which
origin an already-installed package came from (all it knows is the dpkg
metadata, which doesn't include the origin); so it can't know whether
the absence of an archive area prefix in the Section means Debian main,
or Ubuntu main, or some third-party thing that isn't necessarily even
Free Software.
smcv
[toc] | [prev] | [standalone]
Back to top | Article view | linux.debian.bugs.dist
csiph-web