Bug 632912 - Review Request: rubygem-robots - Simple robots.txt parser
Review Request: rubygem-robots - Simple robots.txt parser
Status: CLOSED WONTFIX
Product: Fedora
Classification: Fedora
Component: Package Review (Show other bugs)
rawhide
All Linux
low Severity medium
: ---
: ---
Assigned To: Mamoru TASAKA
Fedora Extras Quality Assurance
:
Depends On: 553898 624290 632917
Blocks: 632919
  Show dependency treegraph
 
Reported: 2010-09-11 16:50 EDT by Michal Ambroz
Modified: 2012-04-16 22:13 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-04-16 22:13:08 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
mtasaka: fedora‑review?


Attachments (Terms of Use)

  None (edit)
Description Michal Ambroz 2010-09-11 16:50:18 EDT
SPEC URL: http://rebus.fedorapeople.org/SPECS/rubygem-robots.spec
SRPM URL: http://rebus.fedorapeople.org/SRPMS/rubygem-robots-0.10.0-1.fc13.src.rpm

Description:
A simple Ruby library to parse robots.txt.

Hello,
Please could you review the package whatweb?

Output from rpmlint:
$ rpmlint rubygem-robots-0.10.0-1.fc13.src.rpm rubygem-robots-0.10.0-1.fc13.noarch.rpm
#txt is in the reference to the name of the robots.txt file
rubygem-robots.src: W: spelling-error Summary(en_US) txt -> text, ext, tit
rubygem-robots.src: W: spelling-error %description -l en_US txt -> text, ext, tit
rubygem-robots.noarch: W: spelling-error Summary(en_US) txt -> text, ext, tit
rubygem-robots.noarch: W: spelling-error %description -l en_US txt -> text, ext, tit

#% is part urlencoded name of documentation file 
rubygem-robots.noarch: W: unexpanded-macro /usr/lib/ruby/gems/1.8/doc/robots-0.10.0/ri/Robots/ParsedRobots/allowed%3f-i.yaml %3f
rubygem-robots.noarch: W: unexpanded-macro /usr/lib/ruby/gems/1.8/doc/robots-0.10.0/ri/Robots/timeout%3d-c.yaml %3d
rubygem-robots.noarch: W: unexpanded-macro /usr/lib/ruby/gems/1.8/doc/robots-0.10.0/ri/Robots/allowed%3f-i.yaml %3f

#% test scripts are commonly set with only 644 permission
rubygem-robots.noarch: E: non-executable-script /usr/lib/ruby/gems/1.8/gems/robots-0.10.0/test/test_robots.rb 0644L /usr/bin/env

Koji F13: http://koji.fedoraproject.org/koji/taskinfo?taskID=2462027
Comment 1 Mamoru TASAKA 2010-09-12 14:15:47 EDT
Some notes:

* %define -> %global
  - Now we prefer to use %global instead of %define:
    https://fedoraproject.org/wiki/Packaging/Guidelines#.25global_preferred_over_.25define

* BuildRoot
  - BuildRoot tag is no longer used on Fedora and EPEL6:
    https://fedoraproject.org/wiki/Packaging/Guidelines#BuildRoot_tag

* ruby(abi) Requires
  - Writing "R: ruby(abi) = 1.8" is a must
    https://fedoraproject.org/wiki/Packaging/Ruby#Ruby_Packaging_Guidelines

* Requires
  - R: rubygem(shoulda) is not needed
    - thoughtbot-shoulda (not shoulda) dependency appeas in installed gemspec,
      however this is for development dependency and is not needed on runtime.

* Duplicate %files entry
----------------------------------------------------------------
    58  warning: File listed twice: /usr/lib/ruby/gems/1.8/gems/robots-0.10.0/CHANGELOG
    59  warning: File listed twice: /usr/lib/ruby/gems/1.8/gems/robots-0.10.0/README
----------------------------------------------------------------
  - Please make it sure that all files are listed only once in %files
    entry.
  ! Note
    The %files entry
----------------------------------------------------------------
%files
/some_dir/
----------------------------------------------------------------
    contains the directory /some_dir/ itself and all files/directories/etc
    under /some_dir/ , while
----------------------------------------------------------------
%files
%dir /some_dir/
----------------------------------------------------------------
    contains the directory /some_dir/ only.

* rpmlint issue
----------------------------------------------------------------
rubygem-robots.noarch: E: non-executable-script /usr/lib/ruby/gems/1.8/gems/robots-0.10.0/test/test_robots.rb 0644L /usr/bin/env
----------------------------------------------------------------
  - This script need not have shebang and the shebang should be removed.

* %check
  - As this gem contains test/ directory, please add %check section and execute
    some test program there
    ! Note
      To make "$ rake test" succeed, some modification against Rakefile is
      needed.
Comment 2 Mamoru TASAKA 2010-09-12 14:17:43 EDT
One more comment
* Macros
  - Please use the defined %{geminstdir} macro consistently also
    in %files
Comment 3 Mamoru TASAKA 2010-09-22 13:19:23 EDT
ping?
Comment 4 Michal Ambroz 2010-09-25 15:49:53 EDT
Hello Mamoru,
thank you for review, here is the updated package:
SPEC URL: http://rebus.fedorapeople.org/SPECS/rubygem-robots.spec
SRPM URL:
http://rebus.fedorapeople.org/SRPMS/rubygem-robots-0.10.0-2.fc13.src.rpm

I have tried to implement changes based on your comments. Unfortunately I was not able to implement all the changes you have been asking - mainly:

* BuildRoot
- having this tag is not an error - I would like to keep the package maintained for EPEL5 as well and I would prefer to have 1 spec if possible.

* %check
- some packages needed for test are not available in Fedora yet (shoulda, jeweler), I have included BuildRequire(check) dependencies and check section, but it is now commented out. I will uncomment as soon as the dependencies are available.

Best regards
Michal Ambroz
Comment 5 Mamoru TASAKA 2010-10-03 15:22:36 EDT
Sorry for late response.
Well,

* %check issue
  - rubygem(jeweler) is not strictly needed for $ rake test
  - also rubygem(shoulda) is only for gem.add_development_dependency and
    not needed for $ rake test
  - However Rakefile itself is broken for $ rake test.
    Please consider to apply the following patch and enable $ rake test on %check.
-----------------------------------------------------------------
$ diff -u Rakefile.debug Rakefile
--- Rakefile.debug	1970-01-01 09:00:00.000000000 +0900
+++ Rakefile	2010-09-13 02:32:52.000000000 +0900
@@ -21,7 +21,7 @@
 require 'rake/testtask'
 Rake::TestTask.new(:test) do |test|
   test.libs << 'lib' << 'test'
-  test.pattern = 'test/**/*_test.rb'
+  test.pattern = 'test/**/test_*.rb'
   test.verbose = true
 end
 
@@ -38,7 +38,7 @@
   end
 end
 
-task :test => :check_dependencies
+#task :test => :check_dependencies
 
 task :default => :test
 
-----------------------------------------------------------------

* Creating -doc subpackage
  - For rubygem based rpms, We usually suggest to create -doc subpackages,
    make -doc subpackage have "Requires: %{name} = %{version}-%{release}"
    and move the following files / directories to -doc subpackage.
----------------------------------------------------------------
%{gemdir}/doc/%{gemname}-%{version}
%{geminstdir}/Rakefile
%{geminstdir}/test
----------------------------------------------------------------
Comment 6 Mamoru TASAKA 2010-10-14 14:09:27 EDT
ping?
Comment 7 Mamoru TASAKA 2010-10-29 13:38:10 EDT
ping again?
Comment 8 Mamoru TASAKA 2010-11-05 13:31:44 EDT
Again ping?
Comment 9 Mamoru TASAKA 2010-11-15 11:46:26 EST
ping?
Comment 10 Michal Ambroz 2011-04-11 11:18:07 EDT
Hello Mamoru,
I am sorry - I forgot abuot the package. 
I will incorporate your suggestions.
Comment 11 Michal Ambroz 2011-04-11 19:42:25 EDT
Updated package:

SPEC: http://rebus.fedorapeople.org/SPECS/rubygem-robots.spec
SRPM: http://rebus.fedorapeople.org/SRPMS/rubygem-robots-0.10.0-3.fc14.src.rpm

- added suggested patch
- split doc package
- enabled %check

Best regards
Michal Ambroz
Comment 12 Michal Ambroz 2012-04-16 22:13:08 EDT
Resigning in getting the anemone/robots to Fedora.

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