[issue41046] unittest: make skipTest a classmethod

2020-06-19 Thread James Corbett
New submission from James Corbett : The `unittest.TestCase.skipTest` method, used to skip the current test, is currently an instance method. There's nothing to stop it from being a `classmethod` or a `staticmethod` though---it doesn't use its reference to `self` since it's

[issue41046] unittest: make skipTest a classmethod

2020-06-19 Thread James Corbett
Change by James Corbett : -- keywords: +patch pull_requests: +20171 stage: -> patch review pull_request: https://github.com/python/cpython/pull/20996 ___ Python tracker <https://bugs.python.org/issu

[issue41047] argparse: misbehavior when combining positionals and choices

2020-06-19 Thread James Corbett
New submission from James Corbett : The `argparse.ArgumentParser` sometimes rejects positional arguments with no arguments when `choices` is set and `nargs="*"`. When there are no arguments and `nargs` is `"*"`, the default value is chosen, or `[]` if there is no defau

[issue41047] argparse: misbehavior when combining positionals and choices

2020-06-19 Thread James Corbett
Change by James Corbett : -- keywords: +patch pull_requests: +20172 stage: -> patch review pull_request: https://github.com/python/cpython/pull/20997 ___ Python tracker <https://bugs.python.org/issu

[issue41046] unittest: make skipTest a classmethod

2020-07-28 Thread James Corbett
James Corbett added the comment: I was careless in my example, it would need to be `cls.skipTest(reason)`. However, that really doesn't have anything to do with why it should be a `classmethod` instead of an instance method: it's so that you can call `skipTest` from `classmethod

[issue41430] Document C docstring behavior

2020-07-28 Thread James Corbett
New submission from James Corbett : As described in https://stackoverflow.com/questions/25847035/what-are-signature-and-text-signature-used-for-in-python-3-4, https://bugs.python.org/issue20586, and https://stackoverflow.com/questions/50537407/add-a-signature-with-annotations-to-extension

[issue41430] Document C docstring behavior

2020-07-28 Thread James Corbett
Change by James Corbett : -- keywords: +patch pull_requests: +20816 stage: -> patch review pull_request: https://github.com/python/cpython/pull/21673 ___ Python tracker <https://bugs.python.org/issu

[issue41436] BUG a simple "and" and "or"

2020-07-29 Thread James Corbett
James Corbett added the comment: I think this would have been a better fit for a StackOverflow issue: https://stackoverflow.com/questions/tagged/python. Also, it's not a compilation error and it doesn't have anything to do with CPython's testing framework. Anyway, I don&#x

[issue9625] argparse: Problem with defaults for variable nargs when using choices

2020-07-29 Thread James Corbett
James Corbett added the comment: I would love to get this issue resolved; it seems like everyone agrees that it's a bug. It came up for me recently: https://bugs.python.org/issue41047. Judging from the comments above, the consensus is that the relevant line, `self._check_value(action,