banister / pry-stack_explorer

MOVED TO https://github.com/pry/pry-stack_explorer
https://github.com/pry/pry-stack_explorer
Other
18 stars 1 forks source link

undefined method 'add_hook' crash on startup #15

Closed aspiers closed 12 years ago

aspiers commented 12 years ago

When I add pry-stack_explorer to my Gemfile, WEBrick crashes on startup:

/home/adam/.rvm/gems/ruby-1.9.3-p0/gems/pry-stack_explorer-0.2.8pre5/lib/pry-stack_explorer.rb:65:in `<top (required)>': undefined method `add_hook' for #<Hash:0xaaa9b64> (NoMethodError)
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/bundler-1.1.rc.7/lib/bundler/runtime.rb:68:in `require'
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/bundler-1.1.rc.7/lib/bundler/runtime.rb:68:in `block (2 levels) in require'
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/bundler-1.1.rc.7/lib/bundler/runtime.rb:66:in `each'
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/bundler-1.1.rc.7/lib/bundler/runtime.rb:66:in `block in require'
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/bundler-1.1.rc.7/lib/bundler/runtime.rb:55:in `each'
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/bundler-1.1.rc.7/lib/bundler/runtime.rb:55:in `require'
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/bundler-1.1.rc.7/lib/bundler.rb:118:in `require'
    from /data/music/RotC/eventbook/config/boot.rb:119:in `load_gems'
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/rails-2.3.14/lib/initializer.rb:164:in `process'
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/rails-2.3.14/lib/initializer.rb:113:in `run'
    from /data/music/RotC/eventbook/config/environment.rb:13:in `<top (required)>'
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:182:in `require'
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:182:in `block in require'
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:547:in `new_constants_in'
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/activesupport-2.3.14/lib/active_support/dependencies.rb:182:in `require'
    from /home/adam/.rvm/gems/ruby-1.9.3-p0/gems/rails-2.3.14/lib/commands/server.rb:84:in `<top (required)>'
    from ./script/server:3:in `require'
    from ./script/server:3:in `<main>'

I'm using pry 0.9.7.4.

banister commented 12 years ago

You should not be using pry-stack_explorer, it is a --pre gem (meaning prerelease) and it is not compatible with the currently released Pry gem.

The only reason i released the --pre gem was to allow easy testing of pry-stack_explorer by other Pry core committers.

In about 1 week's time I will officially release a new version of Pry, which will be compatible with pry-stack_explorer and i will upgrade the stack_explorer version from prerelease to release version at that time.

Where did you hear about stack_explorer? I tweeted about it yesterday but i thought i made it clear in that tweet that it would not be compatible with the current gem.

aspiers commented 12 years ago

I googled for pry ruby show stack and it was the top hit. I didn't see anything in the README.md about it not being usable yet, so I just stuck it in my Gemfile and it happily installed even without me asking for pre-releases. Maybe that's a Bundler bug or feature?

OK ... now here's where life gets weird. Just realised that we were talking on #ruby about an hour ago about a completely different thing (wrapping a method with default parameters). I only go on IRC once in a blue moon - I guess the Ruby world is smaller than I thought. (BTW I figured out the solution in the end...)

banister commented 12 years ago

Ah ok, my bad then. i updated the readme now:) On Jan 6, 2012 1:37 PM, "Adam Spiers" < reply@reply.github.com> wrote:

I googled for pry ruby show stack and it was the top hit. I didn't see anything in the README.md about it not being usable yet, so I just stuck it in my Gemfile and it happily installed even without me asking for pre-releases. Maybe that's a Bundler bug or feature?

OK ... now here's where life gets weird. Just realised that we were talking on #ruby about an hour ago about a completely different thing (wrapping a method with default parameters). I only go on IRC once in a blue moon - I guess the Ruby world is smaller than I thought. (BTW I figured out the solution in the end...)


Reply to this email directly or view it on GitHub:

https://github.com/banister/pry-stack_explorer/issues/15#issuecomment-3379172