Improve command-not-found package headers

Bug #1867157 reported by Dimitri John Ledkov on 2020-03-12
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
python-defaults (Ubuntu)
Undecided
Unassigned
python2.7 (Ubuntu)
Undecided
Unassigned
python3-defaults (Ubuntu)
Undecided
Unassigned
python3.8 (Ubuntu)
Undecided
Unassigned

Bug Description

Improve command-not-found package headers

command-not-found uses package metadata, and to improve the UX of the misspelled commands / proposed packages.

python2.7-minimal should gain XB-Cnf-Visible-Pkgname: python2.7

python3.8-minimal should gain XB-Cnf-Visible-Pkgname: python3.8

python2-minimal should gain XB-Cnf-Visible-Pkgname: python2

python3-minimal should gain XB-Cnf-Visible-Pkgname: python3

This will then improve these messages from:

"""
  command 'python2.7' from deb python2.7-minimal (2.7.17-1)
  command 'python3.8' from deb python3.8-minimal (3.8.0-5)
  command 'python2' from deb python2-minimal (2.7.17-2)
  command 'python3' from deb python3-minimal (3.7.5-1ubuntu1)
"""

To

"""
  command 'python2.7' from deb python2.7 (2.7.17-1)
  command 'python3.8' from deb python3.8 (3.8.0-5)
  command 'python2' from deb python2 (2.7.17-2)
  command 'python3' from deb python3 (3.7.5-1ubuntu1)
"""

python3 should drop
XB-Cnf-Extra-Commands: python
XB-Cnf-Priority-Bonus: 5

Such that it stops suggesting that somehow python is available from python3 package, which is a lie.

There is a special case for "python" command hint in command-not-found already, which simply points people to "python3".

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package python3.8 - 3.8.2-1ubuntu1

---------------
python3.8 (3.8.2-1ubuntu1) focal; urgency=medium

  * Add XB-Cnf-Visible-Pkgname header on the python*-minimal package to
    point command-not-found at the full one. LP: #1867157

 -- Dimitri John Ledkov <email address hidden> Fri, 13 Mar 2020 10:14:16 +0000

Changed in python3.8 (Ubuntu):
status: New → Fix Released
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package python2.7 - 2.7.17-1ubuntu6

---------------
python2.7 (2.7.17-1ubuntu6) focal; urgency=medium

  * Add XB-Cnf-Visible-Pkgname header on the python*-minimal package to
    point command-not-found at the full one. LP: #1867157

 -- Dimitri John Ledkov <email address hidden> Fri, 13 Mar 2020 12:42:15 +0000

Changed in python2.7 (Ubuntu):
status: New → Fix Released
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package python-defaults - 2.7.17-2ubuntu4

---------------
python-defaults (2.7.17-2ubuntu4) focal; urgency=medium

  * Correct command-not-found XB-Cnf headers LP: #1867157:
    - Drop Extra-Commands headers, not needed
    - Add XB- to ensure Visible-Pkgname actually is included in the binary
      package heders

 -- Dimitri John Ledkov <email address hidden> Fri, 13 Mar 2020 12:31:23 +0000

Changed in python-defaults (Ubuntu):
status: New → Fix Released
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package python3-defaults - 3.8.2-0ubuntu2

---------------
python3-defaults (3.8.2-0ubuntu2) focal; urgency=medium

  [ Dimitri John Ledkov ]
  * Correct command-not-found XB-Cnf headers LP: #1867157:
    - Drop Extra-Commands headers not needed
    - Add XB- to ensure Visible-Pkgname actually is included in the binary
      package heders

  [ Stuart Prescott ]
  * Use unbuffered IO to pass filenames to py_compile (Closes: #953056)
    LP: #1863414

 -- Dimitri John Ledkov <email address hidden> Fri, 13 Mar 2020 12:20:20 +0000

Changed in python3-defaults (Ubuntu):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers