revert: last 2 commit(s) on master (code-review demo)#2
Conversation
kramlipi
left a comment
There was a problem hiding this comment.
Automated code review by kramlip code-agent.
Review notes from kramlip code-agent (@kramlipi_code_review_bot) — grounded scanners + critic, not a rubber stamp.
| @@ -102,7 +102,6 @@ type Router interface { | |||
| Patch(pattern string, h http.HandlerFunc) | |||
There was a problem hiding this comment.
Should fix · api_break · chi.go:102 · Removal of Query method from Router interface
What: The Query method has been removed from the Router interface and Mux implementation.
Why it matters: This is a breaking change for any users relying on r.Query(...) to handle HTTP QUERY requests. While RFC 10008 is relatively new, removing it without a deprecation cycle or clear migration path (other than MethodFunc) forces immediate refactoring on consumers.
Do this: If this removal is intentional, ensure it is documented in the release notes and consider if a deprecation period was possible.
Suggestion:
| Patch(pattern string, h http.HandlerFunc) | |
| Keep the method but mark it as deprecated if removal is necessary. |
Callers that may care:
_examples/custom-method/main.go:11→RegisterMethod—chi.RegisterMethod("LINK")_examples/custom-method/main.go:12→RegisterMethod—chi.RegisterMethod("UNLINK")_examples/custom-method/main.go:13→RegisterMethod—chi.RegisterMethod("WOOHOO")CHANGELOG.md:244→RegisterMethod—- New chi.RegisterMethod(method) to add support for custom HTTP methods, see _examples/custom-methodCHANGELOG.md:245→RegisterMethod—- Deprecated LINK and UNLINK methods from the default list, please usechi.RegisterMethod("LINK")
| steps: | ||
| - name: Install Go | ||
| uses: actions/setup-go@40f1582b2485089dde7abd97c1529aa768e1baff # v5 | ||
| uses: actions/setup-go@v5 |
There was a problem hiding this comment.
Worth a look · consistency · .github/workflows/ci.yml:30 · PR title/diff inconsistency
What: PR title emphasizes topics that do not appear in changed paths or added code (code, demo, last, master, revert, review).
Why it matters: Align the message or the diff. (scanner:commit_consistency)
Do this: Either fix it in this PR, or reply here explaining why the current behavior is intentional.
Evidence: title='revert: last 2 commit(s) on master (code-review demo)'; missing_in_diff=['code', 'demo', 'last', 'master', 'revert', 'review']
Callers that may care:
_examples/custom-method/main.go:11→RegisterMethod—chi.RegisterMethod("LINK")_examples/custom-method/main.go:12→RegisterMethod—chi.RegisterMethod("UNLINK")_examples/custom-method/main.go:13→RegisterMethod—chi.RegisterMethod("WOOHOO")CHANGELOG.md:244→RegisterMethod—- New chi.RegisterMethod(method) to add support for custom HTTP methods, see _examples/custom-methodCHANGELOG.md:245→RegisterMethod—- Deprecated LINK and UNLINK methods from the default list, please usechi.RegisterMethod("LINK")
| @@ -221,7 +221,6 @@ type Router interface { | |||
| Patch(pattern string, h http.HandlerFunc) | |||
There was a problem hiding this comment.
Worth a look · consistency · README.md:221 · No blast-radius risk
What: The changes remove the Query method.
Why it matters: While this is an API break, the blast radius is limited to users of the Query method. A search of the provided codebase shows no internal callers of r.Query in the examples or tests (other than the test being deleted).
Callers that may care:
_examples/custom-method/main.go:11→RegisterMethod—chi.RegisterMethod("LINK")_examples/custom-method/main.go:12→RegisterMethod—chi.RegisterMethod("UNLINK")_examples/custom-method/main.go:13→RegisterMethod—chi.RegisterMethod("WOOHOO")CHANGELOG.md:244→RegisterMethod—- New chi.RegisterMethod(method) to add support for custom HTTP methods, see _examples/custom-methodCHANGELOG.md:245→RegisterMethod—- Deprecated LINK and UNLINK methods from the default list, please usechi.RegisterMethod("LINK")
| @@ -26,17 +26,11 @@ const ( | |||
| mPATCH | |||
There was a problem hiding this comment.
Worth a look · design · tree.go:26 · Removal of mQUERY constant
What: The mQUERY constant and its associated mapping logic were removed.
Why it matters: This reduces the internal support for the QUERY method. If users still need to support QUERY via MethodFunc, they must now manually manage the string constant, which is more error-prone than using the library's internal constants.
Do this: Confirm that the removal of mQUERY is consistent with the project's long-term support strategy for newer HTTP methods.
Callers that may care:
_examples/custom-method/main.go:11→RegisterMethod—chi.RegisterMethod("LINK")_examples/custom-method/main.go:12→RegisterMethod—chi.RegisterMethod("UNLINK")_examples/custom-method/main.go:13→RegisterMethod—chi.RegisterMethod("WOOHOO")CHANGELOG.md:244→RegisterMethod—- New chi.RegisterMethod(method) to add support for custom HTTP methods, see _examples/custom-methodCHANGELOG.md:245→RegisterMethod—- Deprecated LINK and UNLINK methods from the default list, please usechi.RegisterMethod("LINK")
Review notes4 note(s) — 0 must-fix · 1 should-fix · 3 worth a look · 1 from deterministic scanners Themes: consistency (2), api_break (1), design (1) Start here:
Review notes from kramlip code-agent (@kramlipi_code_review_bot) — grounded scanners + critic, not a rubber stamp. |
Summary
Automated revert of the last 2 non-merge commit(s) on
masterfor akramlipi code-agent code-review receipt.
Reverted
caf87e6efeat(mux): support http QUERY method ietf rfc10008 (feat(mux): support http QUERY method ietf rfc10008 go-chi/chi#1132)8b258c7bci: pin GitHub Actions to full commit SHAs (ci: pin GitHub Actions to full commit SHAs go-chi/chi#1116)Notes
scripts/gtm/revert_mr_review.py.— kramlipi · cluevion@gmail.com · https://kramlipi.com · https://kramlipi.github.io