Foodcritic / foodcritic

Lint tool for Chef cookbooks.
http://foodcritic.io
MIT License
408 stars 153 forks source link

LoadError: cannot load such file -- gherkin/parser #778

Closed Josh5K closed 5 years ago

Josh5K commented 5 years ago

Summary

Gherkin update on September 23rd causes foodcritic run to fail with the following error.

/System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- gherkin/parser (LoadError)
        from /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from /Library/Ruby/Gems/2.3.0/gems/cucumber-core-3.2.0/lib/cucumber/core/gherkin/parser.rb:2:in `<top (required)>'
        from /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
        from /Library/Ruby/Gems/2.3.0/gems/cucumber-core-3.2.0/lib/cucumber/core.rb:3:in `<top (required)>'
        from /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:127:in `require'
        from /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:127:in `rescue in require'
        from /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:40:in `require'
        from /Library/Ruby/Gems/2.3.0/gems/foodcritic-14.1.0/lib/foodcritic.rb:5:in `<top (required)>'
        from /Library/Ruby/Gems/2.3.0/gems/foodcritic-14.1.0/bin/foodcritic:2:in `require_relative'
        from /Library/Ruby/Gems/2.3.0/gems/foodcritic-14.1.0/bin/foodcritic:2:in `<top (required)>'
        from /usr/local/bin/foodcritic:22:in `load'
        from /usr/local/bin/foodcritic:22:in `<main>'

Possible Breaking change

(JavaScript,Java,Ruby) The native parsers are removed. Parsing is done by gherkin-go executables which are bundled with the published libraries. (aslakhellesoy, [jaysonesmith])

Change Log https://github.com/cucumber/cucumber/blob/master/gherkin/CHANGELOG.md

Downgrading to the previous version of Gherkin (5.1.0) from new release (6.0.1) solves the issue.

tas50 commented 5 years ago

We have a pin in master now that I'll be releasing tonight which resolves this. Thanks for the report