T
Tom Van den Brandt
Hello !
As you might have guessed, I'm one of those newbie-types, comming here,
asking questions and stuff...
Very specific question, it's probably a bit basic so forgive me if it's
stupid to ask...
If I have an __init__ for a class and the initialisation can't go through
(example: missing or wrong arguments), how do I return an error to the
caller (from main() function)? When I do a return statement in the
__init__ it says __init__ should return None... I can stop the flow with
raise 'BlahBlah'. But then the program exits.
What is the nice way to do this ?
Tnx,
As you might have guessed, I'm one of those newbie-types, comming here,
asking questions and stuff...
Very specific question, it's probably a bit basic so forgive me if it's
stupid to ask...
If I have an __init__ for a class and the initialisation can't go through
(example: missing or wrong arguments), how do I return an error to the
caller (from main() function)? When I do a return statement in the
__init__ it says __init__ should return None... I can stop the flow with
raise 'BlahBlah'. But then the program exits.
What is the nice way to do this ?
Tnx,