Closed Bug 885871 Opened 11 years ago Closed 11 years ago

No such file or directory: favicon.ico

Categories

(Socorro :: Webapp, task)

task
Not set
normal

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: stephend, Assigned: peterbe)

References

()

Details

STR: Load https://crash-stats-django.allizom.org/favicon.ico (seems legit) Actual: IOError: [Errno 2] No such file or directory: '/data/www/crash-stats-django.allizom.org/app/static/img/favicon.ico' Stacktrace (most recent call last): File "django/core/handlers/base.py", line 111, in get_response response = callback(request, *callback_args, **callback_kwargs) File "crashstats/crashstats/views.py", line 41, in favicon_ico return http.HttpResponse(open(filename).read(), mimetype='image/x-icon')
Assignee: nobody → jezdez
I was able to confirm that the favicon file is indeed being found when running the collectstatic management command. So in other words, this is definitely a deployment issue, not a code problem. I guess we could extend the favicon view to throw a 404 instead of a 500 if the file can't be found, but that seems to only hide the problem. Assigning to Peter since he better knows how to deal with this situation.
Flags: needinfo?(peterbe)
Assignee: jezdez → peterbe
notablocker
No longer blocks: 749359
Flags: needinfo?(peterbe)
Summary: [socorro-crashstats][traceback] IOError: [Errno 2] No such file or directory: '/data/www/crash-stats-django.allizom.org/app/static/img/favicon.ico' → No such file or directory: favicon.ico
Pull request: https://github.com/mozilla/socorro-crashstats/pull/400 :jezdez :rhelmer r? This is quite a crucial change. My bad, I think it was wrong of the tests to depend on running collectstatic to be able to run the test suite. As of this patch, after you do what jenkins does the tarball will contain a perfectly fine static/img/favicon.ico image which will solve the bug. Developers will, as of this landing, have a choice: 1. [Convenient alternative] Being able to run the tests without running `collectstatic` and `compress_jingo`. This takes about **20+ seconds** to run the whole suite. Every time. 2. [Fast alternative] Editing settings/local.py and adding `COMPRESS_OFFLINE = True` and then running `collectstatic` and `compress_jingo` (once) and now the whole test suite takes **2 seconds** each time.
Commit pushed to master at https://github.com/mozilla/socorro-crashstats https://github.com/mozilla/socorro-crashstats/commit/e00e137503f5d47ba422c68d868dada380da87ff fixes bug 885871 - No such file or directory: favicon.ico, r=rhelmer This changes so that offline compression is by default DISABLED. That makes running the whole test suite about 10 times slower. Alternatively a developer (who runs tests often and wants to run them fast) is instructed in settings/local.py-dist how to change it. Also, this patch changes how the favicon test is run. Instead of relying on ``collectstatic`` having been run, it instead uses a temporary directory thus making sure that running ``./manage.py test`` doesn't affect any of the static files created.
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Still no dice on dev: [12:28:14.527] GET https://crash-stats-dev.allizom.org/favicon.co [HTTP/1.1 404 NOT FOUND 32ms]
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
(In reply to Stephen Donner [:stephend] from comment #6) > Still no dice on dev: > > [12:28:14.527] GET https://crash-stats-dev.allizom.org/favicon.co [HTTP/1.1 > 404 NOT FOUND 32ms] Hrm WFM? http://crash-stats-dev.allizom.org/favicon.ico
Target Milestone: --- → 52
OK, yeah, had a typo, sorry: https://crash-stats-dev.allizom.org/favicon.ico is definitely there. Might need spin-off bugs, but looks like we request it twice: http://www.webpagetest.org/result/130702_TN_185T/1/details/
Status: REOPENED → RESOLVED
Closed: 11 years ago11 years ago
Resolution: --- → FIXED
Verified FIXED
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.