I added this feature to a Rails 4.2.5 app. In development, all worked at first attempt. But in production, gravatar never was returned. I realized explicit require is needed. So, I had to add this line at top of app/presenters/avatar_presenter.rb
require 'net/http'
Found it, why not, in SO: https://stackoverflow.com/questions/42803138/why-rails-app-need-to-require-net-http-after-deploy-to-a-new-server