Trouble with Rails Unicorn Web Server starting on Heroku - ruby-on-rails

I've been trouble-shooting my crashed application on Heroku without success. I'm using:
Ruby 2.1.0
Rails 4.1.6
Unicorn web server
I'm getting an Application Error when I go to my url.
These are the last few lines from heroku logs
2015-03-13T20:44:36.095469+00:00 app[web.1]: from config.ru:1:in `new'
2015-03-13T20:44:36.095481+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.1.0/bin/unicorn:23:in `load'
2015-03-13T20:44:36.095477+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.1.0/gems/unicorn- 4.8.3/lib/unicorn/http_server.rb:764:in `build_app!'
2015-03-13T20:44:36.095483+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.1.0/bin/unicorn:23:in `<main>'
2015-03-13T20:44:36.095470+00:00 app[web.1]: from config.ru:1:in `<main>'
2015-03-13T20:44:36.095471+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.1.0/gems/unicorn-4.8.3/lib/unicorn.rb:48:in `eval'
2015-03-13T20:44:36.095467+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.1.0/gems/rack-1.5.2/lib/rack/builder.rb:55:in `initialize'
2015-03-13T20:44:36.095473+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.1.0/gems/unicorn-4.8.3/lib/unicorn.rb:48:in `block in builder'
2015-03-13T20:44:36.095474+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.1.0/gems/unicorn-4.8.3/lib/unicorn/http_server.rb:764:in `call'
2015-03-13T20:44:36.095479+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.1.0/gems/unicorn-4.8.3/lib/unicorn/http_server.rb:137:in `start'
2015-03-13T20:44:36.095480+00:00 app[web.1]: from /app/vendor/bundle/ruby/2.1.0/gems/unicorn-4.8.3/bin/unicorn:126:in `<top (required)>'
2015-03-13T20:44:36.912915+00:00 heroku[web.1]: Process exited with status 1
2015-03-13T20:44:37.040788+00:00 heroku[web.1]: State changed from starting to crashed
2015-03-13T20:45:09.859594+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=stand-as-witnesses-staging.herokuapp.com request_id=2228b811-6b37-482e-a1ec-630699947581 fwd="71.232.132.204" dyno= connect= service= status=503 bytes=
Heroku ps gives:
=== web (1X): `bundle exec unicorn -p $PORT -c ./config/unicorn.rb`
web.1: crashed 2015/03/13 16:44:37 (~ 19m ago)
I upgraded from Ruby 2.0.0 to 2.1.0 and from Unicorn 4.6.3 to 4.8.3 to see if that would solve the problem, but no help there.
My Procfile and app/config/unicorn.rb files are standard based on Heroku's instructions for using unicorn.
Since the app runs fine locally, can anyone point out why I'm getting this crash?
Thanks!

Seems like you should specify model class instead (as I understand this is BlockedSite) of controller in your app/admin/blocked_site.rb AA file. This should fix error:
superclass mismatch for class BlockedSitesController (TypeError)

Thanks for pointing me in the right direction. It turns out that the problem was that we had an existing file in app/controllers/admin/blocked_sites_controller.rb. When I removed that file and a couple of others in that same location, the crashes went away and I was able to navigate to my pages.

Related

How to fix "Client Request Interrupted" error in Heroku (with a rails app)?

I deployed my rails app on Heroku.
When I try to create a new profile, my app crashes. My logs display a Client Request Interrupted error. You can see my logs below.
I searched this error on heroku dev center: https://devcenter.heroku.com/changelog-items/662
On this page (https://devcenter.heroku.com/changelog-items/662):
It said : "This error will be logged if the client socket was closed either in the middle of the request or before a response could be returned."
Then
"This error condition caused an H18 to be logged and the sock field could be used to differentiate between what are now H18 and H27 errors. "
H18 - Server Request Interrupted
The backend socket, belonging to your app’s web process was closed before the backend returned an HTTP response.
2019-02-05T15:53:19.905345+00:00 app[web.1]: bundler: failed to load command: puma (/app/vendor/bundle/ruby/2.5.0/bin/puma)
2019-02-05T15:53:19.905399+00:00 app[web.1]: SignalException: SIGTERM
2019-02-05T15:53:19.905401+00:00 app[web.1]: /app/vendor/bundle/ruby/2.5.0/gems/puma-3.12.0/lib/puma/launcher.rb:398:in `block in setup_signals'
2019-02-05T15:53:19.905406+00:00 app[web.1]: /app/vendor/bundle/ruby/2.5.0/gems/puma-3.12.0/lib/puma/single.rb:115:in `join'
2019-02-05T15:53:19.905407+00:00 app[web.1]: /app/vendor/bundle/ruby/2.5.0/gems/puma-3.12.0/lib/puma/single.rb:115:in `run'
2019-02-05T15:53:19.905409+00:00 app[web.1]: /app/vendor/bundle/ruby/2.5.0/gems/puma-3.12.0/lib/puma/launcher.rb:184:in `run'
2019-02-05T15:53:19.905410+00:00 app[web.1]: /app/vendor/bundle/ruby/2.5.0/gems/puma-3.12.0/lib/puma/cli.rb:78:in `run'
2019-02-05T15:53:19.905412+00:00 app[web.1]: /app/vendor/bundle/ruby/2.5.0/gems/puma-3.12.0/bin/puma:10:in `<top (required)>'
2019-02-05T15:53:19.905414+00:00 app[web.1]: /app/vendor/bundle/ruby/2.5.0/bin/puma:23:in `load'
2019-02-05T15:53:19.905415+00:00 app[web.1]: /app/vendor/bundle/ruby/2.5.0/bin/puma:23:in `<top (required)>'
2019-02-05T21:33:39.526627+00:00 heroku[web.1]: Unidling
2019-02-05T21:33:53.579585+00:00 app[web.1]: Puma starting in single mode...
2019-02-05T21:33:53.579631+00:00 app[web.1]: * Version 3.12.0 (ruby 2.5.3-p105), codename: Llamas in Pajamas
2019-02-05T21:33:53.579632+00:00 app[web.1]: * Min threads: 5, max threads: 5
2019-02-05T21:33:53.579634+00:00 app[web.1]: * Environment: production
2019-02-05T21:34:00.063370+00:00 heroku[web.1]: State changed from starting to up
2019-02-05T21:33:59.640588+00:00 app[web.1]: * Listening on tcp://0.0.0.0:11397
2019-02-05T21:33:59.642173+00:00 app[web.1]: Use Ctrl-C to stop
2019-02-05T21:34:02.204235+00:00 heroku[router]: sock=client at=warning code=H27 desc="Client Request Interrupted" method=GET path="/" host=agora-challenge.herokuapp.com request_id=9d994b8b-eff4-4088-b2be-a42b14fec708 fwd="209.17.96.226" dyno=web.1 connect=1ms service=119ms status=499 bytes= protocol=https
The important part to notice is the sock=client which means that the request was interrupted at the request of the client:
2019-02-05T21:34:02.204235+00:00 heroku[router]: sock=client at=warning code=H27 desc="Client Request Interrupted" method=GET path="/" host=agora-challenge.herokuapp.com request_id=9d994b8b-eff4-4088-b2be-a42b14fec708 fwd="209.17.96.226" dyno=web.1 connect=1ms service=119ms status=499 bytes= protocol=https
I didn't understand either Heroku dev center explanations nor previous Stack Overflow questions.
Thanks a lot for your answers.

not getting what heroku logs are saying

I have deployed app on Heroku but app is not working( I got this message on browser "We're sorry, but something went wrong. If you are the application owner check the logs for more information.") when I checked log I found below message.Can anyone tell me what is the meaning of it?
Stopping all processes with SIGTERM
2018-01-20T10:54:29.710117+00:00 app[web.1]: - Gracefully stopping, waiting for requests to finish
2018-01-20T10:54:29.710722+00:00 app[web.1]: === puma shutdown: 2018-01-20 10:54:29 +0000 ===
2018-01-20T10:54:29.710724+00:00 app[web.1]: - Goodbye!
2018-01-20T10:54:29.710881+00:00 app[web.1]: Exiting
2018-01-20T10:54:29.837650+00:00 heroku[web.1]: Process exited with status 143
2018-01-20T10:54:39.660402+00:00 heroku[web.1]: Starting process with command `bin/rails server -p 38017 -e production`
2018-01-20T10:54:45.686497+00:00 app[web.1]: DEPRECATION WARNING: `config.serve_static_files` is deprecated and will be removed in Rails 5.1.
2018-01-20T10:54:45.686528+00:00 app[web.1]: Please use `config.public_file_server.enabled = true` instead.
2018-01-20T10:54:45.686586+00:00 app[web.1]: (called from block in <top (required)> at /app/config/environments/production.rb:6)
2018-01-20T10:54:47.277792+00:00 app[web.1]: => Booting Puma
2018-01-20T10:54:47.277810+00:00 app[web.1]: => Rails 5.0.6 application starting in production on http://0.0.0.0:38017
2018-01-20T10:54:47.277812+00:00 app[web.1]: => Run `rails server -h` for more startup options
2018-01-20T10:54:47.277818+00:00 app[web.1]: * Version 3.10.0 (ruby 2.3.4-p301), codename: Russell's Teapot
2018-01-20T10:54:47.277813+00:00 app[web.1]: Puma starting in single mode...
2018-01-20T10:54:47.277819+00:00 app[web.1]: * Min threads: 0, max threads: 16
2018-01-20T10:54:47.277908+00:00 app[web.1]: * Listening on tcp://0.0.0.0:38017
2018-01-20T10:54:47.277820+00:00 app[web.1]: * Environment: production
2018-01-20T10:54:47.278132+00:00 app[web.1]: Use Ctrl-C to stop
2018-01-20T10:54:47.817688+00:00 heroku[web.1]: State changed from starting to up
2018-01-20T10:56:14.896122+00:00 heroku[router]: at=info method=GET path="/" host=salty-peak-94323.herokuapp.com request_id=85b8c594-2d92-4e76-9060-01caf2307a44 fwd="45.115.104.19" dyno=web.1 connect=0ms service=268ms status=500 bytes=1735 protocol=https
2018-01-20T10:59:49.774607+00:00 heroku[router]: at=info method=GET path="/" host=salty-peak-94323.herokuapp.com request_id=d60e4280-6d74-42ff-93e4-5a47dcc3bc93 fwd="45.115.104.19" dyno=web.1 connect=0ms service=41ms status=500 bytes=1735 protocol=https
The logs says DEPRECATION WARNING: config.serve_static_files is deprecated and will be removed in Rails 5.1, Please use config.public_file_server.enabled = true instead, So try to change this to what it is saying, Although i believe it is just a warning and it should not break your app but i found a related question to this one, Here it is, Hope it helps

Heroku rails installation stopped working after month

I set up this super simple rails app about 5 month ago and it worked until lately.
But today i noticed im getting this error: "We're sorry, but something went wrong. If you are the application owner check the logs for more information."
I checked the heroku logs but i dont see any errors appart from what i assume is the daily restart:
2017-02-11T01:37:52.624288+00:00 heroku[router]: at=info method=GET path="/favicon.ico" host=url.herokuapp.com request_id=918be0b7-bf45-4111-97b8-d95450dd3507 fwd="126.7.114.122" dyno=web.1 connect=0ms service=4ms status=200 bytes=228
2017-02-11T01:38:45.926088+00:00 heroku[web.1]: Restarting
2017-02-11T01:38:45.927276+00:00 heroku[web.1]: State changed from up to starting
2017-02-11T01:38:46.437082+00:00 app[web.1]: [2017-02-11 01:38:46] FATAL SignalException: SIGTERM
2017-02-11T01:38:46.437099+00:00 app[web.1]: /app/vendor/ruby-2.2.4/lib/ruby/2.2.0/webrick/server.rb:174:in `select'
2017-02-11T01:38:46.437100+00:00 app[web.1]: /app/vendor/ruby-2.2.4/lib/ruby/2.2.0/webrick/server.rb:174:in `block in start'
2017-02-11T01:38:46.437101+00:00 app[web.1]: /app/vendor/ruby-2.2.4/lib/ruby/2.2.0/webrick/server.rb:32:in `start'
2017-02-11T01:38:46.437102+00:00 app[web.1]: /app/vendor/ruby-2.2.4/lib/ruby/2.2.0/webrick/server.rb:162:in `start'
2017-02-11T01:38:46.437103+00:00 app[web.1]: /app/vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/handler/webrick.rb:34:in `run'
2017-02-11T01:38:46.437103+00:00 app[web.1]: /app/vendor/bundle/ruby/2.2.0/gems/rack-1.6.4/lib/rack/server.rb:286:in `start'
2017-02-11T01:38:46.437104+00:00 app[web.1]: /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.6/lib/rails/commands/server.rb:80:in `start'
2017-02-11T01:38:46.437105+00:00 app[web.1]: /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:80:in `block in server'
2017-02-11T01:38:46.437105+00:00 app[web.1]: /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:75:in `tap'
2017-02-11T01:38:46.437106+00:00 app[web.1]: /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:75:in `server'
2017-02-11T01:38:46.437106+00:00 app[web.1]: /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.6/lib/rails/commands/commands_tasks.rb:39:in `run_command!'
2017-02-11T01:38:46.437107+00:00 app[web.1]: /app/vendor/bundle/ruby/2.2.0/gems/railties-4.2.6/lib/rails/commands.rb:17:in `<top (required)>'
2017-02-11T01:38:46.437108+00:00 app[web.1]: bin/rails:9:in `require'
2017-02-11T01:38:46.437109+00:00 app[web.1]: bin/rails:9:in `<main>'
2017-02-11T01:38:46.437176+00:00 app[web.1]: [2017-02-11 01:38:46] INFO going to shutdown ...
2017-02-11T01:38:46.437226+00:00 app[web.1]: [2017-02-11 01:38:46] INFO WEBrick::HTTPServer#start done.
I also took a look at my production.log file but it's weirdly empty.
I'm at a loss regarding how to trouble shoot this. any suggestion?
So, it turned out it wasnt actually related to the environment.
I ran the site on my machine with the prod env and was able to find an access_token was expired which error wasnt caught correctly causing the 500 error.
I fixed it and redeployed the site. it works now.

Completed 500 Internal Server Error on heroku devise sign up

Keep getting this error when trying to sign up on live Rails app. The log also shows this:
2015-06-15T00:13:57.424501+00:00 heroku[router]: at=info method=POST path="/users" host=viral-blocmarks.herokuapp.com request_id=9e9de849-e0fa-40d2-b9a9-d69b605bb55d fwd="71.163.107.55" dyno=web.1 connect=1ms service=105ms status=500 bytes=1754
The app runs fine in development mode, sign up and sign in without problems. Looked at the versions of my databases in local and remote heroku, and they are out of sync. Heroku version is this (heroku run rake db:version):
20150614012934
Local version is this (rake db:version):
20150614160654
I tried to sync them using
heroku run rake db:migrate
But they don't sync, maybe because there is no difference. Anyway, I would appreciate some help since the answers to similar posts don't seem to work for me.
I ran the following, but it didn't help:
heroku run rake db:reset
Went to the live app, and was NOT able to sign up. Got the logs, which had the same error
Completed 500 Internal Server Error in 707ms (ActiveRecord: 10.0ms)
2015-06-15T02:55:49.697158+00:00 app[web.1]: vendor/bundle/ruby/2.0.0/gems/actionpack-4.2.1/lib/action_dispatch/middleware/static.rb:113:in `call'
2015-06-15T02:55:49.697160+00:00 app[web.1]: vendor/bundle/ruby/2.0.0/gems/rack-1.6.1/lib/rack/sendfile.rb:113:in `call'
2015-06-15T02:55:49.697163+00:00 app[web.1]: vendor/bundle/ruby/2.0.0/gems/railties-4.2.1/lib/rails/application.rb:164:in `call'
2015-06-15T02:55:49.697161+00:00 app[web.1]: vendor/bundle/ruby/2.0.0/gems/railties-4.2.1/lib/rails/engine.rb:518:in `call'
2015-06-15T02:55:49.697165+00:00 app[web.1]: vendor/bundle/ruby/2.0.0/gems/rack-1.6.1/lib/rack/lock.rb:17:in `call'
2015-06-15T02:55:49.697166+00:00 app[web.1]: vendor/bundle/ruby/2.0.0/gems/rack-1.6.1/lib/rack/content_length.rb:15:in `call'
2015-06-15T02:55:49.697168+00:00 app[web.1]: vendor/bundle/ruby/2.0.0/gems/rack-1.6.1/lib/rack/handler/webrick.rb:89:in `service'
2015-06-15T02:55:49.697171+00:00 app[web.1]: vendor/ruby-2.0.0/lib/ruby/2.0.0/webrick/httpserver.rb:94:in `run'
2015-06-15T02:55:49.697169+00:00 app[web.1]: vendor/ruby-2.0.0/lib/ruby/2.0.0/webrick/httpserver.rb:138:in `service'
2015-06-15T02:55:49.697172+00:00 app[web.1]: vendor/ruby-2.0.0/lib/ruby/2.0.0/webrick/server.rb:295:in `block in start_thread'
found the error. I didn't modify my setup_mail.rb for production:
if Rails.env.development? || Rails.env.production?
Once I added the OR clause, and then deployed, email sign up, confirmation and sign in all worked fine.

Heroku Aplication error with Google charts

I've got Rails app with Google charts. Everything goes very well on localhost, but on Heroku doesn't. Here is a heroku log:
$ heroku logs
2013-03-16T13:37:16+00:00 heroku[web.1]: Process exited with status 1
2013-03-16T13:37:16+00:00 heroku[web.1]: State changed from starting to crashed
2013-03-16T13:47:42+00:00 heroku[web.1]: State changed from crashed to starting
2013-03-16T13:47:43+00:00 heroku[web.1]: Starting process with command `bundle exec rails server -p 35505`
2013-03-16T13:47:45+00:00 app[web.1]: from /app/config/boot.rb:2:in `<top (required)>'
2013-03-16T13:47:45+00:00 app[web.1]: from script/rails:5:in `require'
2013-03-16T13:47:45+00:00 app[web.1]: from script/rails:5:in `<main>'
2013-03-16T13:47:45+00:00 app[web.1]: /app/config/boot.rb:2:in `require': no such file to load -- google_chart (LoadError)
2013-03-16T13:47:47+00:00 heroku[web.1]: State changed from starting to crashed
2013-03-16T13:47:47+00:00 heroku[web.1]: Process exited with status 1
2013-03-16T13:57:51+00:00 heroku[web.1]: State changed from crashed to starting
2013-03-16T13:57:53+00:00 heroku[web.1]: Starting process with command `bundle exec rails server -p 14631`
2013-03-16T13:57:57+00:00 app[web.1]: /app/config/boot.rb:2:in `require': no such file to load -- google_chart (LoadError)
2013-03-16T13:57:57+00:00 app[web.1]: from /app/config/boot.rb:2:in `<top (required)>'
2013-03-16T13:57:57+00:00 app[web.1]: from script/rails:5:in `require'
2013-03-16T13:57:57+00:00 app[web.1]: from script/rails:5:in `<main>'
2013-03-16T13:57:58+00:00 heroku[web.1]: Process exited with status 1
2013-03-16T13:57:58+00:00 heroku[web.1]: State changed from starting to crashed
2013-03-16T14:07:55+00:00 heroku[web.1]: State changed from crashed to starting
2013-03-16T14:07:58+00:00 heroku[web.1]: Starting process with command `bundle exec rails server -p 40304`
2013-03-16T14:08:00+00:00 app[web.1]: /app/config/boot.rb:2:in `require': no such file to load -- google_chart (LoadError)
2013-03-16T14:08:00+00:00 app[web.1]: from script/rails:5:in `<main>'
2013-03-16T14:08:00+00:00 app[web.1]: from /app/config/boot.rb:2:in `<top (required)>'
2013-03-16T14:08:00+00:00 app[web.1]: from script/rails:5:in `require'
2013-03-16T14:08:01+00:00 heroku[web.1]: Process exited with status 1
2013-03-16T14:08:01+00:00 heroku[web.1]: State changed from starting to crashed
2013-03-16T14:18:01+00:00 heroku[web.1]: State changed from crashed to starting
2013-03-16T14:18:03+00:00 heroku[web.1]: Starting process with command `bundle exec rails server -p 46534`
2013-03-16T14:18:05+00:00 app[web.1]: /app/config/boot.rb:2:in `require': no such file to load -- google_chart (LoadError)
2013-03-16T14:18:05+00:00 app[web.1]: from /app/config/boot.rb:2:in `<top (required)>'
2013-03-16T14:18:05+00:00 app[web.1]: from script/rails:5:in `require'
2013-03-16T14:18:05+00:00 app[web.1]: from script/rails:5:in `<main>'
2013-03-16T14:18:07+00:00 heroku[web.1]: State changed from starting to crashed
2013-03-16T14:18:07+00:00 heroku[web.1]: Process exited with status 1
2013-03-16T14:28:11+00:00 heroku[web.1]: State changed from crashed to starting
2013-03-16T14:28:12+00:00 heroku[web.1]: Starting process with command `bundle exec rails server -p 12019`
2013-03-16T14:28:16+00:00 app[web.1]: /app/config/boot.rb:2:in `require': no such file to load -- google_chart (LoadError)
2013-03-16T14:28:16+00:00 app[web.1]: from /app/config/boot.rb:2:in `<top (required)>'
2013-03-16T14:28:16+00:00 app[web.1]: from script/rails:5:in `require'
2013-03-16T14:28:16+00:00 app[web.1]: from script/rails:5:in `<main>'
2013-03-16T14:28:17+00:00 heroku[web.1]: Process exited with status 1
2013-03-16T14:28:17+00:00 heroku[web.1]: State changed from starting to crashed
2013-03-16T14:38:18+00:00 heroku[web.1]: State changed from crashed to starting
2013-03-16T14:38:20+00:00 heroku[web.1]: Starting process with command `bundle exec rails server -p 26652`
2013-03-16T14:38:22+00:00 app[web.1]: /app/config/boot.rb:2:in `require': no such file to load -- google_chart (LoadError)
2013-03-16T14:38:22+00:00 app[web.1]: from /app/config/boot.rb:2:in `<top (required)>'
2013-03-16T14:38:22+00:00 app[web.1]: from script/rails:5:in `<main>'
2013-03-16T14:38:22+00:00 app[web.1]: from script/rails:5:in `require'
2013-03-16T14:38:23+00:00 heroku[web.1]: Process exited with status 1
2013-03-16T14:38:23+00:00 heroku[web.1]: State changed from starting to crashed
2013-03-16T14:48:53+00:00 heroku[web.1]: State changed from crashed to starting
2013-03-16T14:48:55+00:00 heroku[web.1]: Starting process with command `bundle exec rails server -p 22351`
2013-03-16T14:48:57+00:00 app[web.1]: /app/config/boot.rb:2:in `require': no such file to load -- google_chart (LoadError)
2013-03-16T14:48:57+00:00 app[web.1]: from /app/config/boot.rb:2:in `<top (required)>'
2013-03-16T14:48:57+00:00 app[web.1]: from script/rails:5:in `<main>'
2013-03-16T14:48:57+00:00 app[web.1]: from script/rails:5:in `require'
2013-03-16T14:48:58+00:00 heroku[web.1]: Process exited with status 1
2013-03-16T14:48:58+00:00 heroku[web.1]: State changed from starting to crashed
2013-03-16T14:58:59+00:00 heroku[web.1]: State changed from crashed to starting
2013-03-16T14:59:01+00:00 heroku[web.1]: Starting process with command `bundle exec rails server -p 25792`
2013-03-16T14:59:04+00:00 app[web.1]: /app/config/boot.rb:2:in `require': no such file to load -- google_chart (LoadError)
2013-03-16T14:59:04+00:00 app[web.1]: from /app/config/boot.rb:2:in `<top (required)>'
2013-03-16T14:59:04+00:00 app[web.1]: from script/rails:5:in `require'
2013-03-16T14:59:04+00:00 app[web.1]: from script/rails:5:in `<main>'
2013-03-16T14:59:06+00:00 heroku[web.1]: State changed from starting to crashed
2013-03-16T14:59:06+00:00 heroku[web.1]: Process exited with status 1
2013-03-16T15:09:13+00:00 heroku[web.1]: State changed from crashed to starting
2013-03-16T15:09:14+00:00 heroku[web.1]: Starting process with command `bundle exec rails server -p 37918`
2013-03-16T15:09:16+00:00 app[web.1]: /app/config/boot.rb:2:in `require': no such file to load -- google_chart (LoadError)
2013-03-16T15:09:16+00:00 app[web.1]: from /app/config/boot.rb:2:in `<top (required)>'
2013-03-16T15:09:16+00:00 app[web.1]: from script/rails:5:in `require'
2013-03-16T15:09:16+00:00 app[web.1]: from script/rails:5:in `<main>'
2013-03-16T15:09:17+00:00 heroku[web.1]: Process exited with status 1
2013-03-16T15:09:17+00:00 heroku[web.1]: State changed from starting to crashed
2013-03-16T15:19:51+00:00 heroku[web.1]: Starting process with command `bundle exec rails server -p 32881`
2013-03-16T15:19:54+00:00 app[web.1]: /app/config/boot.rb:2:in `require': no such file to load -- google_chart (LoadError)
2013-03-16T15:19:54+00:00 app[web.1]: from /app/config/boot.rb:2:in `<top (required)>'
2013-03-16T15:19:54+00:00 app[web.1]: from script/rails:5:in `require'
2013-03-16T15:19:54+00:00 app[web.1]: from script/rails:5:in `<main>'
2013-03-16T15:19:55+00:00 heroku[web.1]: Process exited with status 1
2013-03-16T15:30:16+00:00 heroku[web.1]: State changed from crashed to starting
2013-03-16T15:32:31+00:00 heroku[web.1]: State changed from starting to down
2013-03-21T19:57:52+00:00 heroku[web.1]: Unidling
2013-03-21T19:57:52+00:00 heroku[web.1]: State changed from down to starting
2013-03-21T19:57:54+00:00 heroku[web.1]: Starting process with command `bundle exec rails server -p 20966`
2013-03-21T19:57:56+00:00 app[web.1]: from script/rails:5:in `<main>'
2013-03-21T19:57:56+00:00 app[web.1]: /app/config/boot.rb:2:in `require': no such file to load -- google_chart (LoadError)
2013-03-21T19:57:56+00:00 app[web.1]: from /app/config/boot.rb:2:in `<top (required)>'
2013-03-21T19:57:56+00:00 app[web.1]: from script/rails:5:in `require'
2013-03-21T19:57:57+00:00 heroku[web.1]: Process exited with status 1
2013-03-21T19:57:57+00:00 heroku[web.1]: State changed from crashed to starting
2013-03-21T19:57:57+00:00 heroku[web.1]: State changed from starting to crashed
2013-03-21T19:57:59+00:00 heroku[web.1]: Starting process with command `bundle exec rails server -p 58819`
2013-03-21T19:58:01+00:00 app[web.1]: /app/config/boot.rb:2:in `require': no such file to load -- google_chart (LoadError)
2013-03-21T19:58:01+00:00 app[web.1]: from /app/config/boot.rb:2:in `<top (required)>'
2013-03-21T19:58:01+00:00 app[web.1]: from script/rails:5:in `require'
2013-03-21T19:58:01+00:00 app[web.1]: from script/rails:5:in `<main>'
2013-03-21T19:58:02+00:00 heroku[web.1]: Process exited with status 1
2013-03-21T19:58:02+00:00 heroku[web.1]: State changed from starting to crashed
2013-03-21T19:58:04+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path=/ host=cvut-project-manager.herokuapp.com fwd="5.102.48.3" dyno= queue= wait= connect= service= status=503 bytes=
2013-03-21T19:58:06+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path=/favicon.ico host=cvut-project-manager.herokuapp.com fwd="5.102.48.3" dyno= queue= wait= connect= service= status=503 bytes=
I'm using gem "google_charts", "~> 1.2.0" and I've got
require 'google_chart'
in boot.rb.
In project controller:
.
.
#some minor logic
.
.
GoogleChart::PieChart.new('320x200', "Burndown pie chart",false) do |pc|
pc.data "Remain", #remain_points.to_i
pc.data "Done", #done_points.to_i
#chart = pc.to_url
end
respond_to do |format|
format.html # show.html.erb
format.json { render :json => #project }
end
end
boot.rb:
require 'rubygems'
require 'google_chart'
# Set up gems listed in the Gemfile.
ENV['BUNDLE_GEMFILE'] ||= File.expand_path('../../Gemfile', __FILE__)
require 'bundler/setup' if File.exists?(ENV['BUNDLE_GEMFILE'])
And link to that gem is:
https://github.com/rudionrails/google_charts
Rails version 3.2.8 with Ruby 1.8.7
So, please, can you tell me, why this works on localhost but not on heroku? Thank you.
Finally, I used
gem "googlecharts"
which works pretty well.

Resources