You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Attempting to use pry-coolline with pry 0.13.1 gives: undefined method 'file' for #<Pry::History:0x00007fc0d148a578> (NoMethodError)
Reproduction
Save the following in foo.rb:
require 'bundler/inline'
gemfile do
source 'https://rubygems.org'
gem 'pry', '= 0.13.1'
gem 'pry-coolline'
end
binding.pry
p 42
Running ruby foo.rb gives:
$ ruby /tmp/foo.rb
Traceback (most recent call last):
13: from /tmp/foo.rb:3:in `<main>'
12: from /Users/owen/.rbenv/versions/2.5.5/lib/ruby/site_ruby/2.5.0/bundler/inline.rb:70:in `gemfile'
11: from /Users/owen/.rbenv/versions/2.5.5/lib/ruby/site_ruby/2.5.0/bundler/runtime.rb:65:in `require'
10: from /Users/owen/.rbenv/versions/2.5.5/lib/ruby/site_ruby/2.5.0/bundler/runtime.rb:65:in `each'
9: from /Users/owen/.rbenv/versions/2.5.5/lib/ruby/site_ruby/2.5.0/bundler/runtime.rb:76:in `block in require'
8: from /Users/owen/.rbenv/versions/2.5.5/lib/ruby/site_ruby/2.5.0/bundler/runtime.rb:76:in `each'
7: from /Users/owen/.rbenv/versions/2.5.5/lib/ruby/site_ruby/2.5.0/bundler/runtime.rb:81:in `block (2 levels) in require'
6: from /Users/owen/.rbenv/versions/2.5.5/lib/ruby/site_ruby/2.5.0/bundler/runtime.rb:81:in `require'
5: from /Users/owen/.rbenv/versions/2.5.5/lib/ruby/gems/2.5.0/gems/pry-coolline-0.2.5/lib/pry-coolline.rb:18:in `<top (required)>'
4: from /Users/owen/.rbenv/versions/2.5.5/lib/ruby/gems/2.5.0/gems/pry-coolline-0.2.5/lib/pry-coolline/wrapper.rb:55:in `make_input'
3: from /Users/owen/.rbenv/versions/2.5.5/lib/ruby/gems/2.5.0/gems/pry-coolline-0.2.5/lib/pry-coolline/wrapper.rb:26:in `make_coolline'
2: from /Users/owen/.rbenv/versions/2.5.5/lib/ruby/gems/2.5.0/gems/pry-coolline-0.2.5/lib/pry-coolline/wrapper.rb:26:in `new'
1: from /Users/owen/.rbenv/versions/2.5.5/lib/ruby/gems/2.5.0/gems/coolline-0.5.0/lib/coolline/coolline.rb:138:in `initialize'
/Users/owen/.rbenv/versions/2.5.5/lib/ruby/gems/2.5.0/gems/pry-coolline-0.2.5/lib/pry-coolline/wrapper.rb:35:in `block in make_coolline': undefined method `file' for #<Pry::History:0x00007ff490122528> (NoMethodError)
Did you mean? filter
The text was updated successfully, but these errors were encountered:
I think I have the same issue. Well, I'm trying to use the gem 'spirit_hands', the installation is ok, but when I run 'rails console' this happens... ../.rbenv/versions/2.6.5/lib/ruby/gems/2.6.0/gems/pry-coolline-0.2.5/lib/pry-coolline/wrapper.rb:35:in block in make_coolline': undefined method file' for #<Pry::History:0x00007f59bc6dbc40> Did you mean? filter (NoMethodError)
And I still don't understand why
I find @owst fix to be the correct approach since there's no way around the API change for the file history in the config (while keeping it backwards compatible).
@SamZapata I used his fork on Gemfile before any gems that might require it (such as spirit_hands):
Attempting to use
pry-coolline
withpry 0.13.1
gives:undefined method 'file' for #<Pry::History:0x00007fc0d148a578> (NoMethodError)
Reproduction
Save the following in
foo.rb
:Running
ruby foo.rb
gives:The text was updated successfully, but these errors were encountered: