This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author exarkun
Recipients exarkun
Date 2008-09-04.22:10:08
SpamBayes Score 0.000311686
Marked as misclassified No
Message-id <>
This example shows the behavior:

    from warnings import catch_warnings

    def test():
        with catch_warnings(True) as w:
            assert str(w.message) == "foo", "%r != %r" % (w.message, "foo")


This fails with an IndexError from the `w.message`.  That's a bit
surprising, and since this is mostly an API useful for testing, it'd be
much better if it had a well-defined, documented (ie, stable and likely
to continue working in the next release of Python) error mode.
Date User Action Args
2008-09-04 22:10:09exarkunsetrecipients: + exarkun
2008-09-04 22:10:09exarkunsetmessageid: <>
2008-09-04 22:10:08exarkunlinkissue3781 messages
2008-09-04 22:10:08exarkuncreate