evanphx / benchmark-ips

Provides iteration per second benchmarking for Ruby
MIT License
1.72k stars 97 forks source link

Fix missing `noop_suite` and `job/noop_report` files in v2.9.0 Manifest #115

Closed okeeblow closed 3 years ago

okeeblow commented 3 years ago

Previously: https://github.com/evanphx/benchmark-ips/issues/103 Previously previously: https://github.com/evanphx/benchmark-ips/issues/74 Previously previously previously: https://github.com/evanphx/benchmark-ips/issues/59

Before:

Traceback (most recent call last):
        2: from ./bin/benchmark:7:in `<main>'
        1: from /usr/local/lib/site_ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
/usr/local/lib/site_ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require': cannot load such file -- benchmark/ips (LoadError)
        6: from ./bin/benchmark:7:in `<main>'
        5: from /usr/local/lib/site_ruby/2.7.0/rubygems/core_ext/kernel_require.rb:156:in `require'
        4: from /usr/local/lib/site_ruby/2.7.0/rubygems/core_ext/kernel_require.rb:168:in `rescue in require'
        3: from /usr/local/lib/site_ruby/2.7.0/rubygems/core_ext/kernel_require.rb:168:in `require'
        2: from /home/okeeblow/.gems/gems/benchmark-ips-2.9.0/lib/benchmark/ips.rb:8:in `<top (required)>'
        1: from /usr/local/lib/site_ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
/usr/local/lib/site_ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require': cannot load such file -- benchmark/ips/noop_suite (LoadError)

Fix:

[gst-master] [okeeblow@emi#CHECKING-YOU-OUT] curl -o /home/okeeblow/.gems/gems/benchmark-ips-2.9.0/lib/benchmark/ips/job/noop_report.rb https://raw.githubusercontent.com/evanphx/benchmark-ips/master/lib/benchmark/ips/job/noop_report.rb

After:


Memory stats for requiring mime/types/columnar
Total usable MIME::Types: 2315
Total allocated: 7050872 bytes (103543 objects)
Total retained:  2006910 bytes (22929 objects)

Memory stats for requiring mini_mime
Total allocated: 39004 bytes (324 objects)
Total retained:  8728 bytes (65 objects)

Memory stats for requiring CHECKING-YOU-OUT
Total usable CYO Types: 1467
Total allocated: 18256663 bytes (298015 objects)
Total retained:  484343 bytes (7684 objects)
lfalcao commented 3 years ago

Thanks! I was going to report this... :laughing:

eregon commented 3 years ago

Is there a way to move away from this explicit list in Manifest.txt which seems very error-prone (FWIW, comes from here), or alternative to add a test to check that it's always up-to-date with files under lib/? IIRC this happened for multiple releases (#59, #74, #102).

eregon commented 3 years ago

Maybe we should just remove hoe and use a glob pattern in https://github.com/evanphx/benchmark-ips/blob/dea7eb1df656f40c2455a4d69ede8601ba82bf5f/benchmark-ips.gemspec#L22 ? @nateberkopec What do you think?

Anyway, let's merge this and release 2.9.1 to fix the immediate issue.

ivoanjo commented 3 years ago

We got bitten by this @Datadog as well. Might be worth yanking 2.9.0 as well, since it's never going to work.

ms-ati commented 3 years ago

Is this merged?

ivoanjo commented 3 years ago

Thanks for the speedy fix/release! :)