Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

fix: duplicate subparsers being added to argparse#2014

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
nejch merged 1 commit intomainfromjlvillal/python3.11beta1
May 9, 2022

Conversation

@JohnVillalovos
Copy link
Member

@JohnVillalovosJohnVillalovos commentedMay 8, 2022
edited
Loading

Python 3.11 added an additional check in the argparse libary which
detected duplicate subparsers being added. We had duplicate subparsers
being added.

Make sure we don't add duplicate subparsers.
Closes:#2015

@JohnVillalovos
Copy link
MemberAuthor

@nejch Seems like Python 3.11.0-beta.1 doesn't like what we are doing...

@JohnVillalovos
Copy link
MemberAuthor

I think this is the upstream commit:

python/cpython@ad5e852

commit ad5e8520f3e117f45481513014548a39879d30d2Author: Antony Lee <anntzer.lee@gmail.com>Date:   Sun May 1 08:04:50 2022 +0200    bpo-39716: Raise on conflicting subparser names. (GH-18605)    Raise an ArgumentError when the same subparser name is added twice to an    ArgumentParser.  This is consistent with the (default) behavior when the    same option string is added twice to an ArgumentParser.    (Support for `conflict_handler="resolve"` could be considered as a    followup feature, although real use cases seem even rarer than    "resolve"ing option-strings.)    Automerge-Triggered-By: GH:rhettinger

@JohnVillalovos
Copy link
MemberAuthor

The PR upstream:python/cpython#18605

@JohnVillalovos
Copy link
MemberAuthor

Probably should create an issue for this instead of my dummy PR 😊

@JohnVillalovosJohnVillalovosforce-pushed thejlvillal/python3.11beta1 branch 4 times, most recently fromd64b159 to14df327CompareMay 8, 2022 19:20
@JohnVillalovosJohnVillalovos changed the titleWIP: testing Python 3.11.0-beta.1fix: duplicate subparsers being added to argparseMay 8, 2022
@JohnVillalovosJohnVillalovos requested a review fromnejchMay 8, 2022 19:20
@JohnVillalovosJohnVillalovosforce-pushed thejlvillal/python3.11beta1 branch from14df327 to6f013d1CompareMay 8, 2022 19:26
@codecov-commenter
Copy link

codecov-commenter commentedMay 8, 2022
edited
Loading

Codecov Report

Merging#2014 (c7dcedd) intomain (6b47c26) willdecrease coverage by0.03%.
The diff coverage is69.23%.

@@            Coverage Diff             @@##             main    #2014      +/-   ##==========================================- Coverage   92.65%   92.62%   -0.04%==========================================  Files          78       78                Lines        4944     4949       +5     ==========================================+ Hits         4581     4584       +3- Misses        363      365       +2
FlagCoverage Δ
cli_func_v481.39% <69.23%> (-0.03%)⬇️
py_func_v480.33% <0.00%> (-0.09%)⬇️
unit83.53% <69.23%> (-0.03%)⬇️

Flags with carried forward coverage won't be shown.Click here to find out more.

Impacted FilesCoverage Δ
gitlab/v4/cli.py81.18% <69.23%> (-0.38%)⬇️

@JohnVillalovosJohnVillalovosforce-pushed thejlvillal/python3.11beta1 branch 2 times, most recently frome812380 toc7dceddCompareMay 8, 2022 22:01
Python 3.11 added an additional check in the argparse libary whichdetected duplicate subparsers being added. We had duplicate subparsersbeing added.Make sure we don't add duplicate subparsers.Closes:#2015
@JohnVillalovosJohnVillalovosforce-pushed thejlvillal/python3.11beta1 branch fromc7dcedd tof553fd3CompareMay 9, 2022 13:40
@nejchnejch merged commit7d5a0c9 intomainMay 9, 2022
@nejchnejch deleted the jlvillal/python3.11beta1 branchMay 9, 2022 14:53
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@nejchnejchnejch left review comments

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Python 3.11 unit tests are failing due to argparse error

4 participants

@JohnVillalovos@codecov-commenter@nejch

[8]ページ先頭

©2009-2025 Movatter.jp