Python application
Proc file:
web: gunicorn app:app
Requirement:
beautifulsoup4==4.10.0
requests==2.27.1
gunicorn==20.1.0
flask==2.0.3
selenium==4.1.2
Error
2022-04-12T15:27:32.877398+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=scraper-papersdrop.herokuapp.com request_id=f189ac84-cfd8-4bec-9226-741250314389 fwd="157.51.25.187" dyno= connect= service= status=503 bytes= protocol=https
2022-04-12T15:27:33.499233+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/favicon.ico" host=scraper-papersdrop.herokuapp.com request_id=e7069e84-f6b4-4bc6-a4b1-7f4164efa674 fwd="157.51.25.187" dyno= connect= service= status=503 bytes= protocol=https
This error message...
2022-04-12T15:27:32.877398+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=scraper-papersdrop.herokuapp.com request_id=f189ac84-cfd8-4bec-9226-741250314389 fwd="157.51.25.187" dyno= connect= service= status=503 bytes= protocol=https
...indicates a crashed web dyno or a boot timeout on the web dyno.
Deep Dive
Heroku returns a standard error page with the HTTP status code 503. To assist in debuging the underlying error the platform also adds the custom error information along with its own error code, with all HTTP errors starting with the letter H and all runtime errors starting with R. Logging errors start with L.
Another example:
2010-10-06T21:51:12-07:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=myapp.herokuapp.com fwd=17.17.17.17 dyno= connect= service= status=503 bytes=
503 Service Unavailable
The HTTP 503 Service Unavailable server error response code indicates that the server is not in a state to handle the client request.
Some of the common causes are a server that is down for maintenance or that is overloaded with other requests. Ideally, this response should be used for temporary conditions and the Retry-After HTTP header possibly should, contain the estimated time for the recovery of the service.
This usecase
However in this usecase it seems:
protocol=https
host=scraper-papersdrop.herokuapp.com
dyno=
desc="App crashed"
status=503
which implies that the application wasn't deployed successfully.
Related
I implemented omniauth to allow users to login via Twitter. Everything works smooth on my local environment. However, after pushing to Heroku I get an error. The error appears after the redirect to Twitter and after I click to authorize the app. Can anyone point me in the right direction?
Heroku logs:
2014-12-06T22:54:36.173266+00:00 app[web.1]: Started GET "/auth/twitter/callback?oauth_token=0YwVXdIdacx8lK2g31xgtYN5PJzBrthV&oauth_verifier=6gYtUY1sHAimjOPQ2P9FBWqkG4t85wf1" for 207.62.246.40 at 2014-12-06 22:54:36 +0000
2014-12-06T22:54:36.179194+00:00 app[web.1]: I, [2014-12-06T22:54:36.178840 #2] INFO -- omniauth: (twitter) Callback phase initiated.
2014-12-06T22:54:36.784626+00:00 app[web.1]: Processing by SessionsController#create as HTML
2014-12-06T22:54:36.784637+00:00 app[web.1]: Parameters: {"oauth_token"=>"0YwVXdIdacx8lK2g31xgtYN5PJzBrthV", "oauth_verifier"=>"6gYtUY1sHAimjOPQ2P9FBWqkG4t85wf1", "provider"=>"twitter"}
2014-12-06T22:54:36.801839+00:00 app[web.1]: Completed 500 Internal Server Error in 17ms
2014-12-06T22:54:36.805144+00:00 app[web.1]:
2014-12-06T22:54:36.805147+00:00 app[web.1]: NameError (undefined local variable or method `omniauth' for #<Class:0x007f88aa8b7c90>):
2014-12-06T22:54:36.805149+00:00 app[web.1]: app/models/user.rb:11:in `block in create_with_omniauth'
2014-12-06T22:54:36.805150+00:00 app[web.1]: app/models/user.rb:7:in `create_with_omniauth'
2014-12-06T22:54:36.805152+00:00 app[web.1]: app/controllers/sessions_controller.rb:4:in `create'
2014-12-06T22:54:36.805154+00:00 app[web.1]:
2014-12-06T22:54:36.805155+00:00 app[web.1]:
2014-12-06T22:54:36.808588+00:00 heroku[router]: at=info method=GET path="/auth/twitter/callback?oauth_token=0YwVXdIdacx8lK2g31xgtYN5PJzBrthV&oauth_verifier=6gYtUY1sHAimjOPQ2P9FBWqkG4t85wf1" host=www.insidertees.com request_id=c242efb5-8070-4bea-848e-b5542dcf79f1 fwd="207.62.246.40" dyno=web.1 connect=2ms service=638ms status=500 bytes=1754
Dumb mistake. Change omniauth to auth. Issue solved.
I am using the simple rails gem feedback_popup and I have followed all the instructions. It works fine locally but when I push to heroku it no longer sends the email with the feedback though the logs look like it should:
Started POST "/feedback_popup/messages" for 89.27.92.12 at 2013-08-30 08:59:05 +0000
2013-08-30T08:59:05.904701+00:00 app[web.1]:
2013-08-30T08:59:06.008570+00:00 app[web.1]: Sent mail to info#example.com (110ms)
2013-08-30T08:59:06.109094+00:00 app[web.1]: Processing by FeedbackPopup::MessagesController#create as JS
2013-08-30T08:59:06.209392+00:00 app[web.1]: Parameters: {"utf8"=>"✓", "authenticity_token"=>"2jo/keno5XMWc1IgnyJUPBAu5vpLi4uzpHIRQrP+HeA=", "feedback_popup_message"=>{"body"=>"why doesn't this work"}, "commit"=>"Send"}
2013-08-30T08:59:06.310876+00:00 app[web.1]: Rendered vendor/bundle/ruby/2.0.0/gems/feedback_popup-0.0.1/app/views/feedback_popup/mailer/feedback.text.erb (0.0ms)
2013-08-30T08:59:06.412572+00:00 app[web.1]: Rendered vendor/bundle/ruby/2.0.0/gems/feedback_popup-0.0.1/app/views/feedback_popup/messages/create.js.erb (0.1ms)
2013-08-30T08:59:06.513491+00:00 app[web.1]: Completed 200 OK in 118ms (Views: 0.7ms | ActiveRecord: 0.0ms)
2013-08-30T08:59:05.899365+00:00 heroku[router]: at=info method=POST path=/feedback_popup/messages host=www.baybel.com fwd="89.27.92.12" dyno=web.1 connect=1ms service=132ms status=200 bytes=70
I am using MailChimp and that does a perfect job of sending the welcome email when people sign up. Any ideas?
It now works and I can think of two reasons:
1) Heroku didn't like that the config.mail_from was not an email address previously.
2) There were issues precompiling the assets.
I've read through a ton of seemingly similar issues on SO and blogs about setting cookies to work across domains, but my issue is more specific than that. In general, my session_store for cookies works like a charm in dev and prod, across browsers and across sub-domains with the single exception of IE8, which won't let me login (it just redirects me back to the landing page again), and presumably the issue is that it won't issue a cookie.
My session_store.rb initializer is:
Xavy2::Application.config.session_store :cookie_store, :key => 'sitesession', domain: ".site.com"
Here is the output from one IE8 login attept
2013-08-19T15:50:13.352878+00:00 app[web.1]: Started GET "/users/sign_in" for 154.51.130.161 at 2013-08-19 15:50:13 +0000
2013-08-19T15:49:03.398016+00:00 heroku[router]: at=info method=POST path=/users/sign_in host=www.xavy.com fwd="84.207.252.4" dyno=web.1 connect=1ms service=1263ms status=302 bytes=86
2013-08-19T15:50:18.350332+00:00 heroku[router]: at=info method=GET path=/users/sign_in host=www.xavy.com fwd="154.51.130.161" dyno=web.1 connect=2ms service=5033ms status=200 bytes=8737
2013-08-19T15:50:29.746857+00:00 app[web.1]: Started POST "/users/sign_in" for 154.51.130.161 at 2013-08-19 15:50:29 +0000
2013-08-19T15:50:30.282263+00:00 heroku[router]: at=info method=POST path=/users/sign_in host=www.xavy.com fwd="154.51.130.161" dyno=web.1 connect=14ms service=542ms status=302 bytes=86
2013-08-19T15:50:30.409250+00:00 app[web.1]: Started GET "/" for 154.51.130.161 at 2013-08-19 15:50:30 +0000
2013-08-19T15:50:30.679531+00:00 heroku[router]: at=info method=GET path=/ host=www.xavy.com fwd="154.51.130.161" dyno=web.1 connect=3ms service=276ms status=200 bytes=9291
2 service=6ms status=200 bytes=84056
I'm not sure if that's relevant or what else someone would need to see to help me debug or resolve this issue?
Thanks.
is there an underscore in the domain? if so that's probably the issue: Internet Explorer ignores cookies on some domains (cannot read or set cookies)
I'm hosting a Rails 3 site on Heroku, and I've found that whenever I push a new release, POST requests raise a RoutingError until the user clears his cookies. I don't have any problems while developing locally; just when I push to Heroku. So you can hit the front page, but you get a RoutingError when you submit the Sign Up and Log In forms. Has anyone else seen this behavior? Any ideas how to fix it?
I really don't think the problem here is my config/routes.rb or in my controllers/views, because normally this works, but it breaks when I push a new release, at least until cookies get cleared. Could this be a protect_from_forgery issue?
If it helps, here are my logs:
2011-08-29T16:42:30+00:00 heroku[router]: POST mysite.com/signup dyno=web.1 queue=0 wait=0ms service=354ms status=200 bytes=7518
2011-08-29T16:42:30+00:00 heroku[nginx]: 128.91.71.89 - staging [29/Aug/2011:09:42:30 -0700] "POST /signup HTTP/1.1" 200 2482 "http://mysite.com/" "Mozilla/5.0 (X11; Linux i686; rv:6.0) Gecko/20100101 Firefox/6.0" mysite.com
2011-08-29T16:43:17+00:00 app[web.1]:
2011-08-29T16:43:17+00:00 app[web.1]:
2011-08-29T16:43:17+00:00 app[web.1]: Started POST "/signup" for 128.91.71.74 at Mon Aug 29 09:43:17 -0700 2011
2011-08-29T16:43:17+00:00 app[web.1]:
2011-08-29T16:43:17+00:00 app[web.1]: ActionController::RoutingError (No route matches "/signup"):
Well, it turns out the problem was the login & signup forms were doing a PUT, not a POST, because #user was wrongly getting set under certain weird conditions. Sorry to waste the time of anyone who bothers reading this!
I have upload a simple app to Heroku which works fine, however, after some time it stops working and all the GET requests just block.
I get this error:
2011-05-13T13:04:11+00:00 app[web.1]: Started GET "/api/v1/69399ead0ed4ded38e7a101f7c8faf/2011-2-1.json" for 81.84.100.109 at Fri May 13 06:04:11 -0700 2011
2011-05-13T13:04:11+00:00 app[web.1]: Processing by ApiController#api_bounces as JSON
2011-05-13T13:04:11+00:00 app[web.1]: Parameters: {"api_id"=>"69399ead0ed4ded38e7a101f7c8faf", "init"=>"2011-2-1"}
2011-05-13T13:04:57+00:00 heroku[router]: Error H11 (Backlog too deep) -> GET bapi.heroku.com/favicon.ico dyno=none queue=0 wait=0ms service=0ms bytes=0
2011-05-13T13:05:05+00:00 heroku[router]: Error H12 (Request timeout) -> GET bapi.heroku.com/api/v1/69399ead0ed4ded38e7a101f7c8faf/2011-2-1.json dyno=web.1 queue=0 wait=0ms service=0ms bytes=0
2011-05-13T13:05:20+00:00 heroku[router]: Error H12 (Request timeout) -> GET bapi.heroku.com/api/v1/69399ead0ed4ded38e7a101f7c8faf/2011-2-1.json dyno=web.1 queue=0 wait=0ms service=0ms bytes=0
2011-05-13T13:05:36+00:00 heroku[router]: Error H12 (Request timeout) -> GET bapi.heroku.com/favicon.ico dyno=web.1 queue=0 wait=0ms service=0ms bytes=0
2011-05-13T13:05:36+00:00 heroku[router]: Error H12 (Request timeout) -> GET bapi.heroku.com/api/v1/69399ead0ed4ded38e7a101f7c8faf/2011-2-1.json dyno=web.1 queue=0 wait=0ms service=0ms bytes=0
I can't understand why, that never happened before with other apps.
You're getting a Backlog too deep error. Are you running on a single dyno? Your upload would be consuming that dyno so any additional requests would be being queued.
http://devcenter.heroku.com/articles/backlog-too-deep
John.