Skip to content

Commit

Permalink
pythongh-121277: Raise nice error on next as second argument to dep…
Browse files Browse the repository at this point in the history
…recated-removed (pythonGH-124623)
  • Loading branch information
encukou authored Sep 27, 2024
1 parent 6716dd1 commit e349f73
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Doc/tools/extensions/pyspecific.py
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,9 @@ def run(self):
version_deprecated = expand_version_arg(self.arguments[0],
self.config.release)
version_removed = self.arguments.pop(1)
if version_removed == 'next':
raise ValueError(
'deprecated-removed:: second argument cannot be `next`')
self.arguments[0] = version_deprecated, version_removed

# Set the label based on if we have reached the removal version
Expand Down

0 comments on commit e349f73

Please sign in to comment.