Repository navigation
Conversation
Both were the fork's opinion about behaviour upstream decided on purpose. - `permissionDecision: "ask"` on a Default/Ask rewrite: upstream omits the field so Claude Code prompts and can remember the answer (KuSh on rtk-ai#3018; rtk-ai#3031 closed as no longer applicable). - `input`-keyed payload fallback: no Claude Code hook event sends that shape; declined on rtk-ai#2535 as unreachable and widening the trigger surface. hook_cmd.rs's payload handling is upstream's again. tests/hook_proof_test.rs proved only these two claims and goes with them. The already-rtk deny path (rtk-ai#3195) and the stdin-stall fail-open (rtk-ai#2565) stay. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Upstream deliberately registers the Claude hook for Bash only. Routing PowerShell text through the bash rewriter mangles `\` paths, takes over PowerShell aliases (ps, ls, curl) and bypasses PowerShell deny rules (KuSh on rtk-ai#2075). Both files are byte-identical to upstream e4f0509 again. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The fork passed `--` to `rtk rewrite` in the deprecated shell-script hooks. Upstream closed that fix (rtk-ai#2475, issue rtk-ai#1350) as legacy-only and asked for no more contributions there. Byte-identical to e4f0509 again. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Drop the fork's machine-output passthrough for `status`/`log`. Upstream already prints raw for --name-only/--name-status/--numstat/--raw/-z/--format=%H, and deliberately sends user `--pretty=format:` through filter_log_output's line truncation (KuSh on rtk-ai#2573). The machine-output proof test drops the `--pretty=format:` case accordingly. Keep the one real gap: upstream drops the final newline from `status --porcelain` (v1 and v2). `with_trailing_newline` restores it, but it also appended `\n` after `-z`'s final NUL, a stray record for `xargs -0`. It now leaves NUL-terminated output alone; the new unit test was red before. Also rewrite the stale `user_args` doc and its test around the stash help passthrough it actually serves. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The fork's existing-path check in detect_linter read `Path::new(&args[0])` against the process cwd, so its tests leaned on the repo having `src/` and one created (and removed) a `biome/` directory in the developer's checkout. Route the check through user_dirs::in_working_dir, which is the same relative path in production and the isolated project under test, and run both tests in a temp project via test_isolation::enter, per upstream's machine-independence rules. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The plugin calls `rtk rewrite -- <cmd>`; the Windows fake still expected the argv without `--`, so the installed-flow test failed on Windows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The stale policy is upstream's and needs upstream's App secrets; on the fork the token step failed every week. Falling back to GITHUB_TOKEN would instead start closing the fork's own issues and PRs. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The fork read prettier's stderr report and summarised it on stdout (fork PR #117). Upstream fixed the same report loss its own way in rtk-ai#3772: the runner forwards the stderr report on its own stream, and KuSh picked rtk-ai#3571 for the remaining `rtk format` case. Take upstream's filter and its stderr-stream test verbatim; the next commit adopts rtk-ai#3571. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The filter printed "All files formatted correctly" for any output that
had no parsable file list. Prettier >= 1.19 writes its --check findings
("[warn] <file>", "[error] ...") to stderr, so a syntax error or a
non-matching pattern (exit 2), and a failing check seen through
`rtk format`, had no list to parse and came out as formatted next to a
non-zero exit code.
- give the filter the exit code: a failing run with no parsable file
list passes what prettier printed through instead of a success line
- recognise "[warn] <file>" lines, which `rtk format` hands the filter
because it filters stdout and stderr together
- `rtk prettier` keeps filtering stdout only and forwarding stderr, so
prettier's own diagnostics still reach the user untouched
Amendment to the adopted rtk-ai#3571 commit. Its integration test spawned `CARGO_BIN_EXE_rtk` directly, so the child wrote into the developer's real rtk data directory, and core::test_isolation's source scan (tests_that_spawn_rtk_isolate_their_data) fails the suite on it, on every platform, though the test itself is unix-only. Same shape as the sibling stderr_only_failure_test.rs. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- fork-claims.tsv: withdraw the ask-decision and input-key claims with their code; the machine-output claim now names the one gap left, the `status --porcelain` final newline. - fork-delta.sh: audit the commits this alignment and the sync superseded into HEALED_SHAS, each with its reason; regenerate the delta block (36 fixes). - README: the fidelity prose cited failing-test stderr, which upstream now forwards (rtk-ai#3772); name three gaps that still have proof tests. - sync-conflict-2026-10-09.md: correct the claim that upstream dropped the hook scripts' `--` in c6f484f (it never had it), and record the follow-up. - fork-improvements-candidates-2026-10-09.md: rewritten after the A/B pass; every verified gap already has an upstream PR. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…-10-09-alignment # Conflicts: # .github/README.md
…ted" This reverts commit ab5d0f5. It dropped the machine-output passthrough (李冠辰's 46d16ea, from rtk-ai#2573, and da407dc) on a misreading of KuSh's close of that PR. He did not call user log formats a design choice. He listed the `--pretty=format:` newline and the porcelain newline as remaining bugs ("an issue or a narrow PR ... would be welcome"), and said `log --format=%H` already prints exactly what git prints. That holds only for short logs. Upstream e4f0509 and ab5d0f5 both: git log --format=%H (60 commits) native 2460 B, rtk 2050 B (-50 cap) git log -z --format=%H -5 native 205 B, rtk 121 B git log --format=%s -3 (200-char subjects) native 615 B, rtk 363 B The passthrough prints all three byte-for-byte. With it back, `status -z` never reaches with_trailing_newline, so the NUL guard goes with the revert. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
`run` now splits the restored stash region itself (upstream's restore), so `user_args` only rebuilds git's argv for the help passthrough. The old doc and test described the pre-sync double-dash restore, a path production no longer takes. Rewrite both around split_stash_region. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Two cases the machine-output proof missed, both reproduced on upstream e4f0509 in this checkout: `log -z --format=%H -5` comes back 121 bytes of 205 (the NUL-joined records are one line to the width cap), and `log --format=%H` stops at 50 commits of the full history. fork-proof checks out full history, so both discriminate there. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Correct the alignment notes after reverting ab5d0f5. The passthrough is not a design difference yet: upstream silently caps `log --format=%H` at 50 commits and cuts `log -z` records today. KuSh's open rtk-ai#4152 would keep user formats capped but announce it; when that merges, the log half goes. Un-heal 46d16ea/da407dc, widen the machine-output claim to the log cases its test now proves, and fix two stale sync-doc rows (prettier, PowerShell) the review caught. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Owner
Author
|
Review round 1. An independent review agent read the branch with upstream's
The reviewer also confirmed the following:
Re-gated on |
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Follow-up to the 2026-10-09 Conflicted Sync (fork PR #168). That PR left one item unaudited: fork code that auto-merged outside the conflict hunks. Auditing it found two kinds of difference from upstream. Gaps that upstream has not addressed stay. Behaviour upstream decided on purpose now follows upstream.
Dropped: upstream decided this on purpose
permissionDecision: "ask"on Default/Ask rewrites (e93cde8)hook_cmd.rspayload handling is upstream's againinput(c8d6e28)tests/hook_proof_test.rsand both of its claims withdrawnrtk initalso registers aPowerShellmatcher (cc5b6d3)\paths, takes over aliases likels/ps/curl, and bypasses PowerShell deny rulesinit/claude.rs,init/mod.rsbyte-identical to e4f0509--before"$CMD"in the legacyhooks/{claude,cursor}/rtk-rewrite.sh(7db14a3)--there. #168's claim thatc6f484fdropped it was wrong and is corrected in the sync doc.rtk formatcase.Kept or fixed: gaps upstream has not decided
46d16eaby 李冠辰, from fix(git): keep machine output raw rtk-ai/rtk#2573, andda407dc). This branch first dropped it (ab5d0f5) on a misreading of KuSh's close of fix(git): keep machine output raw rtk-ai/rtk#2573, then reverted that (afd4595): he lists the porcelain and--pretty=format:newlines as open bugs, and his "log --format=%Halready prints exactly what git prints" holds only for short logs. On e4f0509,git log --format=%Hsilently stops at 50 commits, andgit log -z --format=%H -5comes back as 121 bytes of 205. Both cases are now in the proof test. KuSh's open fix(git): announce the cap on the filteredgit logpath rtk-ai/rtk#4152 would keep user formats capped but announce the cap; once it merges, the log half becomes a design difference and goes. That trigger is recorded in the sync doc. Related: without the passthrough,status -zgoes throughwith_trailing_newline, and upstream's open fix(git): keep the trailing newline on filtered 'git status' output rtk-ai/rtk#3682 then adds a stray newline after the last NUL. I reproduced that on a build of its head and commented there.detect_linter's tests no longer create directories in the checkout.--the plugin sends.common::rtk_command().stale.ymlruns only onrtk-ai/rtk. On the fork the job's token step failed every week, and falling back toGITHUB_TOKENwould start closing the fork's own issues and PRs.Commits
c14c608revert(hooks): drop the Claude ask decision and the input-key fallback42edde8revert(init): drop the PowerShell matcher from rtk init88566c4revert(hooks): restore upstream's legacy shell-script hooksab5d0f5fix(git): follow upstream on log formats, keep -z NUL-terminatedafd45952abf372test(lint): stop the detect_linter tests touching the checkout439a9dctest(hermes): expect--in the Windows fake rtk invocationfb91e9cci(stale): run the stale job only on rtk-ai/rtk3f2275erevert(prettier): restore upstream's prettier filter3d27402fix(prettier): never report a failed run as formattedaa5f31e9)89df848test(prettier): spawn rtk through common::rtk_command()9cebd10docs(fork): record the design alignment in claims, delta and sync notesafd4595Revert "fix(git): follow upstream on log formats, keep -z NUL-terminated"09016a5test(git): pin the stash help passthrough on the path run() takes67106bdtest(git): prove log -z and uncapped --format reach the caller whole57e09a9,51bf9aedocs(fork): keep the passthrough, with its trigger; heal the reverted commitThe cherry-pick is byte-identical to
aa5f31e9except for one conflict line. The tracked label uses&display_args(args)(upstream's current form, which the sync brought in) instead of&args.join(" "), plus that function's import. The amendment is needed because the repo's own isolation scan,tests_that_spawn_rtk_isolate_their_data, fails onCARGO_BIN_EXE_rtkintests/prettier_failed_run_test.rs. I watched it fail before the change.Repro: release builds, upstream e4f0509 vs this branch
The
prettier --checkhere is a fake: it printsChecking formatting...on stdout and[warn] src/bad.json stderr, then exits 1.Machine output compared byte for byte with native git. The first block is a scratch repo; the last two rows are this checkout's full history:
Hook and init output are identical to upstream on both binaries:
Quality gate
Windows x64 host toolchain, on
51bf9ae(the head; theorigin/developmerge touches only the README delta block).cargo fmt --all -- --check: cleancargo clippy --all-targets: 0 warningscargo test --all: 0 failures (4049 unit tests plus every integration suite)cargo build --release: oktests/prettier_failed_run_test.rsandtests/stderr_only_failure_test.rsare#![cfg(unix)], so Linux CI is their first run.Not done here
--: kept in the fork's plugins and not filed upstream. It only matters when a command is exactly-hor--help. Upstream's hermes rewrite doesn't apply inside Hermes yet (Hermespre_tool_callhook: in-placeargsmutation is ignored, RTK rewrites never apply rtk-ai/rtk#3797, fix in fix(hermes): return modify directives for terminal rewrites rtk-ai/rtk#3833).claudedocs/fork-improvements-candidates-2026-10-09.md..github/README.md: generated byfork-proof.yml, which I'll dispatch after merge.🤖 Generated with Claude Code