gem 'ruby-prof'
Gem::LoadError: Could not find RubyGem ruby-prof (>= 0)
from <internal:gem_prelude>:186:in `push_gem_version_on_load_path'
from <internal:gem_prelude>:16:in `gem'
from (irb):1
from c:/installs/ruby_trunk_installed/bin/irb.bat:20:in `<main>'
=begin
gem_prelude.rb:push_all_highest_version_gems_on_load_path expects gem
directory names to be "#{GEMNAME}-#{VERSION}", but the native gem
directory name is suffixed by the platform name.
The following patch may help or may not.
diff --git a/gem_prelude.rb b/gem_prelude.rb
index 71f30bd..3be64aa 100644
--- a/gem_prelude.rb
+++ b/gem_prelude.rb
@@ -229,8 +229,12 @@ if defined?(Gem) then
Dir.entries(gems_directory).each do |gem_directory_name|
next if gem_directory_name == "." || gem_directory_name == ".."
next unless gem_name = gem_directory_name[/(.*)-(.*)/, 1]
next unless gem_name = gem_directory_name[/(.*)-(\d+(?:\.\d+)*)(?:-(.*))?/, 1]
new_version = integers_for($2)
if platform = $3
require 'rubygems/platform'
Gem::Platform.match(platform) or next
end
current_version = GemVersions[gem_name]
if !current_version or (current_version <=> new_version) < 0 then
Assigned to changed from Eric Hodel to Evan Phoenix
Hi, Evan
This ticket is about gem_prelude.rb.
Do you think this should be fixed in 1.9.2?
And what do you think about nobu's patch?
Nobu's patch is fine. It's a minor modification of my original patch for this issue. Nobu's patch was reverted from trunk because of the lazy sweep issue, as I recall.
This ticket is about gem_prelude.rb.
Do you think this should be fixed in 1.9.2?
And what do you think about nobu's patch?
Nobu's patch is fine. It's a minor modification of my original patch for this issue. Nobu's patch was reverted from trunk because of the lazy sweep issue, as I recall.
If we can apply the patch to 1.9.2, we should.
Thank you for your quick reply!
Did you get a commit bit? If you did, could you apply it to
trunk and check "make test-rubyspec" and "make check"?
If you see no problem, please commit it to trunk.
If no problem is reported in a few days, I'll backport it to
ruby_1_9_2.
This ticket is about gem_prelude.rb.
Do you think this should be fixed in 1.9.2?
And what do you think about nobu's patch?
Nobu's patch is fine. It's a minor modification of my original patch for this issue. Nobu's patch was reverted from trunk because of the lazy sweep issue, as I recall.
If we can apply the patch to 1.9.2, we should.
Thank you for your quick reply!
No problem!
Did you get a commit bit? If you did, could you apply it to
trunk and check "make test-rubyspec" and "make check"?
If you see no problem, please commit it to trunk.
Yep! I've got a commit bit now, I'll apply to trunk and commit it if it's fine.
If no problem is reported in a few days, I'll backport it to
ruby_1_9_2.
=begin
I've committed a slightly revised version of the patch that nobu and I worked on into trunk. It solves the gem activation issues because it loads all of rubygems to perform any gem activation.
Hopefully we can have this backported to 1.9.2 soon.
This ticket is about gem_prelude.rb.
Do you think this should be fixed in 1.9.2?
And what do you think about nobu's patch?
Nobu's patch is fine. It's a minor modification of my original patch for this issue. Nobu's patch was reverted from trunk because of the lazy sweep issue, as I recall.
If we can apply the patch to 1.9.2, we should.
Thank you for your quick reply!
No problem!
Did you get a commit bit? If you did, could you apply it to
trunk and check "make test-rubyspec" and "make check"?
If you see no problem, please commit it to trunk.
Yep! I've got a commit bit now, I'll apply to trunk and commit it if it's fine.
If no problem is reported in a few days, I'll backport it to
ruby_1_9_2.
=begin
Seems to work now. Since it doesn't pre-load $: with any gem lib paths anymore, probably quite a bit of gem_prelude could now be removed as well.