Skip to content

Expanded subcommand management API.#1663

Merged
kmvanbrunt merged 4 commits into
mainfrom
update_subcommand_api
May 14, 2026
Merged

Expanded subcommand management API.#1663
kmvanbrunt merged 4 commits into
mainfrom
update_subcommand_api

Conversation

@kmvanbrunt
Copy link
Copy Markdown
Member

  1. Detaching a subcommand returns metadata for easily reattaching later
  2. Added ability to remove all subcommands of a given command

1. Detaching a subcommand returns metadata for easily reattaching later
2. Added ability to remove all subcommands of a given command
@kmvanbrunt kmvanbrunt requested a review from tleonhardt as a code owner May 14, 2026 15:52
@codecov
Copy link
Copy Markdown

codecov Bot commented May 14, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.53%. Comparing base (5b3bc53) to head (ced8042).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1663      +/-   ##
==========================================
- Coverage   99.55%   99.53%   -0.02%     
==========================================
  Files          22       22              
  Lines        4889     4934      +45     
==========================================
+ Hits         4867     4911      +44     
- Misses         22       23       +1     
Flag Coverage Δ
unittests 99.53% <100.00%> (-0.02%) ⬇️

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

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

tleonhardt
tleonhardt previously approved these changes May 14, 2026
Copy link
Copy Markdown
Member

@tleonhardt tleonhardt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The test_proc_reader_terminate test is failing due to a timeout specifically for Window and Python 3.10. It may be a one-off fluke or it might not be.

I don't think I'd worry about it for this PR unless you have insight into what might be causing it.

We talked earlier today about dropping support for Python 3.10 in the upcoming 4.0.0 release and I am fully in support of that. I think we should do that in a separate PR.

Comment thread cmd2/cmd2.py
tleonhardt
tleonhardt previously approved these changes May 14, 2026
@kmvanbrunt kmvanbrunt changed the title Expanded subcommand API. Expanded subcommand management API. May 14, 2026
@kmvanbrunt kmvanbrunt merged commit 211a3b1 into main May 14, 2026
32 of 33 checks passed
@kmvanbrunt kmvanbrunt deleted the update_subcommand_api branch May 14, 2026 23:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants