Skip to content

chore(web): import apps/web and @plane/* at the oracle pin, with the Q-R2 gate - #120

Merged
aRustyDev merged 4 commits into
mainfrom
chore/web-import-oracle-pin
Nov 11, 2026
Merged

aRustyDev merged 4 commits into
mainfrom
chore/web-import-oracle-pin

Conversation

@aRustyDev

Copy link
Copy Markdown
Owner

Part of #44 (the web import and the Q-R2 gate). Three commits; the first is the import and is not meant to be read.

What

  • web/ holds the stock React app (apps/web), all 14 @plane/* packages and the workspace's root files, copied from the oracle pin oracle/v1-pin-20261018 (ba85d4d332b5) as a pnpm workspace (ADR-0005, Q-R6, Q-0005.2). The pin is not pushed (tools/oracle-v1/SOURCE: pushed=false), so this is a vendored copy; web/SOURCE records where it came from. 3,878 files, about 54 MB on disk.
  • scripts/check-web-diff.sh is the Q-R2 gate: only the files in web/ALLOWED-CHANGES may differ from the pin. The list is empty here.
  • A web job in CI runs the gate, then a frozen install and a build, and the required gate check now judges it.

The import is byte-identical, and how to check it

Tree hashes do not depend on the path, so these match the fork's:

git rev-parse 1b2c313:web/apps/web   707b4128f023f21c1f1cdb99e836e7631b449133   (= ba85d4d3d3:apps/web)
git rev-parse 1b2c313:web/packages   7845782819dc98315f99afe074d582062ea1ee92   (= ba85d4d3d3:packages)

Control: one extra byte in web/apps/web/package.json moves the first hash to 7e00c8fffb6d..., and restoring it brings it back. The first commit holds only the import and web/SOURCE.

The gate (6a4007b)

The pin is not in this repository, so the gate reads two files committed beside the import: web/PIN-MANIFEST (git ls-tree -r <pin> apps/web packages, 3,869 files) and web/ALLOWED-CHANGES. It passes only when the set of files that differ from the manifest (changed, added, deleted, or a mode change) equals the allowed set. A listed file that no longer differs fails too, since a stale line would let a later change through unreviewed. The manifest has to rebuild the two tree hashes in web/SOURCE, so a manifest edited to hide a change fails, and it will not pass on an empty manifest or an empty tree.

.github/scripts/tests/test-check-web-diff.sh runs it against a stand-in pin: 15 cases, eleven of which must fail.

The acceptance line in #44 (git diff --stat ba85d4d3d3 -- apps/web packages) cannot run inside this repository, and the paths in the issue (apps/web/core/components/...) are not the pin's: at the pin the files are apps/web/components/... and apps/web/services/..., with no core/. The manifest comparison is the equivalent check.

CI (f322977)

  • classify-changes.sh prints web= beside rust=; the two are independent, so a change under web/ alone is rust=false, web=true.
  • The web job: the gate, pnpm install --frozen-lockfile --ignore-scripts, turbo run build --filter=web, then a check that build/client/index.html exists. Node is web/.node-version; pnpm is the version web/package.json pins, read from it. actions/setup-node is pinned by SHA (v7.1.0, released 2026-10-08).
  • assert-gate.sh takes WEB_CHANGED: if true, web must be exactly success (skipped is vacuous); if false it may be skipped, which it is on every Rust-only change, but not failed or cancelled. A gate run that is not told WEB_CHANGED fails.

This PR touches scripts/ and .github/, so it runs the full Rust pipeline as well as the web job.

Verified, and not

Run locally on this branch:

  • scripts/check-web-diff.sh at HEAD: ok: 3869 files ... 0 differ.
  • test-check-web-diff.sh 15/15; test-ci-scripts.sh 52 passed, 0 bad (34 existing cases unchanged, 18 new); test-required-contexts.sh passes; actionlint on ci.yml is clean.
  • On the import as it is, with pnpm 11.10.0: a frozen install with --ignore-scripts from an empty node_modules, then an uncached turbo run build --filter=web (10 of 10 tasks), which regenerates build/client/index.html. The lockfile and the root files therefore stay byte-identical to the pin; no pruning was needed.

Not run yet: the web job and the changed gate on GitHub. Their [verified] markers are absent from cicd.md and running.md for that reason. Please read the set of contexts that reported, not only the verdict.

Not in this PR

Still pending the owner

D-022, D-023, D-025, D-026, D-027, D-028 and D-029 await confirmation; this PR touches none of them. Also pending: whether to correct #44's "48 rows, S01 to S48 plus X01 to X03" (the inventory has 49 plus X04) and its core/ paths.

Repository size: this adds about 3,900 files to history permanently.

🤖 Generated with Claude Code

aRustyDev and others added 3 commits November 11, 2026 15:48
Copy the stock React app and the packages around it into web/, as a pnpm
workspace (ADR-0005, Q-R6; Q-0005.2 moves the frontend into this repository).
The source is the fork's oracle pin, oracle/v1-pin-20261018 (ba85d4d332b5),
which exists only in the local clone, so this is a vendored copy and not a
subtree or a submodule. web/SOURCE records where it came from.

web/apps/web and web/packages are byte-identical to the pin. The tree hashes
say so, whatever the path:

  git rev-parse <this commit>:web/apps/web  = 707b412
  git rev-parse <this commit>:web/packages  = 7845782

Both equal `git rev-parse ba85d4d3d3:apps/web` and `:packages` in the fork.
Control: one extra byte in web/apps/web/package.json moves the first hash to
7e00c8fffb6d..., and restoring the file brings it back.

Imported: apps/web, all 14 packages/*, and the workspace's root files
(.node-version, .npmrc, .oxfmtrc.json, .oxlintrc.json, COPYRIGHT.txt,
package.json, pnpm-lock.yaml, pnpm-workspace.yaml, turbo.json). 3,878 files.
Not imported: the other apps, the compose files, deployments, .github, .husky
and docs of the fork. Plane's LICENSE.txt is the AGPL-3.0 text this repository
already carries; the per-file SPDX headers and COPYRIGHT.txt keep the credit.

Nothing builds or runs this yet. The Q-R2 gate, the CI job, the pruned
lockfile and the ignore rules follow in their own commits.

Refs: plane-byd.3
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
…changes

Q-R2 lets the stock app change only in a few places (the auth client, the base
URL and service layer, the collab provider, branding). The pin is not pushed,
so the check cannot diff against it. It reads two files committed beside the
import instead:

- web/PIN-MANIFEST: `git ls-tree -r <pin> apps/web packages`, the mode and blob
  hash of the 3,869 files the pin has there.
- web/ALLOWED-CHANGES: the files that may differ from it. Empty now.

scripts/check-web-diff.sh passes only when the set of files that differ from the
manifest (changed, added, deleted, or a mode change) EQUALS the allowed set. A
listed file that no longer differs fails too, because a stale line would let a
later change through unreviewed. It also rebuilds the pin's two tree hashes from
the manifest and compares them with web/SOURCE, so a manifest edited to hide a
change fails, and it refuses to pass on an empty manifest or an empty tree.

.github/scripts/tests/test-check-web-diff.sh runs it against a stand-in pin:
15 cases, each checked for its exit status and its message, eleven of which must
fail (an unlisted change, a stale line, a deletion, an addition, a mode change,
a doctored manifest, a missing allowlist, an entry outside the trees, a SOURCE
with no hash, and the empty tree and the empty manifest).

Also ignore the build output of web/ (build, dist, .turbo, .react-router) and the
one source file its build generates, as the pin does. `pnpm install
--frozen-lockfile` and `turbo run build --filter=web` pass on the import as it
is (pnpm 11.10.0, ten tasks, build/client/index.html), so the lockfile and the
root files stay byte-identical to the pin.

Not wired into CI yet: that is the next commit.

Refs: plane-byd.3
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
… by the gate

`web/` was not in any CI job: classify-changes.sh sent a web-only change to
rust=false, so the Q-R2 check would have protected nothing.

classify-changes.sh now prints web=true|false beside rust=. web is true for a path
under web/, for scripts/check-web-diff.sh and for the CI files, and it fails open
like rust (an empty list is both). The two are independent: a change under web/
alone is rust=false and web=true.

ci.yml gets a `web` job, run when web=true: scripts/check-web-diff.sh, then
`pnpm install --frozen-lockfile --ignore-scripts` and `turbo run build
--filter=web`, then a check that build/client/index.html exists, so a build that
exits 0 and makes no SPA cannot pass. Node is web/.node-version and pnpm is the
version web/package.json pins, read from it. setup-node is pinned by SHA
(v7.1.0, released 2026-10-08).

assert-gate.sh takes WEB_CHANGED. When it is true the web job must be exactly
`success` (skipped is vacuous, as for the Rust jobs); when it is false the job may
be skipped, which it is on every Rust-only change, but not failed or cancelled.
The Rust rule no longer counts a skipped web job against it, or every Rust-only
change would have failed the gate. A gate run that is not told WEB_CHANGED fails
and does not read it as false.

Tests: test-ci-scripts.sh gains 11 gate cases and 7 classifier cases (52 pass,
the 34 existing ones unchanged), and ci-scripts now also runs
test-check-web-diff.sh. actionlint is clean on ci.yml. The web job itself has not
run in CI; the commands in it were run locally on the import (pnpm 11.10.0, a
frozen install with --ignore-scripts from an empty node_modules, then an uncached
build of ten tasks that regenerated build/client/index.html).

docs/src/architecture/cicd.md and docs/src/testing/running.md describe the job,
with no [verified] marker on what has not run in CI. docs/src/architecture/app.md
said there was no web/ and that the compat plane served S01 to S07, and that
thrust-api-v1 did not exist; it now says what is there.

Refs: plane-byd.3
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@socket-security

socket-security Bot commented Nov 11, 2026 •

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Addednpm/​hast@​1.0.01001003950100
Addednpm/​mdast@​3.0.01001009350100
Addednpm/​recharts@​2.15.49810010050100
Addednpm/​husky@​9.1.71001006180100
Addednpm/​@​tanstack/​react-virtual@​3.13.121001006698100
Addednpm/​@​react-router/​serve@​8.3.0991006796100
Addednpm/​class-variance-authority@​0.7.11001006780100
Addednpm/​@​hypermod/​utils@​0.7.1881006881100
Addednpm/​@​tiptap/​extension-text@​2.26.110010069100100
Addednpm/​@​tiptap/​extension-document@​2.26.11001006998100
Addednpm/​@​react-router/​node@​8.3.01001006996100
Addednpm/​@​types/​sanitize-html@​2.16.01001006986100
Addednpm/​@​types/​express@​4.17.231001007081100
Addednpm/​@​makeplane/​propel@​0.7.3851001009570
Addednpm/​jsdom@​23.2.0951001009670
Addednpm/​@​types/​compression@​1.8.11001007180100
Addednpm/​@​hocuspocus/​extension-logger@​2.15.21001007297100
Addednpm/​@​base-ui/​react@​1.6.0721008895100
Addednpm/​@​tiptap/​extension-list-item@​2.26.11001007298100
Addednpm/​@​hocuspocus/​extension-redis@​2.15.21001007297100
Addednpm/​@​types/​hast@​3.0.41001007281100
Addednpm/​@​tanstack/​react-table@​8.21.31001007296100
Addednpm/​@​tiptap/​extension-task-list@​2.26.11001007298100
Addednpm/​@​commitlint/​cli@​21.2.31001007396100
Addednpm/​@​tiptap/​extension-underline@​2.26.11001007398100
Addednpm/​@​tiptap/​extension-blockquote@​2.26.11001007398100
Addednpm/​@​types/​pdf-parse@​1.1.51001007380100
Addednpm/​@​atlaskit/​pragmatic-drag-and-drop-hitbox@​1.1.01001007388100
Addednpm/​@​tiptap/​html@​2.26.210010073100100
Addednpm/​@​types/​ws@​8.18.11001007383100
Addednpm/​@​tiptap/​extension-placeholder@​2.26.11001007398100
Addednpm/​@​tiptap/​extension-text-style@​2.26.11001007398100
Addednpm/​@​tiptap/​extension-text-align@​2.26.110010073100100
See 133 more rows in the dashboard

View full report

…shell

The ci-scripts job failed on #120 at one case, "a gate run that is not told
WEB_CHANGED fails": it wanted exit 1 and got 2. The script checked its inputs with
`: "${VAR:?}"`, and the shell chooses that exit status: bash (macOS's `sh`, where
the case was written and passed) exits 1, dash (Ubuntu's `sh`, the runner) exits 2.
The gate refused either way, so nothing unsafe got through, but a gate that refuses
should refuse the same way on every runner, and the test was right to say so.

The five inputs are now checked in a loop that names the missing one and calls
fail(), which exits 1. The names are literals, so the eval reads only them. An
empty value fails as before. The test is unchanged.

Because that step runs the three test scripts in sequence and the first failed,
test-required-contexts.sh and test-check-web-diff.sh did not run in CI at all.
Run in an ubuntu:24.04 container, where /bin/sh is dash and git and jq are the
runner's versions: test-ci-scripts.sh 52 passed, 0 bad; test-required-contexts.sh
14 passed, 0 bad; test-check-web-diff.sh 15 passed, 0 bad. The unfixed script,
run directly under dash with WEB_CHANGED unset, exits 2; fixed, it exits 1 under
both dash and macOS sh.

Refs: plane-byd.3
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
@aRustyDev
aRustyDev merged commit 0db0b56 into main Nov 11, 2026
34 checks passed
@aRustyDev
aRustyDev deleted the chore/web-import-oracle-pin branch November 11, 2026 22:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant