Re: argparse and default for FileType

2011-04-12 Thread Paolo Elvati
> Open up a bug report on the Python bug tracker and assign it to the user > "bethard", who is the author of argparse. He's usually pretty responsive. Thank you for the answer, I will. Paolo -- http://mail.python.org/mailman/listinfo/python-list

argparse and default for FileType

2011-04-08 Thread Paolo Elvati
Hi, I noticed a "strange" behavior of argparse. When running a simple code like the following: import argparse parser = argparse.ArgumentParser() parser.add_argument( "-o", default = 'fake', dest = 'OutputFile', type = argparse.FileType('w') ) args = parser.parse_args() I noticed that t