#24663: DEBUG view AttributeError on exception value.__traceback__ in python2
-------------------------------------+-------------------------------------
Reporter: fero | Owner: fero
Type: Bug | Status: new
Component: Core (Other) | Version: master
Severity: Release blocker | Resolution:
Keywords: debugview debug | Triage Stage:
template_debug | Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 1 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by fero):
* needs_better_patch: => 0
* needs_tests: => 0
* needs_docs: => 0
Comment:
I suppose that
[https://github.com/django/django/blob/master/django/views/debug.py#L452-L454
this comment] is not completely true ;). Code follows
{{{
# In case there's just one exception (always in Python 2,
# sometimes in Python 3), take the traceback from self.tb (Python 2
# doesn't have a __traceback__ attribute on Exception)
exc_value = exceptions.pop()
tb = self.tb if not exceptions else exc_value.__traceback__
}}}
Just some debug printing infos...
{{{
BEFORE [
IntegrityError('NOT NULL constraint failed: base_product.created',),
IntegrityError('NOT NULL constraint failed: base_product.created',)
]
AFTER exceptions.pop() [
IntegrityError('NOT NULL constraint failed: base_product.created',)
]
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/24663#comment:1>
Django <https://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 unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/062.4cf798b056059e7f0bcebbc2517ee105%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.