Skip to content
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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bpo-44986: Fixed bug with date formats like %Y-%m-%d in help messages of argparse #27923

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Projects
None yet
4 participants
@SengerM
Copy link

@SengerM SengerM commented Aug 23, 2021

Fixed bug with date formats like %Y-%m-%d in help messages of argparse

Now this code does not produce any error when invoked with the -h option and produces the expected result:

import argparse

parser = argparse.ArgumentParser(description = 'Just a test code.')
parser.add_argument(
	'--from',
	metavar = 'when', 
	help = 	'A date in format %Y-%m-%d',
	dest = f'From',
	type = str,
	required = True,
)
args = parser.parse_args()

print(args.From)

https://bugs.python.org/issue44986

@the-knights-who-say-ni
Copy link

@the-knights-who-say-ni the-knights-who-say-ni commented Aug 23, 2021

Hello, and thanks for your contribution!

I'm a bot set up to make sure that the project can legally accept this contribution by verifying everyone involved has signed the PSF contributor agreement (CLA).

Recognized GitHub username

We couldn't find a bugs.python.org (b.p.o) account corresponding to the following GitHub usernames:

@SengerM

This might be simply due to a missing "GitHub Name" entry in one's b.p.o account settings. This is necessary for legal reasons before we can look at this contribution. Please follow the steps outlined in the CPython devguide to rectify this issue.

You can check yourself to see if the CLA has been received.

Thanks again for the contribution, we look forward to reviewing it!

@SengerM
Copy link
Author

@SengerM SengerM commented Aug 24, 2021

I don't know if a human will ever read this, but if so I have already signed the CLA yesterday and in the check yourself page still says that I have not signed it. Is it normal that it takes so long?

Lib/test/test_argparse.py Outdated Show resolved Hide resolved
@github-actions
Copy link

@github-actions github-actions bot commented Oct 1, 2021

This PR is stale because it has been open for 30 days with no activity.

@github-actions github-actions bot added the stale label Oct 1, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment