Skip to content

Commit

Permalink
Remove mutable dict from default argument
Browse files Browse the repository at this point in the history
  • Loading branch information
nicoddemus committed Jul 9, 2015
1 parent e5e2a95 commit 33752dc
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion _pytest/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -674,7 +674,9 @@ def _addoption_instance(self, option, shortupper=False):


class MyOptionParser(argparse.ArgumentParser):
def __init__(self, parser, extra_info={}):
def __init__(self, parser, extra_info=None):
if not extra_info:
extra_info = {}
self._parser = parser
argparse.ArgumentParser.__init__(self, usage=parser._usage,
add_help=False, formatter_class=DropShorterLongHelpFormatter)
Expand Down

0 comments on commit 33752dc

Please sign in to comment.