[Tutor] TypeError: 'str' object is not callable
Alan Gauld
alan.gauld at blueyonder.co.uk
Sun Sep 7 22:28:29 EDT 2003
> > TypeError: 'str' object is not callable
>
> I think what you mean to do in your code is call the os.exit
function,
> as opposed to the string named "exit" in the built-ins.
Or better still raise the SystemExit exception which automatically
ensures all the correct exit hooks are called and doesn't need any
module involvement.
Alan g.
More information about the Tutor
mailing list