Files
omnigent-ai--omnigent/pnpm-workspace.yaml
Zeyi (Rice) Fan c5b3310edd chore(pnpm): drop nodeLinker: hoisted for the default isolated layout (#3497)
## Related issue

N/A

## Summary

- `nodeLinker: hoisted` was a compatibility shim from the npm→pnpm migration
  that forced an npm-style flat `node_modules`. Removing it returns pnpm to its
  default isolated/symlinked layout (packages under `node_modules/.pnpm/…`),
  restoring strict dependency isolation — dependencies must be declared, so
  phantom/undeclared deps stop resolving by accident.
- Validated that the blockers the shim was assumed to guard against don't
  actually block under the isolated layout (details in Test Plan). The Shiki
  cyclic-import crash is handled by the existing `manualChunks` guard in
  `web/vite.config.ts` (a chunking concern, independent of the node linker), and
  electron-builder v26 collects the production dependency tree correctly through
  pnpm's symlinks.

## Test Plan

Validated locally under the isolated layout:
- `pnpm install --frozen-lockfile` — clean and lockfile-consistent (the linker
  setting is not part of the lockfile, so no lockfile churn).
- `pnpm --filter web run build` — succeeds; Shiki resolves to a single acyclic
  chunk via the existing `manualChunks` guard.
- Electron packaging: `pnpm --filter web run build:overlay` then
  `electron-builder --dir` builds and signs the app; inspected the resulting
  `app.asar` — it bundles exactly the production dep tree (`electron-updater`,
  `js-yaml` + their 14 transitive deps) with zero dev-dependency bloat.
- Tailwind v4 `@source` scan follows the symlink: the emitted CSS is
  byte-identical between the hoisted and isolated builds.
- oxlint (schema) and prettier run; `node web/node_modules/vite/bin/vite.js
  --version` (Android Gradle entry) and `web/node_modules/.bin/tsc --version`
  (iOS Fastlane probe) resolve via pnpm's direct-dependency symlinks.

Not runnable locally — relying on CI to confirm: Docker image build,
`electron-build` full installers, and `android-bundle` / iOS app builds.

## Demo

N/A

## Type of change

- [ ] Bug fix
- [ ] Feature
- [ ] UI / frontend change
- [x] Refactor / chore
- [ ] Docs
- [ ] Test / CI
- [ ] Breaking change

## Test coverage

- [ ] Unit tests added / updated
- [ ] Integration tests added / updated
- [ ] E2E tests added / updated
- [x] Manual verification completed
- [ ] Existing tests cover this change
- [x] Not applicable

## Coverage notes

Node-linker layout has no unit-test surface; verified manually via a full
install + web build + electron `--dir` packaging (inspecting the packaged
`app.asar` dependency tree) + a Tailwind CSS byte-diff, and confirmed the
hardcoded node_modules paths (vite entry, tsc/prettier/oxlint) resolve through
pnpm's direct-dependency symlinks. Remaining platform builds are covered by CI.

Signed-off-by: Zeyi (Rice) Fan <zeyi.f@databricks.com>
2026-07-31 18:18:26 -07:00

98 lines
2.9 KiB
YAML

packages:
- 'web'
- 'web/electron'
- '.github/ci-deps'
- 'editors/vscode'
- 'deploy/cloudflare'
settings:
# 7-day dependency cooldown, mirroring the Python-side exclude-newer = "P7D" in uv.toml.
minimumReleaseAge: 10080
autoInstallPeers: false
strictPeerDependencies: false
# jest-dom doesn't declare vitest as a (peer) dependency, so under pnpm's store
# layout its `declare module "vitest"` matcher-type augmentation can't resolve
# vitest and silently fails to merge — `tsc` then loses every DOM matcher
# (toBeInTheDocument, toHaveClass, …) though they work at runtime. Re-enable the
# peer so the augmentation resolves. Drop once jest-dom ships the peer upstream.
packageExtensions:
'@testing-library/jest-dom':
peerDependencies:
vitest: '*'
catalog:
react: ^18.2.0
react-dom: ^18.2.0
shiki: 4.2.0
overrides:
# Build-tool pins that match the legacy npm lockfile. Removing them allowed pnpm
# to resolve newer Vite/Tailwind patches whose new bundler/chunking produced a
# broken split of the Shiki bundle and lost the PDF worker asset.
vite: 8.1.0
tailwindcss: 4.3.1
'@tailwindcss/vite': 4.3.1
'@tailwindcss/node': 4.3.1
'@tailwindcss/postcss': 4.3.1
jiti: 2.7.0
lightningcss: 1.32.0
postcss: 8.5.18
linkify-it: 5.0.2
shiki: "catalog:"
react: "catalog:"
react-dom: "catalog:"
dompurify: ^3.4.0
'@shikijs/core': 4.2.0
'@shikijs/engine-javascript': 4.2.0
'@shikijs/engine-oniguruma': 4.2.0
'@shikijs/langs': 4.2.0
'@shikijs/themes': 4.2.0
'@shikijs/types': 4.2.0
'@shikijs/transformers': 4.2.0
'@tiptap/core': 3.23.4
'@tiptap/extension-blockquote': 3.23.4
'@tiptap/extension-bold': 3.23.4
'@tiptap/extension-bubble-menu': 3.23.4
'@tiptap/extension-bullet-list': 3.23.4
'@tiptap/extension-code': 3.23.4
'@tiptap/extension-code-block': 3.23.4
'@tiptap/extension-document': 3.23.4
'@tiptap/extension-dropcursor': 3.23.4
'@tiptap/extension-floating-menu': 3.23.4
'@tiptap/extension-gapcursor': 3.23.4
'@tiptap/extension-hard-break': 3.23.4
'@tiptap/extension-heading': 3.23.4
'@tiptap/extension-horizontal-rule': 3.23.4
'@tiptap/extension-image': 3.23.4
'@tiptap/extension-italic': 3.23.4
'@tiptap/extension-link': 3.23.4
'@tiptap/extension-list': 3.23.4
'@tiptap/extension-list-item': 3.23.4
'@tiptap/extension-list-keymap': 3.23.4
'@tiptap/extension-ordered-list': 3.23.4
'@tiptap/extension-paragraph': 3.23.4
'@tiptap/extension-strike': 3.23.4
'@tiptap/extension-table': 3.23.4
'@tiptap/extension-text': 3.23.4
'@tiptap/extension-underline': 3.23.4
'@tiptap/extensions': 3.23.4
'@tiptap/markdown': 3.23.4
'@tiptap/pm': 3.23.4
'@tiptap/react': 3.23.4
'@tiptap/starter-kit': 3.23.4
express-rate-limit>ip-address: ^10.1.1
allowBuilds:
'@anthropic-ai/claude-code': true
'@google/genai': true
'@vscode/vsce-sign': true
canvas: true
electron-winstaller: true
esbuild: true
keytar: true
msw: true
protobufjs: true
sharp: true
workerd: true