True to get the full traceback? If you set the ADMINS tuple in the
settings you also can get an email with the traceback when DEBUG =
False. The email backend can also be configured with the
EMAIL_BACKENDS setting, so you can, for example, write to a log file
instead [1].
Hope this helps,
-Roberto.
[1] http://docs.djangoproject.com/en/dev/topics/email/#e-mail-backends
On Jul 27, 2:06 am, ffffff <cp368...@ohio.edu> wrote:
> I have a python script that creates and then uploads a file to a
> django app. Sometimes the django app will error out and my script will
> just return this:
>
> Traceback (most recent call last):
> File "/home/chris/bin/upload.py", line 318, in <module>
> send_request(tmpzip, var1, var2, options.meta, url)
> File "/srv/the_system/scripts/multipart.py", line 89, in
> send_request
> print urllib2.urlopen(request).read()
> File "/usr/lib/python2.6/urllib2.py", line 126, in urlopen
> return _opener.open(url, data, timeout)
> File "/usr/lib/python2.6/urllib2.py", line 397, in open
> response = meth(req, response)
> File "/usr/lib/python2.6/urllib2.py", line 510, in http_response
> 'http', request, response, code, msg, hdrs)
> File "/usr/lib/python2.6/urllib2.py", line 435, in error
> return self._call_chain(*args)
> File "/usr/lib/python2.6/urllib2.py", line 369, in _call_chain
> result = func(*args)
> File "/usr/lib/python2.6/urllib2.py", line 518, in
> http_error_default
> raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
> urllib2.HTTPError: HTTP Error 500: INTERNAL SERVER ERROR
>
> Its very hard to pinpoint what exactly went wrong with just a big
> "ERROR 500" message...
>
> Does anyone have any tips on how to get the full fancy traceback when
> interfacing with a django app in this way?
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
No comments:
Post a Comment