Good, besides simple text file format is easy to parse and check by command
line tools, if needed.
To my surprise, I have more manually installed packages than automatically
installed ones, so listing manually installed instead of automatically
installed in the file would not give benefit.
There is no performance issue with the file format, the parsing is not
noticeable.
There is a massive design problem in the DepCache having to visit every
dependency in the cache and do marking stuff. This worked fine for tiny
sets, but scales superlinear to package count.
That's a very long
Well, Boolean algebra may have had some influence on that. It is a
common practice. 1 is shorter than yes.
Oh that is sad, because I am not satisfied with the speed of apt-mark.
On the other hand it is good. Another format or data structure may be
more efficient.
--
You received this bug
It's also imaginable that we might change the value from e.g. 1 to yes.
I don't know why it's an integer. In any case, I'd say you can't rely on
that file at all. It might get changed in format, renamed or removed
entirely without any notice.
--
You received this bug notification because you are
Oh, currently missing Auto-Installed field seems to mean the package is
manually installed even if the Package field exists. I suppose I can
rely on that in the future.
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
No such version exists as it would be a bug. An Auto-Installed field !=
1 is still possible if the section includes another field the current
apt version doesn't know about and hence can't reason about. apt itself
does not currently generate such stanzas, but a future version might. Or
other
Julian, BTW can you tell which version of apt was the latest where value
of the Auto-Installed field can be something else than 1 in the file?
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1713219
It's slow because it loads the entire depcache, and checks all
dependencies. This can be avoided by refactoring the code, but it seems
unnecessary. I'd rather add useful features like telling you which
packages become autoremovable garbage after marking something, rather
than refactoring the code
Oh, actually I was already using set substraction in my code, but I was
also checking for 'Auto-Installed: 0'. Maybe that is necessary with some
older version of apt? (There was some bug in my code and that is why it
did not work correctly for some packages.) Sorry for blaming and
confusing.
Well, the script in the description is a bit too simple. In my
application, I was looking for 'Auto-Installed:' field with value 0 to
find manually installed packages, and due to the change in the way the
file is build nowadays I do not find them by the code anymore. Now the
field is pointless. I
Mechanical train signals used to signal if the next section is clear vs.
blocked by another train used to have the arm raised if it was clear and
down if not. That was so that if the mechanic would fail in some way the
arm would fall down and rest in the "blocked" state rather than in a
"clear"
I wonder why didn't you choose to have only manually installed packages
in the file? It would be even smaller file.
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1713219
Title:
'apt-mark showauto'
Yes
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1713219
Title:
'apt-mark showauto' and 'apt show' is slow
To manage notifications about this bug go to:
So the file should only list packages that are installed automatically
or what?
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1713219
Title:
'apt-mark showauto' and 'apt show' is slow
To manage
There is no bug there, this is all working correctly.
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1713219
Title:
'apt-mark showauto' and 'apt show' is slow
To manage notifications about this bug
Maybe so, but the fact is that the file does not contain information
about all packages installed to my system. (apt 2.0.4 (amd64) / Ubuntu
20.04)
$ grep -c '^Package:' /var/lib/apt/extended_states
698
$ dpkg -l | grep ^ii | wc -l
1893
My file contains only records for packages that are
Maybe I should make another bug report about it?
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1713219
Title:
'apt-mark showauto' and 'apt show' is slow
To manage notifications about this bug go
That's simply not true.
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1713219
Title:
'apt-mark showauto' and 'apt show' is slow
To manage notifications about this bug go to:
I just found out information about packages installed from PPAs are not found
in file configured in Dir::State::extended_states, so my script does not work
for them.
Are they found in some other file then?
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is
I'm not going to add a second independent reader to apt just so that
apt-mark runs a bit faster.
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1713219
Title:
'apt-mark showauto' and 'apt show' is
The problem is that the code that reads the state reads it into the
depcache.
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1713219
Title:
'apt-mark showauto' and 'apt show' is slow
To manage
Well, I think it is not a problem, if we do not need depcache here :)
--
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1713219
Title:
'apt-mark showauto' and 'apt show' is slow
To manage
Two problems: (1) depcache opening is slow (2) we don't really need the
depcache here. Anyway, triaged, but low importance.
** Changed in: apt (Ubuntu)
Status: New => Triaged
** Changed in: apt (Ubuntu)
Importance: Undecided => Low
--
You received this bug notification because you
** Summary changed:
- apt-mark showauto is slow
+ 'apt-mark showauto' and 'apt show' is slow
** Description changed:
- $ time apt-mark showmanual >/dev/null
+ $ time apt-mark showauto >/dev/null
- real 0m0.610s
- user 0m0.544s
- sys 0m0.024s
+ real 0m0.587s
+ user 0m0.552s
+ sys
24 matches
Mail list logo