Skip to content

feat: Assorted small improvements#135

Open
doismellburning wants to merge 6 commits intomainfrom
feat/small-improvements
Open

feat: Assorted small improvements#135
doismellburning wants to merge 6 commits intomainfrom
feat/small-improvements

Conversation

@doismellburning
Copy link
Copy Markdown
Owner

  • Expand .gitignore to cover common Python artifacts
  • Add RUF, PT, SIM, PERF, LOG to ruff lint rules
  • Add make clean target to remove generated coverage artifacts
  • Add workflow_dispatch trigger and concurrency cancellation to CI
  • Set .DEFAULT_GOAL to check so bare make runs a more useful target
  • Add py.typed marker for PEP 561 type annotation support

doismellburning and others added 6 commits April 3, 2026 16:15
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
PEP 561 defines how packages signal they ship inline type annotations.
Without a py.typed marker file, type checkers (mypy, pyright, etc.)
will silently ignore a package's type annotations when it is installed
as a dependency, even if the source contains full type hints.

The marker is an empty file; its presence is the signal. Adding it
declares this package as "typed" so that downstream projects benefit
from type checking against the package's annotations.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings April 3, 2026 15:16
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR makes small developer-experience and CI improvements for the Python template project, including expanded ignore rules, stricter Ruff linting, a new make clean target, CI workflow concurrency controls, and shipping a py.typed marker for PEP 561 typing support.

Changes:

  • Expand .gitignore to cover common Python build/venv/cache artifacts.
  • Tighten Ruff lint rules by enabling additional rule families (RUF/PT/SIM/PERF/LOG).
  • Improve automation via make defaults/clean target and CI workflow dispatch + concurrency cancellation.

Reviewed changes

Copilot reviewed 3 out of 5 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/python_template/py.typed Adds PEP 561 marker file to the package.
pyproject.toml Enables additional Ruff lint rule families.
Makefile Sets default goal to check and adds clean target.
.gitignore Adds common Python artifact ignores.
.github/workflows/test.yml Adds workflow_dispatch trigger and concurrency cancellation.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.


.PHONY: clean
clean:
git clean -X
Copy link

Copilot AI Apr 3, 2026

Choose a reason for hiding this comment

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

The clean target runs git clean -X without -f, so it will typically do a dry-run and not actually remove anything (most Git configs require force for git clean). Consider adding the appropriate force/dir flags or using explicit rm -rf of the generated artifacts you want to clean.

Suggested change
git clean -X
git clean -fdX

Copilot uses AI. Check for mistakes.
Comment on lines +31 to +33
.PHONY: clean
clean:
git clean -X
Copy link

Copilot AI Apr 3, 2026

Choose a reason for hiding this comment

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

PR description says the clean target removes generated coverage artifacts, but git clean -X removes all ignored files in the repo (including things like /.venv/ per .gitignore). This is broader and potentially surprising/destructive for local dev. Consider restricting clean to the specific coverage outputs (e.g., .coverage, htmlcov/, etc.) or documenting that it nukes all ignored files.

Copilot uses AI. Check for mistakes.
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