Skip to content

Forms #875 - #1281

Open
Polleps wants to merge 37 commits into
developfrom
forms-#875
Open

Forms #875#1281
Polleps wants to merge 37 commits into
developfrom
forms-#875

Conversation

@Polleps

@Polleps Polleps commented Aug 17, 2026

Copy link
Copy Markdown
Collaborator

Related Issues

closes #number

Checklist

  • Add changelog entry linking to issue, describe API changes
  • Add or update tests if needed
  • Update docs if needed

@cursor

cursor Bot commented Aug 17, 2026

Copy link
Copy Markdown

Bugbot is not enabled for your account, so this pull request was not reviewed.

Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs.

Polleps and others added 29 commits August 19, 2026 12:21
The .po catalogs and pnpm-lock.yaml are generated artifacts; both were
resolved to develop's side during the rebase, so the forms strings and the
form-app/form-renderer workspace entries were missing. Re-extracted with
wuchale (no AI translation run) and re-locked with pnpm install.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The rights walk now consults the per-query verdict memo by subject
before fetching an ancestor, and loads ancestors from materialized
propvals instead of decoding their Loro snapshots. Query loops stop
calling resolve_query_member after 16 consecutive denials while filling
a page, so a fully-private listing no longer fetches every match.

Co-authored-by: Polle Pas <polleps@gmail.com>
Each member can carry its own read grant, so a streak of private
siblings must not skip later readable rows. Keep resolving until the
page is full of authorized hits; the ancestor-fetch memo is what makes
that cheap.

Co-authored-by: Polle Pas <polleps@gmail.com>
FormCondition resources on pages, fields, and layout blocks, evaluated
in document order (AND; empty = always visible). Shared fixtures keep
the TS renderer and Rust submit validator in lockstep. Hidden required
fields are not errors; submitted values for them are dropped.

Co-authored-by: Polle Pas <polleps@gmail.com>
Co-authored-by: Polle Pas <polleps@gmail.com>
The compiler emitted a broken _w_ctx reference, which crashed the form
builder as soon as the page settings pane mounted the editor.

Co-authored-by: Polle Pas <polleps@gmail.com>
Wuchale rewrote "<FaPlus /> Add condition" into W_tx_ with an undefined
_w_ctx_, which crashed the form builder as soon as the page pane mounted.
Wrap the label in a span so it extracts as a plain string.

Co-authored-by: Polle Pas <polleps@gmail.com>
Polleps and others added 7 commits August 19, 2026 12:21
Three independent failures, each masked by the previous one.

1. pnpm 11 aborted every `pnpm run` with
   ERR_PNPM_ABORTED_REMOVE_MODULES_DIR_NO_TTY. Bumping `packageManager`
   to pnpm@11.10.0 brought in a deps-status check that runs before each
   script and re-invokes `pnpm install` itself. That implicit install
   never sees the `--shamefully-hoist` CLI flag, reads the hoisting
   config as changed, and tries to purge node_modules — with no TTY to
   confirm, it aborts. Hoisting moves to PNPM_CONFIG_SHAMEFULLY_HOIST so
   every invocation agrees; the `yes |` prompt hack is no longer needed.
   Kept as an env var rather than `shamefullyHoist` in
   pnpm-workspace.yaml: that file is shared with developers, and
   flattening node_modules locally would hide undeclared dependencies.

2. `handlers/form.rs` include_str!s assets_tmp/form-assets/index.html,
   but copy_form_assets deliberately skips when browser/form-app/dist is
   absent. What build.rs treats as graceful degradation is a hard
   compile error. dist is gitignored *and* in dagger's source-exclude
   list, so no container can ever have it — hence a placeholder in
   build.rs rather than per-container stubs. This also fixes `cargo
   check` on a fresh clone before `pnpm build`.

3. testdata/form-conditions.json is read from both sides — readFileSync
   in form-renderer's conditions.test.ts, include_str! in forms.rs's
   test module — and was mounted in neither container. The Rust one is
   the worse of the two: it fails compilation of every --all-targets
   build, taking out clippy and nextest together.

Verified on a real engine: js-lint, js-test (774 tests),
js-test-integration, rust-clippy and rust-test all green.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
CI's `pnpm run lint` and `cargo fmt --check` were both failing behind
the pnpm abort fixed in the previous commit, so the drift had gone
unreported. Pure formatting — no behaviour change.

17 JS/TS files via oxfmt (the workspace sets jsxSingleQuote, and the
new form code used double quotes) and 6 Rust files via cargo fmt.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Every JS container died ~2 minutes in with

  ERROR  Failed to switch pnpm to v11.10.0. Looks like pnpm CLI is missing
  at "/root/.local/share/pnpm/.tools/@pnpm+linux-x64/11.10.0/bin"

The containers installed `pnpm@latest-10` via corepack (now 10.34.5), and
browser/package.json declares pnpm@11.10.0, so the first pnpm invocation
in the workspace tried to self-switch. pnpm 10's switch downloads the
`@pnpm/<platform>` package and expects the CLI under `<version>/bin`,
which pnpm 11 no longer ships there — the switch is broken across the
10→11 boundary (pnpm/pnpm#12528, still open). It happened to work on the
engine the last CI fix was verified against, presumably a cached older
10.x layer; against a current latest-10 it fails deterministically.

Fix: install the declared version outright. The pnpm 11 npm package is a
self-contained 18MB JS bundle, so `npm install -g pnpm@11.10.0` needs no
corepack and no platform package, and a matching version never triggers a
switch. The version lives in one constant next to a note that it must
track browser/package.json.

The e2e container had the same latent bug — pinned 10.15.1 via
get.pnpm.io, self-switching on its first `pnpm install` — so it takes the
same constant.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
The playwright container installs pnpm via `get.pnpm.io/install.sh` and
then hardcodes PATH to `/root/.local/share/pnpm`. That was right for
pnpm 10, which dropped its binary straight into `$PNPM_HOME`. pnpm 11
installs `@pnpm/exe` and leaves the shims in `$PNPM_HOME/bin` instead,
so bumping PNPM_VERSION to 11.10.0 in cdef5cb moved the binary out
from under that PATH and the container's first `pnpm install` died with

  exec: "pnpm": executable file not found in $PATH

taking the whole `ci` call down with it. Third distinct symptom of the
same pnpm 10 -> 11 migration.

Hoist the location into a PNPM_BIN_DIR constant next to PNPM_VERSION,
since the two have to move together, and use it for both the in-exec
`export PATH` and the container env var. The install script's own
advice (`export PATH="$PNPM_HOME/bin:$PATH"`) is the authority.

Verified in the exact image the pipeline uses
(mcr.microsoft.com/playwright:v1.58.2-noble): the old PATH gives
"pnpm: not found", `$PNPM_HOME/bin` gives 11.10.0. Then confirmed
end to end with `dagger call end-to-end` against the CI engine —
the e2e container now reaches "Done in 20.4s using pnpm v11.10.0",
installs browsers, and runs all 179 tests.

The e2e container was the only install.sh consumer; every other
container installs via `npm --global` into a Node image where
/usr/local/bin is already on PATH.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
The rebase resolved four .po conflicts by union, which left duplicate and
stale entries. `pnpm clean-translations` dedupes and prunes them: the 47
entries dropped relative to develop are the test fixtures and @wc-ignore'd
error names this branch already excluded from extraction, and the 10 dropped
relative to the pre-rebase branch are strings develop has since renamed
(Cloud Sync -> Cloud Server). No live string lost a translation.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
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.

2 participants