Bug 587438

Summary: Review Request: rubygem-snmp - A Ruby implementation of SNMP (the Simple Network Management Protocol)
Product: [Fedora] Fedora Reporter: Michael Stahnke <mastahnke>
Component: Package ReviewAssignee: Mamoru TASAKA <mtasaka>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: medium    
Version: rawhideCC: fedora-package-review, mtasaka, notting
Target Milestone: ---Flags: mtasaka: fedora-review+
dennis: fedora-cvs+
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: rubygem-snmp-1.0.3-1.el5 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-06-12 17:39:20 UTC Type: ---
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
patch to fix failed test none

Description Michael Stahnke 2010-04-29 22:05:37 UTC
Spec URL: http://stahnma.fedorapeople.org/reviews/rubygem-snmp.spec
SRPM URL: http://stahnma.fedorapeople.org/reviews/rubygem-snmp-1.0.2-1.src.rpm
Description: 
A Ruby implementation of SNMP (the Simple Network Management Protocol).

Comment 1 Mamoru TASAKA 2010-05-06 17:51:27 UTC
Some notes:

* Unused macro
  - %ruby_sitelib macro doesn't seem to be used anywhere

* License
  - When the license is "the same as Ruby", it means
    "GPLv2 or Ruby" for license tag.

* %doc
  - Please mark document files as %doc properly
    * "README" file should be marked as %doc
    * examples/ test/ directory should also be marked
      as %doc

* Enabling test
  - As this gem contains test/ directory, please add %check
    section and execute some tests (like $ rake test) there.

Comment 2 Michael Stahnke 2010-05-12 01:00:35 UTC
Haven't forgotten about this one.  My F13beta box is currently having a couple issues.

Comment 3 Mamoru TASAKA 2010-05-21 16:47:04 UTC
ping?

Comment 5 Mamoru TASAKA 2010-05-23 19:14:46 UTC
Created attachment 415990 [details]
patch to fix failed test

For -2:

* Virtual provides name for BR
  - As rubygem(foo) virtual provides names are provided, please use
    this style for rubygem related packaged as BR, like
    "BuildRequires: rubygem(rake)".

    ref: (although the following is for perl:)
    https://fedoraproject.org/wiki/Packaging/Perl#Perl_Requires_and_Provides

* Directory ownership issue
  - The directory %geminstdir itself is not owned by any packages.

* Documents
  - Usually I also mark "Rakefile" "setup.rb" as %doc (because these are
    like "makefile"s for autotool system)

* Test failure
  - the attached patch fixes test failure

! Note
  - Currently "rake test" fails in some weird ways like:
-----------------------------------------------------------------
  1) Error:
test_trap_v1(TestManager):
NoMethodError: undefined method `new' for Integer:Class
    ./test/test_manager.rb:135:in `test_trap_v1'

  2) Error:
test_integer_comparable(TestVarBind):
NoMethodError: undefined method `new' for Integer:Class
    ./test/test_varbind.rb:212:in `test_integer_comparable'

-----------------------------------------------------------------
    I guess some namespaces or so are conflicting when multiple
    files are subsequently loaded by rake/rake_test_loader.rb,
    however I have not examined this yet.
    ( As with the attached patch, "for f in test/*.rb ; do .... ; done"
      test way succeeds, so currently I don't think this as a
      blocker )

Comment 6 Michael Stahnke 2010-05-24 15:57:30 UTC
I have fixed the comments unrelated to the test.  I am trying decide if patching simply for tests is a good idea.  In general, I'd rather not carry patches against upstream if I can help it.  I can contact upstream about the tests and see if they can either fix them or explain to me the proper method for running them.  

Very thorough and good review thus far.  I do appreciate it. 

http://stahnma.fedorapeople.org/reviews/rubygem-snmp-1.0.2-3.fc12.src.rpm

Comment 7 Mamoru TASAKA 2010-05-24 18:23:14 UTC
Well, I think that if the provided tests fail, at least
- the cause should be examined (especially the cause is because
  the failed test is badly written or the main program itself
  is broken)
- the fact should be noticed to the upstream that the provided test
  fails

And if patch is available, submitting the patch to the upstream will
be appreciated (by the upstream).

By the way one other thing.
* Consistent macros usage
  - If you want to use %{__sed} style, please use this style everywhere
    if this is available for consistency (like %{__mkdir}, %{__rm},
    %{__mv}).

-----------------------------------------------------------------
     This package (rubygem-snmp) is APPROVED by mtasaka
-----------------------------------------------------------------

Comment 8 Michael Stahnke 2010-05-24 21:48:46 UTC
New Package CVS Request
=======================
Package Name: rubygem-snmp
Short Description: SNMP bindings for Ruby 
Owners: stahnma
Branches: F-12 F-13  EL-5 EL-6
InitialCC:

Comment 9 Michael Stahnke 2010-05-24 21:49:16 UTC
I've contacted upstream about the test failures and fixed the macros usage.  They will be fixed upon import.

Comment 10 Dennis Gilmore 2010-05-25 20:59:55 UTC
CVS Done

Comment 11 Mamoru TASAKA 2010-06-06 16:59:53 UTC
Please import this package into Fedora.

Comment 12 Michael Stahnke 2010-06-08 15:09:44 UTC
I was working on the testing with upstream a bit.  Tests seem to work on Mac OS so I don't think upstream is too interested in fixing.  I will apply patch provided and run tests that way (rather than with Rake).

Comment 13 Fedora Update System 2010-06-11 20:19:15 UTC
rubygem-snmp-1.0.3-1.el5 has been submitted as an update for Fedora EPEL 5.
http://admin.fedoraproject.org/updates/rubygem-snmp-1.0.3-1.el5

Comment 14 Fedora Update System 2010-06-11 20:19:20 UTC
rubygem-snmp-1.0.3-1.fc13 has been submitted as an update for Fedora 13.
http://admin.fedoraproject.org/updates/rubygem-snmp-1.0.3-1.fc13

Comment 15 Fedora Update System 2010-06-11 23:37:42 UTC
rubygem-snmp-1.0.3-1.el5 has been pushed to the Fedora EPEL 5 testing repository.  If problems still persist, please make note of it in this bug report.
 If you want to test the update, you can install it with 
 su -c 'yum --enablerepo=updates-testing update rubygem-snmp'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/rubygem-snmp-1.0.3-1.el5

Comment 16 Mamoru TASAKA 2010-06-12 17:39:20 UTC
Closing.

Comment 17 Fedora Update System 2010-07-01 18:44:04 UTC
rubygem-snmp-1.0.3-1.fc13 has been pushed to the Fedora 13 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 18 Fedora Update System 2010-07-02 19:25:21 UTC
rubygem-snmp-1.0.3-1.el5 has been pushed to the Fedora EPEL 5 stable repository.  If problems still persist, please make note of it in this bug report.