a little docstring for ParsedException.to_string, pretty much resolving #80

This commit is contained in:
Mahmoud Hashemi 2016-06-07 19:12:10 -07:00
parent df56a3ba0d
commit 52bfc7cd05
1 changed files with 6 additions and 0 deletions

View File

@ -683,6 +683,12 @@ class ParsedException(object):
% (cn, self.exc_type, self.exc_msg, self.frames))
def to_string(self):
"""Formats the exception and its traceback into the standard format,
as returned by the traceback module.
``ParsedException.from_string(text).to_string()`` should yield
``text``.
"""
lines = [u'Traceback (most recent call last):']
for frame in self.frames: