Skip to content

ci: fix crypto wasm types - #29

Open
liviaUeno wants to merge 8 commits into
developfrom
fix-crypto-wasm-types
Open

liviaUeno wants to merge 8 commits into
developfrom
fix-crypto-wasm-types

Conversation

@liviaUeno

@liviaUeno liviaUeno commented Oct 22, 2026 •

Copy link
Copy Markdown

Summary

Fixes the 4 remaining tsc errors reported by the TypeScript job, all of them inside matrix-js-sdk.

Add @matrix-org/matrix-sdk-crypto-wasm@^18.3.1 (the version range the pinned SDK asks for) as a devDependency of apps/web. The change is one line in apps/web/package.json and six lines in pnpm-lock.yaml. No source code changes.

Root cause

apps/web/tsconfig.json includes ./node_modules/matrix-js-sdk/src/@types/*.d.ts through the symlinked path. That declaration file does import type * as RustSdkCryptoJs from "@matrix-org/matrix-sdk-crypto-wasm".

Because the file is read through apps/web/node_modules, TypeScript resolves that import from apps/web. pnpm only links an app's direct dependencies there, and @matrix-org/matrix-sdk-crypto-wasm is only a dependency of the SDK, so it is not visible and tsc fails with TS2307: Cannot find module. The three other errors in MSC4108SignInWithQR.ts (TS2312, TS2698, TS2322) follow from it, because the types from that package become unknown.

Things that were ruled out: the package is installed (18.3.1), it is linked into the SDK's own folder, and moduleResolution is already bundler.

Verification

  • tsc --noEmit in apps/web: 4 errors before, 0 after.
  • pnpm -r --workspace-concurrency=1 lint:types (the command the CI uses) passes.

Notes

@liviaUeno
liviaUeno requested a review from zZMathSP October 22, 2026 15:54

This branch has not been deployed

No deployments
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