Repository navigation
Fix five small browse and question-hook bugs - #4192
Merged
Merged
Conversation
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Review-Finding: p1/targeted#1 reader=targeted Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Review-Finding: p2/outside-voice#1 reader=outside-voice Review-Finding: p2/adversarial-native#1 reader=adversarial-native Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
…angelog Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
|
😎 This pull request was merged. |
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.
This fixes five small bugs in gstack's browser commands and its question hooks, so
browse scroll, the PDF and diagram renderer, per-project domain skills and never-ask preferences behave the way the docs say. It serves the README's goal of skills a person can rely on without babysitting.What changed
A question marker with a malformed signal hint used to lose its id (left, main); it now keeps the lowercased id and drops only the bad hint (right).
Before/after as text: A question marker with a malformed signal hint used to lose its id (left, main); it now keeps the lowercased id and drops only the bad hint (right)
browse scroll <selector>keeps its selector when--waitis absent. The old parser read the first argument as the--waitvalue, soscroll footerscrolled to the page bottom (browse/src/write-commands.ts).browseon PATH whose real file has another name, such as Debian and Ubuntu's/usr/bin/browselink to xdg-open, instead of launching a desktop opener (lib/aside-render.ts).~/.claude, the browse daemon gives each project its own domain-skill file. It tries the checkout's owngstack-slug, then the Claude install's, then the git remote rule, instead of one shared "unknown" bucket (browse/src/project-slug.ts).;signal=hint keeps its id and drops only the hint (scripts/qid-marker.ts).Why
Each fix comes from a bug the crew hit: "scroll footer" replied "Scrolled to bottom", a Debian machine opened a desktop app instead of rendering, a Codex install mixed every repository's domain skills, and a silenced question was asked again because its marker had capitals or a bad hint. After this, those commands and preferences do what they say. Review found that widening the marker pattern let text inside a marker skip the one-way door check, so two follow-up commits keep that text in the check, spaced apart from the next word.
Blast radius
The scroll parser, the PATH lookup and the slug lookup are each one function with their own tests. The marker change reaches both Claude hooks through
parseQidMarker, and the never-ask gate and the spawned deny path now classify the marker's tail text too, so any change there only makes the hook ask more often; the red/green tests in test/question-preference-hook.test.ts and a probe ofclassifyQuestionshowed that (script ran). Security read: the slug fix runs a localgstack-slugscript (the checkout's ownbin/gstack-slug, then~/.claude's) throughexecFileSyncwith no shell and a 2 s timeout; there is no network use, no credentials, and no install, upgrade or workflow change. One small risk in fix 2: a PATH wrapper whose real file has another name is now skipped, and the renderer reports that no browser was found.Summary
Five one-commit bug fixes, each with a test that fails on main, plus two review fixes to the one-way door check and a docs note on where domain skills live. This is crew work.
Test Coverage
Coverage: deterministic (each of 5 changed runtime files has a changed test naming it; no audit reader).
Regression proof: each fix's test fails on main 10fc9b1 and passes on this branch. The two review-fix tests failed on the hook before each fix and pass after it.
Tests ran: free (carried from CI; see Test plan)
Pre-Landing Review
Pass 1 (full panel, gate class): 3 issues — 0 auto-fixed, 2 asked (0 fixed, 2 skipped), 0 deferred, 1 noted. The Step 11 targeted reader found one blocker, fixed in "Keep a marker's tail in the one-way door check". Pass 2 (full panel on the range): clean, 3 notes. Its Step 11 voices found one blocker in that fix (the tail joined the next word), fixed in "Keep a marker's tail apart from the next word in the one-way door check" and checked by one granted fix-check reader plus the targeted reader: no findings.
Gate edits: none detected (7 listed, 2 read; patterns: RH-1,RH-3,RH-4,RH-12,RH-13,RH-14,RH-15,RH-16; unlisted idioms: none)
Outside review: openai/gpt-6.1-sol as a host subagent. Pass 1: VERDICT: CLEAN. Pass 2: one finding, fixed.
Review notes
Below the blocking floor; recorded here and not fixed in this PR. Follow-ups:
<gstack-qid:adhoc-x> Proceed?withA) Force-push to main (recommended), or an unregistered id likeforce-push-main, can still auto-decide under a never-ask preference. This already happens on main; it is the same class as the fixed tail bug.qTextat :475 and :517).gstack-slugruns (native Windows, or a 2 s timeout), the slug fallback usesgetRemoteSlug()rather thanslugFromEnvironment()from lib/bin-context.ts, so it ignores.gstack-projectmarkers and the outer-root walk; no test reaches that branch.~/.gstack/projects/unknown/learnings.jsonl; the changelog and docs/domain-skills.md say so, and nothing moves them.browseon PATH and checks only its file name.Exploratory QA
Functional smoke (report-only, 3 of 12 probes, 300 s budget): all pass on current inputs. The qid marker keeps the lowercased id with a malformed hint and keeps a valid hint; a PATH
browselinked to xdg-open resolves to nothing while a realbrowsestill resolves; with no~/.claude, a repository with origin acme/widgets gets the slugacme-widgets. Not run live:browse scroll(needs a browser; covered by browse/test/commands.test.ts) and the never-ask hook end to end (covered by its tests).Design Review
No frontend files changed — design review skipped.
Eval Results
No prompt-related files changed — evals skipped. eval:select's dependents profile lists probes through scripts/qid-marker.ts references; none were run.
Scope Drift
Scope Check: CLEAN
Plan Completion
Plan completion audit: not run (no plan is bound to this branch and no docs/designs/ file matches). Bug fixes skip plan review; each carries a failing-first test.
Verification Results
No plan verification items. Exploratory smoke: 3 PASS, 0 FAIL, 0 BLOCKED.
TODOS
Completed: the plan-tune qid marker follow-ups item (#3442 review notes) is removed from TODOS.md, since fixes 4 and 5 ship it.
Documentation
Status: updated. One factual edit, no blockers.
Scope: base 10fc9b1 to head 67df822 on
five-small-browse-and-question-hook-fixes(8 commits, 12 files: browse scroll parsing, the PATH browse check in the renderer, per-project browse slug, qid-marker hint parsing, and never-ask hook id lowercasing). There were no staged, unstaged or untracked changes.Documentation health:
docs/domain-skills.md: Updated. Storage now says how the project slug is resolved and where rows saved by older builds sit (projects/unknown).BROWSER.md: Current. The scroll command row matches the fixed behavior.browse/sections/command-list.md: Current.ARCHITECTURE.md: Current. It does not describe the PATH browse lookup.changelog.d/five-small-browse-and-question-hook-fixes.md: Reviewed and consistent with the code; not edited.TODOS.md: Reviewed. The removed qid-marker item matches the fix; not edited.Coverage debt: no critical gaps. One common gap: the renderer rule that skips a PATH
browsewhose real file has another name (for example Debian and Ubuntu's xdg-open link) is documented only in source comments and the changelog. The qid-marker and hook changes are internal. There is no architecture diagram drift.Test plan
bun run test(free suite): carried from Free Tests run 42570140462 at this tree (tree bfc52c392e04, head 79b69fe), 1651 files, exit 0 (EVIDENCE: FRESH).bun --no-env-file test test/question-preference-hook.test.ts test/qid-marker.test.ts test/hook-log.test.ts: 55 pass, 0 fail.bun run typecheck: exit 0.This is crew work by the GStack Minder crew (GSTA-429).
Agent notes
Refs GSTA-429
Refs p1/targeted#1
Refs p2/adversarial-native#1
Refs p2/outside-voice#1
Approvals
Approved: yes (record r-062a94bcd83d). The full approval record stays private: this repository is public or its visibility is unknown.
Plan: exempt: bug fix
Plan check: exempt bug fix
Review fix-check grant: a-5730afc7c802 (review_loop_grant at 8ecc77b).
REVIEW_LOOP: passes=2 blocking_found=3 deferred=0 noted=4 fixed=3 scope=frozen ledgers_read=4 fix_checks=1 dispatches=4 est_input_tokens=16001
Gate edits: none detected (7 listed, 2 read; patterns: RH-1,RH-3,RH-4,RH-12,RH-13,RH-14,RH-15,RH-16; unlisted idioms: none)