On Tue, Jul 10, 2012 at 10:56 AM, Chris Hare <ch...@labr.net> wrote: > The input to the function in the larger program is the same as the first test > in the small script that works -- "admin". > > As a side note -- the rstrip call is also broken, although the string module > is imported. I just can't figure out why this code works in one context and > not in another.
I suspect you defined "bool" somewhere to be a string. That, or else you passed in a string as the search argument. Unfortunately Python doesn't tell you which expression raised the exception, but certainly it's one of those two. -- Devin _______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor