def main(self, argv=None):
options = self.parser.parse_args(argv)
if not hasattr(options, "cmd"):
- self.parser.print_help()
+ # see http://bugs.python.org/issue9253, argparse
+ # behavior changed incompatibly in py3.3
+ self.parser.error("too few arguments")
else:
cfg = Config(options.config, options.name)
self.run_cmd(cfg, options)
.. changelog::
:version: 0.5.0
+ .. change::
+ :tags: bug
+ :pullreq: 27
+
+ Worked around a backwards-incompatible regression in Python3.3
+ regarding argparse; running "alembic" with no arguments
+ now yields an informative error in py3.3 as with all previous versions.
+ Courtesy Andrey Antukh.
+
.. change::
:tags: change