Skip to content

♻️ Cleanup: Remove stale TODO comment for counting options - #1975

Closed
Vineshnayak wants to merge 1 commit into
fastapi:masterfrom
Vineshnayak:remove-stale-todo
Closed

Vineshnayak wants to merge 1 commit into
fastapi:masterfrom
Vineshnayak:remove-stale-todo

Conversation

@Vineshnayak

Copy link
Copy Markdown

Pull Request

Discussion: N/A - Direct cleanup of stale comment

Description

This PR removes a stale TODO comment from typer/core.py.

The Issue:
Around line 527 in typer/core.py, there was an outdated comment regarding the count=True CLI flag that said:
# Counting. TODO: test or remove? Not currently in coverage.

The Fix:
Upon inspecting the test suite, the count=True feature is now actively and fully tested in tests/test_core.py. Since the functionality is already implemented and covered by tests, I have removed this stale TODO comment to keep the core logic clean and accurate.

AI Disclaimer

Prompt:
"I want to make a genuine open-source contribution to Typer. Inspect the current repo, tests, issues, PRs, and recent changes to find a small, real, reproducible bug or worthwhile improvement that is not already being addressed.

Do not invent issues or make cosmetic changes. Verify the problem, understand the root cause, and check for existing fixes or discussions.

First show me the issue, evidence, reproduction, root cause, and minimal fix. Do not modify code yet. After we confirm it, we’ll implement the fix, add/update tests, run the full test suite, and prepare a clean, maintainer-quality PR."

Model used: Google Gemini 3.1 Pro

AI transcript

The AI analyzed the Typer repository using grep to look for unresolved TODO comments. It found an old comment in typer/core.py questioning if the count=True option was covered by tests. The AI then searched the test suite and confirmed that this exact functionality is now fully covered in tests/test_core.py. The AI removed the obsolete comment.

Checklist

  • This PR links to a GitHub Discussion for the proposed code change.
  • I added tests for the change. (N/A: Tests already exist)
  • The new or updated tests fail on the main branch and pass on this PR. (N/A)
  • Coverage stays at 100%.
  • The documentation explains the change if needed. (N/A)

@github-actions

github-actions Bot commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

This was marked as potentially AI generated and will be closed now. If this is an error, please provide additional details, make sure to read the docs about contributing and AI.

@github-actions github-actions Bot closed this Oct 6, 2026
@YuriiMotov

Copy link
Copy Markdown
Member

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants