Bug 908491 - [rfe] list recent
Summary: [rfe] list recent
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: dnf
Version: 18
Hardware: x86_64
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Panu Matilainen
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard: abrt_hash:407f2aeb597733a68e3e37472c1...
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-02-06 20:36 UTC by "FeRD" (Frank Dana)
Modified: 2013-07-01 01:37 UTC (History)
2 users (show)

Fixed In Version: libsolv-0.3.0-5.git228d412.fc19
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-07-01 01:37:03 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
File: backtrace (1.47 KB, text/plain)
2013-02-06 20:36 UTC, "FeRD" (Frank Dana)
no flags Details
File: core_backtrace (726 bytes, text/plain)
2013-02-06 20:36 UTC, "FeRD" (Frank Dana)
no flags Details
File: environ (1.64 KB, text/plain)
2013-02-06 20:36 UTC, "FeRD" (Frank Dana)
no flags Details
Resurrect "list recent" functionality (1.38 KB, patch)
2013-05-30 10:26 UTC, Panu Matilainen
no flags Details | Diff

Description "FeRD" (Frank Dana) 2013-02-06 20:36:08 UTC
Description of problem:
Occurred when I ran the following:
% sudo dnf -v list recent

...After a bunch of other (successful) dnf commands, including '-v list obsoletes', '-v list extras', '-v check-update', and '-v repolist enabled'.

Version-Release number of selected component:
dnf-0.2.20-1.gitdec970f.fc18

Additional info:
cmdline:        /usr/bin/python /bin/dnf -v list recent
executable:     /bin/dnf
kernel:         3.7.4-204.fc18.x86_64
uid:            0

Truncated backtrace:
__init__.py:1857:doPackageLists:AttributeError: 'YumBaseCli' object has no attribute 'pkgSack'

Traceback (most recent call last):
  File "/bin/dnf", line 35, in <module>
    main.user_main(sys.argv[1:], exit_code=True)
  File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 303, in user_main
    errcode = main(args)
  File "/usr/lib/python2.7/site-packages/dnf/cli/main.py", line 131, in main
    result, resultmsgs = cli.do_commands()
  File "/usr/lib/python2.7/site-packages/dnf/cli/cli.py", line 1478, in do_commands
    return command.doCommand(self.base.basecmd, self.base.extcmds)
  File "/usr/lib/python2.7/site-packages/dnf/cli/commands.py", line 539, in doCommand
    ypl = self.base.returnPkgLists(extcmds, installed_available=highlight)
  File "/usr/lib/python2.7/site-packages/dnf/cli/cli.py", line 696, in returnPkgLists
    ignore_case=True)
  File "/usr/lib/python2.7/site-packages/dnf/yum/__init__.py", line 1857, in doPackageLists
    avail = self.pkgSack.returnNewestByNameArch(patterns=patterns,
AttributeError: 'YumBaseCli' object has no attribute 'pkgSack'

Local variables in innermost frame:
available: []
ignore_case: True
pkgnarrow: 'recent'
showdups: False
self: <dnf.cli.cli.YumBaseCli object at 0x2b75b50>
obsoletesTuples: []
reinstall_available: []
patterns: []
extras: []
ygh: <dnf.yum.misc.GenericHolder instance at 0x2b887e8>
obsoletes: []
installed: []
recentlimit: 1359577910.056804
ic: True
now: 1360182710.056804
old_available: []
updates: []
recent: []

Comment 1 "FeRD" (Frank Dana) 2013-02-06 20:36:11 UTC
Created attachment 694135 [details]
File: backtrace

Comment 2 "FeRD" (Frank Dana) 2013-02-06 20:36:13 UTC
Created attachment 694136 [details]
File: core_backtrace

Comment 3 "FeRD" (Frank Dana) 2013-02-06 20:36:15 UTC
Created attachment 694137 [details]
File: environ

Comment 4 Ales Kozumplik 2013-02-07 07:22:20 UTC
Hello,

Thank you for opening the report. This is in fact not supposed to work at the moment, dnf so far lacks the capability to look into package changelists. This will be added later.

Comment 5 Panu Matilainen 2013-05-30 10:26:42 UTC
Created attachment 754771 [details]
Resurrect "list recent" functionality

(In reply to Ales Kozumplik from comment #4)
> dnf so far lacks the capability to look into package
> changelists. This will be added later.

'yum list recent' doesn't actually look at package changelogs but the physical package mtime from repository ("filetime" in eg repoquery formatting), with a configurable time for just how new packages are considered "recent".

"filetime" isn't currently available through libsolv (and unless there are some other uses for it too, doesn't seem worth adding just because of this) so this just uses what we have now and use package buildtime for determining "recent". Of course it will NOT give identical results to yum, so whether you want it at all... well, up to you :)

Comment 6 Ales Kozumplik 2013-05-30 14:41:01 UTC
Thanks for the patch, Panu, pushed:

https://github.com/akozumpl/dnf/commit/b85ab047a29bdde63f61b1b8f8ad7f898b5d98ea

Assigning this to you, it will get closed after the next DNF build.

Comment 7 Fedora Update System 2013-06-24 13:25:21 UTC
libsolv-0.3.0-5.git228d412.fc19, librepo-0.0.4-2.fc19, hawkey-0.3.14-1.git78b3aa0.fc19, dnf-0.3.8-2.git85524ae.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/libsolv-0.3.0-5.git228d412.fc19,dnf-0.3.8-2.git85524ae.fc19,hawkey-0.3.14-1.git78b3aa0.fc19,librepo-0.0.4-2.fc19

Comment 8 Fedora Update System 2013-06-24 18:49:51 UTC
Package libsolv-0.3.0-5.git228d412.fc19, librepo-0.0.4-2.fc19, hawkey-0.3.14-1.git78b3aa0.fc19, dnf-0.3.8-2.git85524ae.fc19:
* should fix your issue,
* was pushed to the Fedora 19 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing libsolv-0.3.0-5.git228d412.fc19 librepo-0.0.4-2.fc19 hawkey-0.3.14-1.git78b3aa0.fc19 dnf-0.3.8-2.git85524ae.fc19'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2013-11602/libsolv-0.3.0-5.git228d412.fc19,dnf-0.3.8-2.git85524ae.fc19,hawkey-0.3.14-1.git78b3aa0.fc19,librepo-0.0.4-2.fc19
then log in and leave karma (feedback).

Comment 9 Fedora Update System 2013-07-01 01:37:03 UTC
libsolv-0.3.0-5.git228d412.fc19, librepo-0.0.4-2.fc19, hawkey-0.3.14-1.git78b3aa0.fc19, dnf-0.3.8-2.git85524ae.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.