-
Notifications
You must be signed in to change notification settings - Fork 0
feat: improved development workflow #59
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
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| root = true | ||
|
|
||
| [*] | ||
| indent_style = space | ||
| indent_size = 4 | ||
| end_of_line = lf | ||
| charset = utf-8 | ||
| trim_trailing_whitespace = true | ||
| insert_final_newline = true | ||
|
|
||
| [*.{yml,yaml,json,jsonc,toml}] | ||
| indent_size = 2 | ||
|
|
||
| [*.md] | ||
| trim_trailing_whitespace = false | ||
|
|
||
| [Makefile] | ||
| indent_style = tab |
File renamed without changes.
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,33 @@ | ||
| Fetch and address review comments from the most recent PR on the current branch. | ||
|
|
||
| ## Execution policy | ||
|
|
||
| - Run all `gh` commands (or equivalent GitHub MCP calls) immediately without asking for confirmation. | ||
| - Do **not** start code edits until after presenting a full comment assessment and getting explicit user confirmation. | ||
|
|
||
| ## Workflow | ||
|
|
||
| 1. **Get the PR number:** `gh pr view --json number --jq .number` | ||
| 2. **Get review comments:** | ||
| Use the GitHub MCP to fetch PR review comments: | ||
| ```bash | ||
| gh pr view --json reviews --jq '.reviews[] | {author: .author.login, body, state}' | ||
| gh pr view --json comments --jq '.comments[] | {author: .author.login, body, path, line}' | ||
| gh api repos/{owner}/{repo}/pulls/{number}/comments --jq '.[] | {path, line, body, user: .user.login}' | ||
| ``` | ||
| 3. **List all comments first (no edits yet):** | ||
| - Produce a complete checklist of every review comment. | ||
| - For each item include: | ||
| - **Assessment:** valid / duplicate / not applicable | ||
| - **Suggestion:** exact fix you plan to apply (or why you will skip) | ||
| 4. **Ask for confirmation:** | ||
| - Share the full checklist with the user. | ||
| - Ask for explicit confirmation before implementing any code/document changes. | ||
| 5. **After confirmation, implement valid changes**, then run the check suite: | ||
| ```bash | ||
| source .venv/bin/activate && pytest tests/ -x -q && ruff check --fix . && ruff format --check . && mypy . | ||
| ``` | ||
| 6. **Commit strategy:** | ||
| - **Trivial fixes** (typos, naming, small refactors): `git add -A && git commit --amend --no-edit && git push --force-with-lease` | ||
| - **Substantive changes** (new tests, logic changes, API modifications): `git add -A && git commit -m "fix: address PR feedback — <summary>" && git push` | ||
| 7. **NEVER** force-push to `main` or any shared branch — only the current feature branch |
File renamed without changes.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| { | ||
| "recommendations": [ | ||
| "ms-python.python", | ||
| "ms-python.vscode-pylance", | ||
| "charliermarsh.ruff", | ||
| "tamasfe.even-better-toml", | ||
| "GitHub.copilot", | ||
| "GitHub.copilot-chat" | ||
| ] | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,41 @@ | ||
| { | ||
| "version": "0.2.0", | ||
| "configurations": [ | ||
| { | ||
| "name": "Streamlit App", | ||
| "type": "debugpy", | ||
| "request": "launch", | ||
| "module": "streamlit", | ||
| "args": ["run", "immermatch/app.py"], | ||
| "cwd": "${workspaceFolder}", | ||
| "env": {}, | ||
| "justMyCode": true | ||
| }, | ||
| { | ||
| "name": "pytest: Current File", | ||
| "type": "debugpy", | ||
| "request": "launch", | ||
| "module": "pytest", | ||
| "args": ["${file}", "-x", "-v"], | ||
| "cwd": "${workspaceFolder}", | ||
| "justMyCode": false | ||
| }, | ||
| { | ||
| "name": "pytest: All Tests", | ||
| "type": "debugpy", | ||
| "request": "launch", | ||
| "module": "pytest", | ||
| "args": ["tests/", "-x", "-v"], | ||
| "cwd": "${workspaceFolder}", | ||
| "justMyCode": false | ||
| }, | ||
| { | ||
| "name": "Daily Task", | ||
| "type": "debugpy", | ||
| "request": "launch", | ||
| "program": "${workspaceFolder}/daily_task.py", | ||
| "cwd": "${workspaceFolder}", | ||
| "justMyCode": true | ||
| } | ||
| ] | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change | ||||
|---|---|---|---|---|---|---|
| @@ -0,0 +1,46 @@ | ||||||
| .PHONY: check test lint coverage format typecheck run install install-dev clean | ||||||
|
|
||||||
| SHELL := /bin/bash | ||||||
|
|
||||||
| ## Run the full check suite (test + lint + format + typecheck) | ||||||
| check: | ||||||
| source .venv/bin/activate && pytest tests/ -x -q && ruff check --fix . && ruff format --check . && mypy . | ||||||
|
|
||||||
| ## Run tests only | ||||||
| test: | ||||||
| source .venv/bin/activate && pytest tests/ -x -q | ||||||
|
|
||||||
| ## Run tests with coverage | ||||||
| coverage: | ||||||
| source .venv/bin/activate && pytest tests/ --cov=immermatch --cov-report=term-missing | ||||||
|
|
||||||
| ## Lint with ruff (auto-fix) | ||||||
| lint: | ||||||
| source .venv/bin/activate && ruff check --fix . | ||||||
|
||||||
| source .venv/bin/activate && ruff check --fix . | |
| source .venv/bin/activate && ruff check --fix . && ruff format --check . |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The
make lintdescription here says it runs bothruff check --fixandruff format --check, but the newly added Makefile’slinttarget only runsruff check --fix. Update this table or the Makefile so they match.