2012/1/29 Merlijn van Deen <valhallasw@arctus.nl>

Which is incredibly weird, considering the try-except block is inside showHelp, which is a line above the sys.exit(). 
I realized that myself after sending mail. :-)

Possibly the problem is caused by a double import
Exactly that's what happened!
 
The solution would then be to make sure pywikibot.handleArgs() is only called when the script runs from the command like (i.e. use a __name__=="__main__" block).
Thank you, this solved the problem finally! I had this block but I didn't know that handleArgs  had to be there. Now I understand.

--
Bináris