apt's display of repositories with directories is incomplete

Bug #17066 reported by Christian Reis
10
Affects Status Importance Assigned to Milestone
apt (Ubuntu)
Won't Fix
Low
Unassigned

Bug Description

My sources.list has this:

  deb http://people.ubuntu.com/~daf/packages ./

When I issue an apt-get update, I get this:

  Hit http://people.ubuntu.com ./ Release
  Ign http://people.ubuntu.com ./ Release
  Ign http://people.ubuntu.com ./ Packages
  Hit http://people.ubuntu.com ./ Packages

Where's the ~daf/packages?

I thought it was an issue with the tilde (~) perhaps, but when I have:

  deb http://bazaar.canonical.com/packages/debs/ ./

I still get:

  Hit http://bazaar.canonical.com ./ Release
  Ign http://bazaar.canonical.com ./ Release
  Ign http://bazaar.canonical.com ./ Packages
  Ign http://bazaar.canonical.com ./ Sources
  Hit http://bazaar.canonical.com ./ Packages
  Hit http://bazaar.canonical.com ./ Sources

Additionally, if I have something like:

  deb file:///mondo/packages/ubuntu/warty ./

I get the very confusing

  Ign file: ./ Release.gpg
  Ign file: ./ Release

  Ign file: ./ Packages

This is pretty bad for people.ubuntu.com, in particular, because it's not really
possible to distinguish between the different repositories. Is this hard to fix?

Revision history for this message
Michael Vogt (mvo) wrote :
Revision history for this message
Christian Reis (kiko) wrote :

I don't know what to say, but check out this message:

  W: Couldn't stat source package list http://people.ubuntu.com ./ Packages
(/var/lib/apt/lists/people.ubuntu.com_%7emvo_apt_apt-cache-control_._Packages) -
stat (2 No such file or directory)
  W: You may want to run apt-get update to correct these problems

This is particularly bad on my system, which has about 5 people.ubuntu.com
entries -- it's unobvious which is to blame until I look at %7evmo.

I don't think the actual filenames are very useful, but the full directory used
in the apt sources list should be preserved, as it's the only way I can track
probles back to their source. So for the example I posted, I'd expect:

   deb http://people.ubuntu.com/~daf/packages ./

to generate

  Hit http://people.ubuntu.com/~daf/packages ./ Release
  [...]

and

  deb http://bazaar.canonical.com/packages/debs/ ./

to get me

  Hit http://bazaar.canonical.com/packages/debs ./ Release

In these specific cases the lines would not be longer than 70 chars, and I think
that may hold true for most repositories.

Revision history for this message
Michael Vogt (mvo) wrote :

I agree that this output needs to be improved. I see various options:

1. we show the full path to the archive:
Get:1 http://de.archive.ubuntu.com/ubuntu/ breezy Release.gpg [189B]
Ign http://people.ubuntu.com/~doko/GCC-4.0/i386/ Release.gpg
Hit http://de.archive.ubuntu.com/ubuntu/ breezy Release
Get:2 http://ring.fujixerox.co.jp/archives/linux/debian/debian-ddtp/ sarge
Release.gpg [197B]
[..]

2. Only show the first component of the path:
Get:1 http://de.archive.ubuntu.com/ubuntu breezy Release.gpg [189B]
Ign http://people.ubuntu.com/~doko Release.gpg
Hit http://de.archive.ubuntu.com/ubuntu breezy Release
Get:2 http://ring.fujixerox.co.jp/archives sarge Release.gpg [197B]
[..]

Or use a mixture of the two (show full path if it is not too long etc). If we
use 1) the pathes may become very long. That's why I lean toward going with
solution 2). It's not hard to fix,

For the error, there should always be a the full path displayed, I'll attach a
patch for that.

Revision history for this message
Michael Vogt (mvo) wrote :

Created an attachment (id=2427)
describe a indexfile more verbose (used to report errors better)

deb{Sources,Package}Index::Info() is only used by
deb{Sources,Package}Index::Describe(). This functin is used to display errors
about the IndexFile to the user and to display the cache policy in apt-cache.

Revision history for this message
Christian Reis (kiko) wrote :

Long time no see, but option 2 looks good to me. Why don't you try that post-hardy?

JLR (artirj)
Changed in apt:
status: Confirmed → Invalid
Revision history for this message
Christian Reis (kiko) wrote :

Undoing invalidation done by a halfwit.

Changed in apt:
status: Invalid → Confirmed
Revision history for this message
Nigel Babu (nigelbabu) wrote :

Mvo, thanks for the patch. Do you have plans for this patch? I checked it out and it doesn't apply anymore.

tags: added: patch-needswork
Changed in apt (Ubuntu):
assignee: Michael Vogt (mvo) → nobody
status: Confirmed → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.