Author mark.dickinson
Recipients WitcherGeralt, mark.dickinson
Date 2013-08-03.13:40:07
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1375537207.25.0.0436984099259.issue18642@psf.upfronthosting.co.za>
In-reply-to
Content
Ah, so I think I don't understand the proposal.  In your original message,  is it your intention that the assert raises TypeError, or that it raises AssertionError?

Again:  what's the benefit over existing solutions?  Either:

    if not isinstance(data, basestring):
        raise TypeError("Bad user!  You gave me the wrong type")

or

    assert isinstance(data, basestring), "data should be a string at this point"

?
History
Date User Action Args
2013-08-03 13:40:07mark.dickinsonsetrecipients: + mark.dickinson, WitcherGeralt
2013-08-03 13:40:07mark.dickinsonsetmessageid: <1375537207.25.0.0436984099259.issue18642@psf.upfronthosting.co.za>
2013-08-03 13:40:07mark.dickinsonlinkissue18642 messages
2013-08-03 13:40:07mark.dickinsoncreate