#11667: Full traceback if import error before model validation ------------------------------------------------+--------------------------- Reporter: jedie | Owner: nobody Status: new | Milestone: Component: django-admin.py runserver | Version: 1.1 Resolution: | Keywords: Stage: Accepted | Has_patch: 1 Needs_docs: 0 | Needs_tests: 1 Needs_better_patch: 0 | ------------------------------------------------+--------------------------- Comment (by vanschelven):
Any movement on this? I can't count the number of times I've dived into the Django code and added a 'raise'. Of course, the proper solution would be simply to drop the associated try/catch block, since all it does is obfuscate things. This can be rewritten: {{{ 206 if self.can_import_settings: 207 try: 208 from django.utils import translation 209 translation.activate('en-us') 210 except ImportError, e: 211 # If settings should be available, but aren't, 212 # raise the error and quit. 213 sys.stderr.write(smart_str(self.style.ERROR('Error: %s\n' % e))) 214 sys.exit(1) }}} I'll submit a patch in a sec. -- Ticket URL: <http://code.djangoproject.com/ticket/11667#comment:9> Django <http://code.djangoproject.com/> The Web framework for perfectionists with deadlines. -- You received this message because you are subscribed to the Google Groups "Django updates" group. To post to this group, send email to django-updates@googlegroups.com. To unsubscribe from this group, send email to django-updates+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-updates?hl=en.