Bug 971135 - The -d flag is broken for rpm content search
Summary: The -d flag is broken for rpm content search
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Pulp
Classification: Retired
Component: rpm-support
Version: 2.2
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: 2.2.0
Assignee: Nobody
QA Contact: Preethi Thomas
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-06-05 19:00 UTC by Randy Barlow
Modified: 2013-09-10 15:45 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-09-10 15:45:23 UTC


Attachments (Terms of Use)

Description Randy Barlow 2013-06-05 19:00:08 UTC
I created a repository to sync the "zoo" repository[0], I synced it, and then I ran a query to find out the details on the contents of that repository. The CLI encountered a traceback in rendering the results:

$ pulp-admin rpm repo content rpm --repo-id zoo -d
An unexpected error has occurred. More information can be found in the client
log file ~/.pulp/admin.log.

$ tail -n 17 ~/.pulp/admin.log 
2013-06-05 14:55:53,557 - ERROR - Client-side exception occurred
Traceback (most recent call last):
  File "/home/rbarlow/devel/pulp/platform/src/pulp/client/extensions/core.py", line 478, in run
    exit_code = Cli.run(self, args)
  File "/usr/lib/python2.7/site-packages/okaara/cli.py", line 974, in run
    exit_code = command_or_section.execute(self.prompt, remaining_args)
  File "/home/rbarlow/devel/pulp/platform/src/pulp/client/extensions/extensions.py", line 224, in execute
    return self.method(*arg_list, **clean_kwargs)
  File "/home/rbarlow/devel/pulp_rpm/pulp_rpm/src/pulp_rpm/extension/admin/contents.py", line 202, in package_search
    self.run_search([self.type_id], out_func=out_func, **kwargs)
  File "/home/rbarlow/devel/pulp_rpm/pulp_rpm/src/pulp_rpm/extension/admin/contents.py", line 157, in run_search
    out_func(units)
  File "/home/rbarlow/devel/pulp_rpm/pulp_rpm/src/pulp_rpm/extension/admin/contents.py", line 197, in out_func
    map(self._reformat_rpm_provides_requires, document_list)
  File "/home/rbarlow/devel/pulp_rpm/pulp_rpm/src/pulp_rpm/extension/admin/contents.py", line 240, in _reformat_rpm_provides_requires
    related_rpm_list = rpm[reformat_me]
KeyError: 'requires'

[0] http://repos.fedorapeople.org/repos/pulp/pulp/demo_repos/zoo/

Comment 1 Jeremy Cline 2013-06-06 17:45:48 UTC
https://github.com/pulp/pulp_rpm/pull/232

Comment 2 Jeff Ortel 2013-06-11 14:15:57 UTC
build: 2.2.0-0.3.beta

Comment 3 Preethi Thomas 2013-06-12 13:12:02 UTC
verified

[root@hp-dl360g6-01 ~]# rpm -q pulp-server
pulp-server-2.2.0-0.3.beta.fc18.noarch
[root@hp-dl360g6-01 ~]# 

[root@hp-dl360g6-01 ~]#  pulp-admin rpm repo content rpm --repo-id zoo.repo -d |more
Metadata:     
  Arch:         noarch
  Buildhost:    smqe-ws15
  Checksum:     7a831f9f90bf4d21027572cb503d20b702de8e8785b02c0397445c2e481d81b3
  Checksumtype: sha256
  Description:  A dummy package of bear
  Epoch:        0
  Filename:     bear-4.1-1.noarch.rpm
  License:      GPLv2
  Name:         bear
  Provides:     bear = 4.1-1-0
  Release:      1
  Requires:     
  Vendor:       None
  Version:      4.1
Created:      2013-06-07T06:36:39Z
Id:           51b147375f96362572eeb769
Owner Id:     yum_importer
Owner Type:   importer
Repo Id:      zoo.repo
Unit Id:      ec649c7e-d9ff-431a-b4b4-e11a9b28831c
Unit Type Id: rpm
Updated:      2013-06-07T06:36:39Z

Comment 5 Preethi Thomas 2013-09-10 15:45:23 UTC
2.2 released
http://repos.fedorapeople.org/repos/pulp/pulp/stable/2.2/


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