René's URL Explorer Experiment


Title: Fixed crash in Python 3.15.0a6 by tleonhardt · Pull Request #1604 · python-cmd2/cmd2 · GitHub

Open Graph Title: Fixed crash in Python 3.15.0a6 by tleonhardt · Pull Request #1604 · python-cmd2/cmd2

X Title: Fixed crash in Python 3.15.0a6 by tleonhardt · Pull Request #1604 · python-cmd2/cmd2

Description: The crash was caused by changes in the argparse internal API in Python 3.15, specifically in how it handles colorization and formatter initialization. Changes Made: Add testing for Python 3.15-dev: Start testing on Python 3.15 pre-release versions, currently 3.15.0a6 Cmd2HelpFormatter._set_color: Added an override for the _set_color method to handle the new file keyword argument introduced in Python 3.15. It uses a try-except block to fall back to the older signature if the underlying RichHelpFormatter (from rich-argparse) does not yet support the new keyword argument. Cmd2ArgumentParser._get_formatter: Updated the _get_formatter method to accept **kwargs and pass them to the superclass. This is necessary because Python 3.15's argparse now passes a file argument to this method in several places (e.g., print_usage). TextGroup.__init__: Updated the type hint for the formatter_creator parameter from Callable[[], Cmd2HelpFormatter] to Callable[..., Cmd2HelpFormatter] to remain consistent with the updated _get_formatter signature. string_utils.common_prefix function added as a replacement for os.path.commonprefix which is deprecated in Python 3.15. Closes #1603

Open Graph Description: The crash was caused by changes in the argparse internal API in Python 3.15, specifically in how it handles colorization and formatter initialization. Changes Made: Add testing for Python 3.15-de...

X Description: The crash was caused by changes in the argparse internal API in Python 3.15, specifically in how it handles colorization and formatter initialization. Changes Made: Add testing for Python 3.15-de...

Opengraph URL: https://github.com/python-cmd2/cmd2/pull/1604

X: @github

direct link

Domain: github.com

route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:3ee040b3-c06f-0d28-8a2d-d600d9ed6007
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-id8BA4:3FF0AC:105537B:166A767:6A4DD9A5
html-safe-nonce0cac0107b377e745e3d2d125922279f4b80db2682ae85e3a5f71629a5c317b66
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4QkE0OjNGRjBBQzoxMDU1MzdCOjE2NkE3Njc6NkE0REQ5QTUiLCJ2aXNpdG9yX2lkIjoiMjQxNjk3Mzk4ODQwNjA5MDE0OSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac0c8354211bc4d6c3281b8cd57210f42273e1c9eb3eb239a922809e302d033846
hovercard-subject-tagpull_request:3368237487
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/python-cmd2/cmd2/pull/1604/files
twitter:imagehttps://avatars.githubusercontent.com/u/2812720?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/2812720?s=400&v=4
og:image:altThe crash was caused by changes in the argparse internal API in Python 3.15, specifically in how it handles colorization and formatter initialization. Changes Made: Add testing for Python 3.15-de...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None06b8a6144231bf3a234f1c2e9993861e07ce98a905912b114aa386c2d7e84b33
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/python-cmd2/cmd2 git https://github.com/python-cmd2/cmd2.git
octolytics-dimension-user_id17161025
octolytics-dimension-user_loginpython-cmd2
octolytics-dimension-repository_id51442999
octolytics-dimension-repository_nwopython-cmd2/cmd2
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id51442999
octolytics-dimension-repository_network_root_nwopython-cmd2/cmd2
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release1d344bdb7547fe6bca17a59bb2b8aac3dc9532a0
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/python-cmd2/cmd2/pull/1604/files#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython-cmd2%2Fcmd2%2Fpull%2F1604%2Ffiles
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython-cmd2%2Fcmd2%2Fpull%2F1604%2Ffiles
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=python-cmd2%2Fcmd2
Reloadhttps://github.com/python-cmd2/cmd2/pull/1604/files
Reloadhttps://github.com/python-cmd2/cmd2/pull/1604/files
Reloadhttps://github.com/python-cmd2/cmd2/pull/1604/files
Please reload this pagehttps://github.com/python-cmd2/cmd2/pull/1604/files
python-cmd2 https://github.com/python-cmd2
cmd2https://github.com/python-cmd2/cmd2
Notifications https://github.com/login?return_to=%2Fpython-cmd2%2Fcmd2
Fork 132 https://github.com/login?return_to=%2Fpython-cmd2%2Fcmd2
Star 689 https://github.com/login?return_to=%2Fpython-cmd2%2Fcmd2
Code https://github.com/python-cmd2/cmd2
Issues 0 https://github.com/python-cmd2/cmd2/issues
Pull requests 0 https://github.com/python-cmd2/cmd2/pulls
Discussions https://github.com/python-cmd2/cmd2/discussions
Actions https://github.com/python-cmd2/cmd2/actions
Projects https://github.com/python-cmd2/cmd2/projects
Security and quality 0 https://github.com/python-cmd2/cmd2/security
Insights https://github.com/python-cmd2/cmd2/pulse
Code https://github.com/python-cmd2/cmd2
Issues https://github.com/python-cmd2/cmd2/issues
Pull requests https://github.com/python-cmd2/cmd2/pulls
Discussions https://github.com/python-cmd2/cmd2/discussions
Actions https://github.com/python-cmd2/cmd2/actions
Projects https://github.com/python-cmd2/cmd2/projects
Security and quality https://github.com/python-cmd2/cmd2/security
Insights https://github.com/python-cmd2/cmd2/pulse
Sign up for GitHub https://github.com/signup?return_to=%2Fpython-cmd2%2Fcmd2%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2Fpython-cmd2%2Fcmd2%2Fissues%2Fnew%2Fchoose
tleonhardthttps://github.com/tleonhardt
mainhttps://github.com/python-cmd2/cmd2/tree/main
python-3.15https://github.com/python-cmd2/cmd2/tree/python-3.15
Conversation 1 https://github.com/python-cmd2/cmd2/pull/1604
Commits 5 https://github.com/python-cmd2/cmd2/pull/1604/commits
Checks 32 https://github.com/python-cmd2/cmd2/pull/1604/checks
Files changed 7 https://github.com/python-cmd2/cmd2/pull/1604/files
Fixed crash in Python 3.15.0a6 https://github.com/python-cmd2/cmd2/pull/1604/files#top
Show all changes 5 commits https://github.com/python-cmd2/cmd2/pull/1604/files
2587813 Fixed crash in Python 3.15.0a6 tleonhardt Mar 7, 2026 https://github.com/python-cmd2/cmd2/pull/1604/commits/2587813256b2d52bada81bf8428aa7e124e3cd08
3bb5d42 Ruggedize override so it would be safe on any version of Python and t… tleonhardt Mar 7, 2026 https://github.com/python-cmd2/cmd2/pull/1604/commits/3bb5d42ed7a9eaa8e5544cd274e2e63677af40b6
9d39c14 Add a common_prefix helper function in string_utils module tleonhardt Mar 7, 2026 https://github.com/python-cmd2/cmd2/pull/1604/commits/9d39c1444413758af52eeea818e17a3033ab1aad
2ff6640 Added tests to cover missing lines in argparse_custom.py tleonhardt Mar 7, 2026 https://github.com/python-cmd2/cmd2/pull/1604/commits/2ff6640814d77f94fdca97675f66861ec0732b63
5c1a274 Add GitHub Actions testing on Python 3.15-dev tleonhardt Mar 7, 2026 https://github.com/python-cmd2/cmd2/pull/1604/commits/5c1a2747dbe09ed92c270da3688121cd4cb14304
Clear filters https://github.com/python-cmd2/cmd2/pull/1604/files
Please reload this pagehttps://github.com/python-cmd2/cmd2/pull/1604/files
Please reload this pagehttps://github.com/python-cmd2/cmd2/pull/1604/files
tests.yml https://github.com/python-cmd2/cmd2/pull/1604/files#diff-1db27d93186e46d3b441ece35801b244db8ee144ff1405ca27a163bfe878957f
CHANGELOG.md https://github.com/python-cmd2/cmd2/pull/1604/files#diff-06572a96a58dc510037d5efa622f9bec8519bc1beab13c9f251e97e657a9d4ed
argparse_custom.py https://github.com/python-cmd2/cmd2/pull/1604/files#diff-cda20c32c93f85726f52d02d186e85d6e82d6b8a9921605022d8a1c9f5485a04
cmd2.py https://github.com/python-cmd2/cmd2/pull/1604/files#diff-325e1c8c92627fe81d6ef9f286b107ede43813bfdb4160425ca4f69c9e7ce08b
string_utils.py https://github.com/python-cmd2/cmd2/pull/1604/files#diff-cf61d228cd964e72ebd39803e921c26662031f143fb61aee4474405faa15eba3
test_argparse_custom.py https://github.com/python-cmd2/cmd2/pull/1604/files#diff-8dc5eab99e6e14c4350f60a2c11e14272264af688ba14586bd2e04ee7627c175
test_string_utils.py https://github.com/python-cmd2/cmd2/pull/1604/files#diff-492046b42bc03b5c29f2994a5d641d26b15c1e69f9a8f716365c026b27125f3d
https://github.com/python-cmd2/cmd2/blob/main/.github/CODEOWNERS#L15
.github/workflows/tests.ymlhttps://github.com/python-cmd2/cmd2/pull/1604/files#diff-1db27d93186e46d3b441ece35801b244db8ee144ff1405ca27a163bfe878957f
View file https://github.com/python-cmd2/cmd2/blob/5c1a2747dbe09ed92c270da3688121cd4cb14304/.github/workflows/tests.yml
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/python-cmd2/cmd2/pull/1604/{{ revealButtonHref }}
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-1db27d93186e46d3b441ece35801b244db8ee144ff1405ca27a163bfe878957f
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-1db27d93186e46d3b441ece35801b244db8ee144ff1405ca27a163bfe878957f
https://github.com/python-cmd2/cmd2/blob/main/.github/CODEOWNERS#L67
CHANGELOG.mdhttps://github.com/python-cmd2/cmd2/pull/1604/files#diff-06572a96a58dc510037d5efa622f9bec8519bc1beab13c9f251e97e657a9d4ed
View file https://github.com/python-cmd2/cmd2/blob/5c1a2747dbe09ed92c270da3688121cd4cb14304/CHANGELOG.md
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/python-cmd2/cmd2/pull/1604/{{ revealButtonHref }}
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-06572a96a58dc510037d5efa622f9bec8519bc1beab13c9f251e97e657a9d4ed
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-06572a96a58dc510037d5efa622f9bec8519bc1beab13c9f251e97e657a9d4ed
https://github.com/python-cmd2/cmd2/blob/main/.github/CODEOWNERS#L30
cmd2/argparse_custom.pyhttps://github.com/python-cmd2/cmd2/pull/1604/files#diff-cda20c32c93f85726f52d02d186e85d6e82d6b8a9921605022d8a1c9f5485a04
View file https://github.com/python-cmd2/cmd2/blob/5c1a2747dbe09ed92c270da3688121cd4cb14304/cmd2/argparse_custom.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/python-cmd2/cmd2/pull/1604/{{ revealButtonHref }}
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-cda20c32c93f85726f52d02d186e85d6e82d6b8a9921605022d8a1c9f5485a04
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-cda20c32c93f85726f52d02d186e85d6e82d6b8a9921605022d8a1c9f5485a04
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-cda20c32c93f85726f52d02d186e85d6e82d6b8a9921605022d8a1c9f5485a04
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-cda20c32c93f85726f52d02d186e85d6e82d6b8a9921605022d8a1c9f5485a04
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-cda20c32c93f85726f52d02d186e85d6e82d6b8a9921605022d8a1c9f5485a04
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-cda20c32c93f85726f52d02d186e85d6e82d6b8a9921605022d8a1c9f5485a04
https://github.com/python-cmd2/cmd2/blob/main/.github/CODEOWNERS#L32
cmd2/cmd2.pyhttps://github.com/python-cmd2/cmd2/pull/1604/files#diff-325e1c8c92627fe81d6ef9f286b107ede43813bfdb4160425ca4f69c9e7ce08b
View file https://github.com/python-cmd2/cmd2/blob/5c1a2747dbe09ed92c270da3688121cd4cb14304/cmd2/cmd2.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/python-cmd2/cmd2/pull/1604/{{ revealButtonHref }}
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-325e1c8c92627fe81d6ef9f286b107ede43813bfdb4160425ca4f69c9e7ce08b
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-325e1c8c92627fe81d6ef9f286b107ede43813bfdb4160425ca4f69c9e7ce08b
https://github.com/python-cmd2/cmd2/blob/main/.github/CODEOWNERS#L45
cmd2/string_utils.pyhttps://github.com/python-cmd2/cmd2/pull/1604/files#diff-cf61d228cd964e72ebd39803e921c26662031f143fb61aee4474405faa15eba3
View file https://github.com/python-cmd2/cmd2/blob/5c1a2747dbe09ed92c270da3688121cd4cb14304/cmd2/string_utils.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/python-cmd2/cmd2/pull/1604/{{ revealButtonHref }}
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-cf61d228cd964e72ebd39803e921c26662031f143fb61aee4474405faa15eba3
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-cf61d228cd964e72ebd39803e921c26662031f143fb61aee4474405faa15eba3
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-cf61d228cd964e72ebd39803e921c26662031f143fb61aee4474405faa15eba3
https://github.com/python-cmd2/cmd2/blob/main/.github/CODEOWNERS#L58
tests/test_argparse_custom.pyhttps://github.com/python-cmd2/cmd2/pull/1604/files#diff-8dc5eab99e6e14c4350f60a2c11e14272264af688ba14586bd2e04ee7627c175
View file https://github.com/python-cmd2/cmd2/blob/5c1a2747dbe09ed92c270da3688121cd4cb14304/tests/test_argparse_custom.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/python-cmd2/cmd2/pull/1604/{{ revealButtonHref }}
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-8dc5eab99e6e14c4350f60a2c11e14272264af688ba14586bd2e04ee7627c175
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-8dc5eab99e6e14c4350f60a2c11e14272264af688ba14586bd2e04ee7627c175
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-8dc5eab99e6e14c4350f60a2c11e14272264af688ba14586bd2e04ee7627c175
https://github.com/python-cmd2/cmd2/blob/main/.github/CODEOWNERS#L58
tests/test_string_utils.pyhttps://github.com/python-cmd2/cmd2/pull/1604/files#diff-492046b42bc03b5c29f2994a5d641d26b15c1e69f9a8f716365c026b27125f3d
View file https://github.com/python-cmd2/cmd2/blob/5c1a2747dbe09ed92c270da3688121cd4cb14304/tests/test_string_utils.py
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/python-cmd2/cmd2/pull/1604/{{ revealButtonHref }}
https://github.com/python-cmd2/cmd2/pull/1604/files#diff-492046b42bc03b5c29f2994a5d641d26b15c1e69f9a8f716365c026b27125f3d
Please reload this pagehttps://github.com/python-cmd2/cmd2/pull/1604/files
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.