google-maps-services-ruby icon indicating copy to clipboard operation
google-maps-services-ruby copied to clipboard

ArgumentError: tried to create Proc object without a block

Open mike927 opened this issue 3 years ago • 6 comments

Hello, upgraded my app to Ruby 3.0.1 and it looks like hurley-0.2 which is a dependency of your product broke the gem. Getting that error while calling DirectionsApi

2021-04-28T17:21:35.996Z pid=98696 tid=2ifg WARN: ArgumentError: tried to create Proc object without a block
2021-04-28T17:21:35.996Z pid=98696 tid=2ifg WARN: /Users/michal/.rvm/gems/ruby-3.0.1/gems/hurley-0.2/lib/hurley.rb:45:in `new'

Is it a chance somebody could fix it?

mike927 avatar Apr 28 '21 17:04 mike927

I'm getting the same error

mybuddyandrew avatar May 04 '21 19:05 mybuddyandrew

I forked the hurley lib and potentialy fixed the place giving the error. Not sure if it's the correct way, but the google service works again in my project - https://github.com/AkermanisM/hurley

Minimally tested, but maybe it helps somebody.

AkermanisM avatar Aug 09 '21 14:08 AkermanisM

Great job @AkermanisM, your fork of hurley worked in my project as well.

Miloshes avatar Mar 07 '22 13:03 Miloshes

I forked the hurley lib and potentialy fixed the place giving the error. Not sure if it's the correct way, but the google service works again in my project - https://github.com/AkermanisM/hurley

Minimally tested, but maybe it helps somebody.

I'm sorry. I'm a little slow. how did you fork/fix it? I'm having. this same issue and it's driving me nuts

aames-cls avatar Apr 05 '22 23:04 aames-cls

There is button in github interface called Fork, it will create a repository with identical code as the source repo.\

This is the commit where i fixed it https://github.com/AkermanisM/hurley/commit/2f8924c89b0269a71c30e537789c045eedb8fd7d

AkermanisM avatar Apr 06 '22 11:04 AkermanisM

I added

gem 'hurley', :git => "https://github.com/AkermanisM/hurley.git"

to my Gemfile and now everything works like a charm! thanks you're the best :)

aames-cls avatar Apr 06 '22 15:04 aames-cls