Repository navigation
chore(deps): hold @opentui/* at the V2 host's OpenTUI version - #589
Conversation
fro-bot
left a comment
There was a problem hiding this comment.
Verdict: PASS
This is a config-only change: one Renovate packageRule in .github/renovate.json5. I reviewed the diff directly instead of running the ce:review pipeline. A 9-line config change has no code paths for the persona reviewers to examine. I checked the rule against package.json, which already pins @opentui/core and @opentui/solid at 0.8.4 in devDependencies. The @opentui/core override is also 0.8.4, and the peers are optional with a floor of >=0.4.5. The rule matches the state the PR description gives for the V2 host.
Blocking issues
None
Non-blocking concerns
allowedVersions: '<=0.8.4'is correct for an npm-versioned range. It also stops Renovate from proposing downgrades. A hand-bumped dev pin above 0.8.4 would be left alone, and the rule would not flag it.- The manual-sync step is documented only in the rule's
description. It reads: raiseallowedVersions, the devDependencies and the@opentui/coreoverride together when thev2host pin moves. Nothing in CI enforces it. Consider adding a check to the host-contract script that comparespackage.jsonagainst the hosts' OpenTUI versions. This can be a later follow-up. - Once the rule is merged and #577 is closed, Renovate should not re-open the 0.9.x bump. If it appears on the Dependency Dashboard, confirm the rule was applied after the shared preset's rules. Package rules later in the list win, and this one comes after the
extendspreset.
Missing tests
None. The PR description reports renovate-config-validator --strict passing, and there is no runtime code to test.
Risk assessment (LOW) + rationale
LOW. The change only affects which dependency PRs Renovate opens. It does not touch the shipped plugin, the TUI half, the subprocess runtime, the RPC layer or any tool output, so a plugin crash or hang affecting parent OpenCode sessions is not a concern. No changeset is needed, because this is chore(deps) and nothing in the published package changes. The worst case is that Renovate stays pinned for longer than intended, which a one-line edit fixes.
Run Summary
| Field | Value |
|---|---|
| Event | pull_request |
| Repository | marcusrbrown/opencode-copilot-delegate |
| Run ID | 44914729146 |
| Cache | hit |
| Session | ses_e0176c0fbffeyrejQHltxEs1FO |
Fro Bot #589 NBC: the manual sync was enforced only by the rule's description. The pins test now asserts that the @opentui/core and @opentui/solid dev pins equal @opencode/plugin's peer floor and the renovate.json5 allowedVersions cap, and that the @opentui/core override matches. Bumping the V2 host devDependency without moving the others now fails CI.
|
Here is what I did with each review note, in 4ad1e5c:
|
fro-bot
left a comment
There was a problem hiding this comment.
Verdict: PASS
Re-review after 4ad1e5c, which adds a sync test to tests/host-contract-pins.test.ts in response to my earlier non-blocking concern. I reviewed the diff directly instead of running ce:review, because the change is one Renovate rule plus one test file. I didn't run any test commands. I read the test against the repo instead.
The new test closes the gap I raised. It requires the @opentui/core and @opentui/solid dev pins to equal the V2 host's peer floor, read from node_modules/@opencode/plugin/package.json. It also requires the Renovate cap to be <=<floor>, and the @opentui/core override to equal the dev pin. A hand-bumped pin, a stale cap or a stale override now fails CI.
What I checked:
@opencode/pluginis a pinned devDependency (2.3.2), and the unit job runsbun install --frozen-lockfile.node_modules/@opencode/plugin/package.jsontherefore exists whentest:unitruns. Its peers are@opentui/core: >=0.8.4and@opentui/solid: >=0.8.4, which matches the assertions.Bun.JSON5.parseworks here: a probe under Bun 1.4.5 returnedtypeof Bun.JSON5 === "object".@types/bunis 1.4.4, which should cover typecheck. CI gets Bun frommise.toml, so it should match.- The test lives in
tests/*.test.ts, so thetest:unitglob picks it up. The change is test-only. - It follows the file's existing style: top-level
await readFile,Bun.YAML.parse, andascasts onJSON.parseresults.
Blocking issues
None
Non-blocking concerns
- The test reads
node_modules/@opencode/plugin, so it assumes the installed devDependency is the V2 host version. That holds while@opencode/pluginstays pinned to thev2host pin (2.3.2). If those drift, the test checks the wrong floor. It would be stricter to also assert thatdevDependencies['@opencode/plugin']equals thev2entry's version inscripts/opencode-host-pins.json. The existing pins test may already cover this. floorcomes fromv2Peers[name]?.replace(/^>=/, ''). If the host later changes to a^or~range, thetoMatch(/^\d+\.\d+\.\d+$/)assertion fails, which is the right outcome. It fails with an unhelpful message, though, so a custom failure message would help whoever hits it.- The
solid-jsdev pin is not covered. That matches the PR's intent, sincesolid-jsis intentionally unrestricted.
Missing tests
None. The new test is the coverage for this change. The author reports a red-check run: setting the cap to <=0.9.2 fails both pin tests.
Risk assessment (LOW) + rationale
LOW. The change affects only Renovate behavior and a unit test, and nothing in the shipped plugin, TUI half, subprocess runtime or RPC layer. No changeset is needed because the published package doesn't change. The main regression risk is a false-red unit test if the @opencode/plugin devDependency drifts from the V2 host pin. That would show up in CI and is a trivial fix. A plugin crash or hang affecting parent OpenCode sessions is not a concern.
Run Summary
| Field | Value |
|---|---|
| Event | pull_request |
| Repository | marcusrbrown/opencode-copilot-delegate |
| Run ID | 44916201033 |
| Cache | hit |
| Session | ses_e0176c0fbffeyrejQHltxEs1FO |
This supersedes Renovate #577, which bumps
@opentui/solidfrom 0.8.4 to 0.9.2. I'll close #577 after this merges.Why hold at 0.8.4: #587 moved
@opentui/core,@opentui/solidandsolid-jsto optional peers with dev pins. Both OpenCode hosts load their own OpenTUI at runtime (V1 1.19.6 uses 0.4.5, V2 2.3.2 uses 0.8.4; research §7). So the dev pin only types and tests the TUI, and it has to stay the lowest version that satisfies both hosts' peers. That is the V2 host's:@opencode/plugin@2.3.2peers@opentui >=0.8.4. On 0.9.x our types and tests would target APIs that no host runs. 0.9 also replaces the input parser, according to the #577 release notes.Rule:
allowedVersions: '<=0.8.4'for@opentui/coreand@opentui/solid. The description says to raise it together with the devDependencies and the@opentui/coreoverride when thev2pin inscripts/opencode-host-pins.jsonmoves to a host that ships a newer OpenTUI.solid-jsis not restricted: patch updates within 1.9.x are harmless.Validation:
renovate-config-validator --strictreportsConfig validated successfully. This is a config-only change; CI's host-contract path filter skips it.