undefined method `match?'
caseywatts opened this issue · comments
Casey Watts commented
I just did gem install coltrane
, then tried running the coltrane
cli and I got this error:
/Users/cwatts/.rbenv/versions/2.3.0/lib/ruby/gems/2.3.0/gems/coltrane-1.0.22/lib/core_ext.rb:7:in `underscore': undefined method `match?' for /[A-Z-]|::/:Regexp (NoMethodError)
Did you mean? match
from /Users/cwatts/.rbenv/versions/2.3.0/lib/ruby/gems/2.3.0/gems/coltrane-1.0.22/lib/coltrane/classic_scales.rb:25:in `block in <module:ClassicScales>'
from /Users/cwatts/.rbenv/versions/2.3.0/lib/ruby/gems/2.3.0/gems/coltrane-1.0.22/lib/coltrane/classic_scales.rb:24:in `each'
from /Users/cwatts/.rbenv/versions/2.3.0/lib/ruby/gems/2.3.0/gems/coltrane-1.0.22/lib/coltrane/classic_scales.rb:24:in `<module:ClassicScales>'
from /Users/cwatts/.rbenv/versions/2.3.0/lib/ruby/gems/2.3.0/gems/coltrane-1.0.22/lib/coltrane/classic_scales.rb:5:in `<module:Coltrane>'
from /Users/cwatts/.rbenv/versions/2.3.0/lib/ruby/gems/2.3.0/gems/coltrane-1.0.22/lib/coltrane/classic_scales.rb:3:in `<top (required)>'
from /Users/cwatts/.rbenv/versions/2.3.0/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /Users/cwatts/.rbenv/versions/2.3.0/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /Users/cwatts/.rbenv/versions/2.3.0/lib/ruby/gems/2.3.0/gems/coltrane-1.0.22/lib/coltrane.rb:29:in `<top (required)>'
from /Users/cwatts/.rbenv/versions/2.3.0/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /Users/cwatts/.rbenv/versions/2.3.0/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /Users/cwatts/.rbenv/versions/2.3.0/lib/ruby/gems/2.3.0/gems/coltrane-1.0.22/exe/coltrane:9:in `<top (required)>'
from /Users/cwatts/.rbenv/versions/2.3.0/bin/coltrane:23:in `load'
from /Users/cwatts/.rbenv/versions/2.3.0/bin/coltrane:23:in `<main>'
Pedro Maciel commented
It's because the match?
method doesn't exist on your Ruby version (2.3.0).
Could you update to >=2.4
?
Thanks for reporting tho, I'm gonna try set some minimum ruby version on the gemspec or maybe fix this method so it works with previous ruby versions.
Casey Watts commented
aha that makes sense! Thanks :)
Pedro Maciel commented
👍😄