[codex] chore(mastra): switch to upstream packages#2985
Conversation
|
Caution Review failedPull request was closed or merged during review 📝 WalkthroughWalkthroughMigrates from a Superset-managed Changes
Estimated code review effort🎯 4 (Complex) | ⏱️ ~60 minutes Poem
🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
🧹 Preview Cleanup CompleteThe following preview resources have been cleaned up:
Thank you for your contribution! 🎉 |
There was a problem hiding this comment.
1 issue found across 13 files
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="apps/desktop/scripts/copy-native-modules.ts">
<violation number="1" location="apps/desktop/scripts/copy-native-modules.ts:152">
P1: The new libsql dependency materialization treats semver ranges as exact versions, which can fetch invalid npm tarball URLs and copy a non-matching Bun store version.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
| } | ||
| } | ||
|
|
||
| if (fetchNpmPackage(moduleName, version, destPath)) { |
There was a problem hiding this comment.
P1: The new libsql dependency materialization treats semver ranges as exact versions, which can fetch invalid npm tarball URLs and copy a non-matching Bun store version.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At apps/desktop/scripts/copy-native-modules.ts, line 152:
<comment>The new libsql dependency materialization treats semver ranges as exact versions, which can fetch invalid npm tarball URLs and copy a non-matching Bun store version.</comment>
<file context>
@@ -110,6 +111,119 @@ function copyModuleIfSymlink(
+ }
+ }
+
+ if (fetchNpmPackage(moduleName, version, destPath)) {
+ return true;
+ }
</file context>
Summary
This switches Superset back to the published upstream Mastra packages and removes the repo-specific Mastracode fork patch flow.
What Changed
mastracodeand@mastra/*patch-mastracode-dependency.tsscript and the fork workflow docWhy
The original fork carried behavior that upstream Mastra now ships directly, while the local fork path added ongoing maintenance cost and custom build steps. The remaining build problem after removing the fork was not Mastra-specific; it was the desktop native packaging path around
libsqlanddetect-libcunder Bun's isolated install layout.Impact
Validation
bun run typecheck -- --filter=@superset/chat --filter=@superset/host-service --filter=@superset/desktopbun run build -- --filter=@superset/chat --filter=@superset/host-service --filter=@superset/desktopbun run test -- --filter=@superset/chat --filter=@superset/host-service --filter=@superset/desktopbunx @biomejs/biome@2.4.2 check AGENTS.md README.md package.json apps/desktop/package.json apps/desktop/scripts/copy-native-modules.ts apps/desktop/src/lib/trpc/routers/changes/utils/merge-pull-request.test.ts packages/chat/package.json packages/chat/src/server/trpc/utils/runtime/runtime.ts packages/chat/src/server/trpc/utils/runtime/superset-mcp.ts packages/host-service/package.jsonSummary by cubic
Switches the repo to upstream
mastracodeand@mastra/*packages and removes the fork/patch workflow. Keeps desktop CI green with semver-aware native module packaging under Bun and stabilizes tests.Dependencies
mastracode,@mastra/core,@mastra/memory.mastracode@0.9.2,@mastra/core@1.17.0(chat),@mastra/mcp@1.3.1.detect-libc@2.0.4to desktop runtime deps.scripts/patch-mastracode-dependency.tsanddocs/mastracode-fork-workflow.md; update README/AGENTS to prefer upstream.Bug Fixes
libsqldeps, materialize exact nested copies when top-level ranges don’t match, and fall back to npm tarballs when Bun store misses artifacts.merge-pull-request.test.tsby using scopedspyOnand restoring withmock.restore()to keep filtered runs green.mode.agentwith current state and tighten MCP tool typing.Written for commit 2a7ec51. Summary will update on new commits.
Summary by CodeRabbit
Release Notes
Dependencies
mastracodeand@mastra/*packages directly (mastracode 0.9.2, @mastra/core 1.17.0, @mastra/mcp 1.3.1).Bug Fixes
Tests
Documentation