shaper/yelp

syntax error, unexpected ':'

Opened this issue · 3 comments

Basically, out of the box I'm getting this error: (after correctly bundling the gem)

prj $ rake db:migrate
rake aborted!
/Users/jose/.rvm/gems/ruby-1.9.3-p194/gems/yelp-1.0.0/lib/yelp/request.rb:37: syntax error, unexpected ':', expecting keyword_then or ',' or ';' or '\n'
when Yelp::ResponseFormat::PICKLE: params[:output] = 'pickle'

Does anybody know how to fix this problem?

It looks like its seeing the switch case in https://github.com/shaper/yelp/blob/master/lib/yelp/request.rb as a single line, thus expecting a then keyword after when.
Wild guess, have you tried upgrading to later version Ruby 1.9.3?

I had the same problem on both 1.9.3-p125 and 2.0.0-p247

This issue was fixed in commit 226d386, which was merged into master 5 months ago, but no new version of the gem has been pushed to rubygems.org since then. @shaper, any plans to release v1.0.1?