Bug 1021298

Summary: rpmgrill can't find uidgid info in wrong dir
Product: [Fedora] Fedora Reporter: Christopher Meng <i>
Component: rpmgrillAssignee: Ed Santiago <santiago>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: dkholia, santiago
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 0.26-1 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-10-22 19:43:34 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Correct the path none

Description Christopher Meng 2013-10-21 03:04:56 UTC
Created attachment 814385 [details]
Correct the path

Hi!

Today when I wanted to try rpmgrill for fun and found a bug:

[root@fab Desktop]# rpmgrill --help
Usage: rpmgrill [OPTIONS] ARGS [...]

blah blah blah

OPTIONS:

  --list-plugins    list available plugins
  --disable=[LIST]  disable one or more plugins, e.g.: --disable=virus,buildlog

  -v, --verbose  show verbose progress indicators
  -n, --dry-run  make no actual changes

  --help         display this message
  --man          display program man page
  --version      display program name and version

[root@fab Desktop]# rpmgrill --list-plugins
Couldn't require RPM::Grill::Plugin::RpmScripts : rpmgrill: No match for '/usr/share/doc/setup-*/uidgid' at /usr/share/perl5/vendor_perl/RPM/Grill/Plugin/RpmScripts.pm line 122.
Compilation failed in require at (eval 35) line 2.
 at /usr/share/perl5/vendor_perl/Module/Pluggable.pm line 32.
Available rpmgrill plugins, in the order in which they run:

Couldn't require RPM::Grill::Plugin::RpmScripts : Attempt to reload RPM/Grill/Plugin/RpmScripts.pm aborted.

Seems something wrong in the code. I've attached a fix.

Comment 1 Ed Santiago 2013-10-21 12:14:39 UTC
Thanks for reporting this - I still don't understand how this is triggering. Could I ask you for the output of:

   $ ls -ld /usr/share/doc/setup*
   $ rpm -qf /usr/share/doc/setup*/uidgid

Thanks again, and I apologize for the poor way this is handled.

Comment 2 Michael Schwendt 2013-10-21 13:27:07 UTC
See the builds of "setup" in Rawhide or F20:
http://koji.fedoraproject.org/koji/rpminfo?rpmID=4437412


> I still don't understand how this is triggering. 

It's caused by the UnversionedDocdirs change in Fedora 20:
http://fedoraproject.org/wiki/Changes/UnversionedDocdirs

That changes the base package %doc path from

  %{_docdir}/%{name}-%{version}

to:

  %{_docdir}/%{name}

As a result, the wildcard /usr/share/doc/setup-*' doesn't match anymore because of the '-' near its end.

$ ls -ld /usr/share/doc/setup*
drwxr-xr-x. 2 root root 4096 Aug 23 00:48 /usr/share/doc/setup
drwxr-xr-x. 2 root root 4096 Aug 23 01:35 /usr/share/doc/setuptool
$ rpm -qf /usr/share/doc/setup*/uidgid
setup-2.8.71-2.fc20.noarch

Comment 3 Christopher Meng 2013-10-22 14:50:02 UTC
Yes, as Michael said, this is caused by f20 change. Since you only build rpmgrill for rawhide, I think you can sign off this patch.

Comment 4 Ed Santiago 2013-10-22 19:43:34 UTC
Thank you for the explanation and the fix. New 0.26-1 packages built for f19, f20, f21.