Closed kcore closed 9 years ago
I hate to ask the obvious question, but have you installed the new google-ads-savon gem from Rubygems?
If so, are you able to successfully make API calls from outside of your rails framework, just using google-adwords-api, google-ads-common, and google-ads-savon?
@mcloonan google-ads-savon being a dependency of ads_common, is installed by default. I even went ahead and specifically mentioned it in my Gemfile. Like i said, if i fire up my rails console, and say require "ads_savon" it works. The api works too.
+1...I got around the issue by reverting everything to v201406, but then needed data only available in v201509
Running rails 4.2.3 on ruby 2.1.5 on either passenger or puma (tried both), with many variants of this in my gemfile: gem 'google-ads-savon', '~> 1.0' gem 'google-ads-common' gem 'google-adwords-api'
Tried with and without ads-savon and ads-common. Adding require 'adwords_api' in a module prevents the app from spinning up (exact error above), whereas removing the require line throws a NameError: uninitialized constant GoogleAdwordsApi::AdwordsApi error.
I'm finally up against this, as I did everything I could in the older API, but now need to push with the newer - would have said something earlier, but I thought it was my ineptitude =]
Since you've confirmed that ads_savon works without your additional framework, I don't think there's much we can do to help here. It must be a configuration issue with your framework, which is not something we can fix within our library.
ads_savon is identical in functionality to the old savon gem we were using before, simply renamed and dependencies updated to avoid compatibility issues with newer versions of savon.
If you are able to figure out what configuration changes you need to make to get this working, please do post here so that we can have some record of it for others who may run into this issue.
We've run into the same issue and actually found the root cause:
The latest version of the gem files uploaded to rubygems.org have a strange umask without read permissions to 'others':
heavy_check_mark: ~/Downloads/google-ads-savon-1.0.0/lib/ads_savon
14:51 $ ls -alh
total 80
drwxr-xr-x 15 foo staff 510B 17 Nov 11:41 .
drwxr-xr-x 4 foo staff 136B 17 Nov 11:41 ..
-rw-r----- 1 foo staff 5.4K 17 Nov 11:41 client.rb
-rw-r----- 1 foo staff 905B 17 Nov 11:41 config.rb
drwxr-xr-x 3 foo staff 102B 17 Nov 11:41 core_ext
-rw-r----- 1 foo staff 104B 17 Nov 11:41 error.rb
drwxr-xr-x 4 foo staff 136B 17 Nov 11:41 hooks
drwxr-xr-x 3 foo staff 102B 17 Nov 11:41 http
-rw-r----- 1 foo staff 905B 17 Nov 11:41 log_message.rb
-rw-r----- 1 foo staff 603B 17 Nov 11:41 logger.rb
-rw-r----- 1 foo staff 2.6K 17 Nov 11:41 model.rb
-rw-r----- 1 foo staff 113B 17 Nov 11:41 null_logger.rb
drwxr-xr-x 8 foo staff 272B 17 Nov 11:41 soap
-rw-r----- 1 foo staff 392B 17 Nov 11:41 soap.rb
-rw-r----- 1 foo staff 93B 17 Nov 11:41 version.rb
This problem is not present if you clone the repository. The fix would involve re-uploading the .gem file to rubygems.org with the fixed permissions.
Makes sense in a production environment where gems are deployed and owned by root but run by a web account. Confirmed that adding go+r in prod "solved" the problem, at least for now.
it works if we clone the git repo. @dterror thanks for fix! @mcloonan can we update .gem file so that others don't face the same issue?
I will look into this today.
I pushed a new version of the ads_savon gem (1.0.1) to RubyGems. Please let me know if this solves the issue.
Works on elastic beanstalk...thanks!
Hello!
Although the ads_savon gem has been updated with this fix, the gem google-ads-common still has the fixed dependency google-ads-savon v 1.0.0 and we are having this issue and can't update to adwords_api gem v 0.17.0. When will the dependencies of google-ads-common be updated?
Thanks!
You can still use google-ads-savon v 1.0.1 with the current version of google-ads-common; just manually install the new one and remove the old one.
The next version of ads-common will update the dependency as well.
I will do so ;)
Thanks!
the latest version of the adwords_api gem (> 0.17.0) which now uses google-ads-savon instead of the standard savon gem doesn't seem to work. We have a standard 3.2.11 rails app with nginx and passenger enabled. The application boots up fine with the webrick server, but the moment we put it behind passenger, it gives the standard passenger error (Web application could not be started).
the normal rails console and everything works fine with ads_savon being available in it and api working fine.
I tried doing
require "ads_savon"
in config/application.rb then the passenger throws the following error:Not able to figure out what the issue is - load sequence of the passenger rack pre_loader... or what?