mirror of
https://github.com/mastra-ai/mastra.git
synced 2026-11-17 08:44:46 +00:00
482 commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
d60ba71be0 | chore: version - exit prerelease mode | ||
|
|
a8130955fe |
chore(deps): update cgr.dev/chainguard/minio docker digest to db3f583 (#30139) | ||
|
|
3a6ca42696 |
chore: version packages (alpha) (#30026)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> |
||
|
|
092dd3c96d |
Add Docker Cloud Sandboxes microVM provider to @mastra/docker (#29356) | ||
|
|
8bce7717eb |
chore: version packages (alpha) (#29986)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> |
||
|
|
2d16c84823 |
feat(factory): Factory-wide sandbox environment variables (#29923)
Factory members can now add environment variables for every sandbox in a
Factory, under Settings › Manage Factory › Environment variables. Each
variable is marked Build, Runtime, or Both.
Runtime variables reach every command in the Factory's sandboxes.
Adding, editing or deleting one takes effect on the next command in a
sandbox that's already running, with no restart (processes already
running keep their old env). Build variables reach template builds and
Factory's setup commands, never runtime commands, and editing one makes
the next build rebuild the template.
Values are encrypted at rest, never returned by the API or shown in the
UI after saving, and never put into template names, identity, or images.
Saving is blocked when sign-in is on but no credential encryption key is
configured.
To make builds work, `FactorySandboxContext` gets two optional fields.
Providers pass `buildEnv` only to a build-only mechanism and put
`buildEnvRevision` (a random id, never derived from values) in template
identity:
```ts
const { buildEnv, buildEnvRevision, ...rest } = ctx;
return createRepoTemplate({ ...rest, buildEnvRevision });
```
The platform and E2B workspace packages pass Build variables to template
builds. Docker keeps them out of the image and its identity, and doesn't
apply them to template builds yet. The routes are also available from
the CLI as `mastra api factory project environment variables
list|set|update|delete`.
Tested with unit tests on a real local sandbox, route tests that check
no response ever contains a value, and UI tests. I also ran it end to
end against a Platform sandbox: a Runtime variable's new value showed up
after an edit and was gone after a delete, and a Build variable was seen
by setup but not at runtime, with an edit producing a new build.
Part of FACT-554
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->
## ELI5
Factory admins can save environment variables for a project and choose
whether each one is used to build sandboxes, run commands, or both.
Factory protects the values and applies changes to later commands or
relevant builds.
## Summary
- Added encrypted, project-scoped storage and authenticated API routes
to list, set, update, and delete sandbox environment variables.
Responses include metadata, not values. When sign-in is enabled without
a credential encryption key, writes are blocked.
- Added a Factory settings interface and CLI commands to manage
variables with Build, Runtime, or Both scopes.
- Runtime variable changes refresh the environment before later
commands. Build variables are available to build contexts and setup
commands. Build-variable changes update a revision used by supported
providers for template identity.
- Reads are served from memory per server: the revision and decrypted
values are reused until a variable changes. A write clears this server's
entry and is announced on Factory's event bus so other servers drop
theirs; a cached read is re-checked after a minute with a cross-process
bus, or after a second without one.
- Added optional `buildEnv` and `buildEnvRevision` fields to
`FactorySandboxContext`. Platform and E2B pass Build variables to
template builds. Docker excludes these fields from template input and
identity; Docker template builds do not receive the variables.
- Added documentation and tests for storage, API routes, settings, CLI,
sandbox behavior, and provider handling.
**Diff size:** 54 files changed; 3,241 lines added and 50 removed.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Co-authored-by: CalebBarnes <CalebBarnes@users.noreply.github.com>
Co-authored-by: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com>
|
||
|
|
4081a55af4 |
chore(deps): update cgr.dev/chainguard/minio docker digest to fb893e3 (#29240) | ||
|
|
b2ce66cef8 |
chore: run lint-staged for root files and the 16 packages without a config (#29898)
Co-authored-by: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com> |
||
|
|
6deb16047f |
chore: version packages (alpha) (#29719)
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and publish to npm yourself or [setup this action to publish automatically](https://github.com/changesets/action#with-publishing). If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. ⚠️⚠️⚠️⚠️⚠️⚠️ `main` is currently in **pre mode** so this branch has prereleases rather than normal releases. If you want to exit prereleases, run `changeset pre exit` on `main`. ⚠️⚠️⚠️⚠️⚠️⚠️ # Releases > The changelog information of each package has been omitted from this message, as the content exceeds the size limit. ## @mastra/slack@1.9.0-alpha.0 ## @mastra/factory@0.28.0-alpha.3 ## @mastra/code-sdk@1.19.0-alpha.3 ## mastracode@0.50.0-alpha.3 ## @mastra/observability@1.24.0-alpha.2 ## @mastra/core@1.83.0-alpha.3 ## @mastra/mcp-apps-components@0.1.0-alpha.3 ## @mastra/playground-ui@69.0.0-alpha.4 ## @mastra/server@1.83.0-alpha.3 ## @mastra/server-adapters-test-suite@0.3.0-alpha.1 ## @mastra/platform-workspace@1.13.0-alpha.0 ## @mastra/auth-better-auth@1.1.11-alpha.1 ## @mastra/client-js@1.60.0-alpha.3 ## @mastra/react@1.15.0-alpha.3 ## @mastra/deployer-cloud@1.83.0-alpha.3 ## @mastra/longmemeval@1.1.42-alpha.3 ## @mastra/opencode@0.1.42-alpha.3 ## create-factory@0.4.3-alpha.3 ## @mastra/arize@1.3.30-alpha.2 ## @mastra/arthur@0.4.30-alpha.2 ## @mastra/braintrust@1.3.27-alpha.2 ## @mastra/datadog@1.4.22-alpha.2 ## @mastra/deepeval@0.1.24-alpha.2 ## @mastra/laminar@1.3.32-alpha.2 ## @mastra/langfuse@1.6.6-alpha.2 ## @mastra/langsmith@1.4.3-alpha.2 ## @mastra/otel-bridge@1.5.22-alpha.2 ## @mastra/otel-exporter@1.5.2-alpha.2 ## @mastra/posthog@1.4.7-alpha.2 ## @mastra/sentry@1.2.32-alpha.2 ## @mastra/agent-builder@1.2.1-alpha.1 ## mastra@1.39.0-alpha.3 ## @mastra/connect@1.3.2-alpha.2 ## @mastra/deployer@1.83.0-alpha.3 ## @mastra/editor@0.17.1-alpha.2 ## @mastra/fastembed@1.3.7-alpha.0 ## @mastra/mcp-docs-server@1.3.13-alpha.6 ## @mastra/memory@1.41.1-alpha.1 ## @mastra/elysia@0.1.23-alpha.3 ## @mastra/express@1.5.27-alpha.3 ## @mastra/fastify@1.5.27-alpha.3 ## @mastra/hono@1.7.25-alpha.3 ## @mastra/koa@1.7.27-alpha.3 ## @mastra/nestjs@0.3.0-alpha.3 ## @mastra/next@0.2.41-alpha.3 ## @mastra/tanstack-start@0.2.41-alpha.3 ## @mastra/convex@1.8.1-alpha.0 ## @mastra/pg@1.36.0-alpha.2 ## @mastra/inngest@1.11.2-alpha.2 ## @mastra/temporal@0.6.0-alpha.3 ## create-mastra@1.39.0-alpha.3 ## @internal/playground@1.39.0-alpha.3 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> |
||
|
|
efe53f0b3c |
feat(platform-workspace): add publicPorts to PlatformSandbox (#28909)
## What
Adds `publicPorts` to `PlatformSandbox`:
```typescript
const sandbox = new PlatformSandbox({ publicPorts: true })
```
Platform sandbox ports are private by default, so they only open through
a signed-in preview link. `publicPorts: true` lets anyone with a port's
URL reach it, for things like webhook receivers that can't sign in. The
port URL is the same either way; only whether it asks for sign-in
changes. It's sent on create, kept through `clone()`, and fixed for the
sandbox's lifetime.
## Changes
- `sandbox.ts`: new option, sent in the create body, copied by
`clone()`.
- `provider.ts`: `publicPorts` in the provider config schema.
- `factory-sandbox.ts`: **Public preview links** setting on
`PlatformFactorySandbox` (off by default), resolved like the idle
timeout: setting, then `defaults`, then the host's `publicPorts` option.
Applies to sandboxes created after it changes. Tried live on a local
Factory: a session started with the setting on served its preview link
without sign-in.
- Docs: "Public ports" section and option row in the `PlatformSandbox`
reference.
- Changeset: `@mastra/platform-workspace` minor.
## Testing
- `sandbox.test.ts` + `provider.test.ts`: 342 pass across the package.
New `PlatformFactorySandbox` tests check the setting's resolution order,
the advertised default, and that the created sandbox sends it. New test
checks the create body for `undefined` / `true` / `false`; the clone
test checks it's inherited.
- Red check: dropping `publicPorts` from the create body fails 3 tests.
- `tsc --noEmit` clean, oxfmt + oxlint clean.
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->
## ELI5
Sandbox ports are private by default. The `publicPorts` option lets
anyone with a port URL access it without signing in, using the same URL.
## Changes
- Added `publicPorts` to `PlatformSandbox` and the provider
configuration schema. It defaults to `false` and is fixed when the
sandbox is created.
- Included the option in sandbox creation requests and passed it to
cloned sandboxes.
- Added a **Public ports** setting to `PlatformFactorySandbox`. Its
value resolves from the factory setting, provider defaults, the host
option, then the built-in default.
- Updated the documentation to explain port access and factory setting
behavior.
- Added tests for creation requests, clone inheritance, and factory
setting resolution.
- Added a minor changeset for `@mastra/platform-workspace`.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Co-authored-by: CalebBarnes <CalebBarnes@users.noreply.github.com>
Co-authored-by: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com>
|
||
|
|
675caf0613 |
chore: version packages (alpha) (#29336)
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and publish to npm yourself or [setup this action to publish automatically](https://github.com/changesets/action#with-publishing). If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. ⚠️⚠️⚠️⚠️⚠️⚠️ `main` is currently in **pre mode** so this branch has prereleases rather than normal releases. If you want to exit prereleases, run `changeset pre exit` on `main`. ⚠️⚠️⚠️⚠️⚠️⚠️ # Releases > The changelog information of each package has been omitted from this message, as the content exceeds the size limit. ## @mastra/client-js@1.60.0-alpha.0 ## @mastra/react@1.15.0-alpha.0 ## @mastra/factory@0.28.0-alpha.0 ## @mastra/code-sdk@1.19.0-alpha.0 ## mastra@1.39.0-alpha.0 ## @mastra/core@1.83.0-alpha.0 ## @mastra/mcp@2.9.0-alpha.0 ## @mastra/mcp-apps-components@0.1.0-alpha.0 ## @mastra/playground-ui@69.0.0-alpha.0 ## @mastra/server@1.83.0-alpha.0 ## @mastra/nestjs@0.3.0-alpha.0 ## @mastra/clickhouse@1.30.0-alpha.0 ## @mastra/duckdb@1.19.0-alpha.0 ## @mastra/libsql@1.30.0-alpha.0 ## @mastra/pg@1.36.0-alpha.0 ## @mastra/temporal@0.6.0-alpha.0 ## @mastra/auth-better-auth@1.1.11-alpha.0 ## @mastra/deployer-cloud@1.83.0-alpha.0 ## @mastra/deployer-cloudflare@1.2.42-alpha.0 ## @mastra/deployer-netlify@1.2.42-alpha.0 ## @mastra/deployer-sandbox@0.3.27-alpha.0 ## @mastra/deployer-vercel@1.2.42-alpha.0 ## @mastra/longmemeval@1.1.42-alpha.0 ## @mastra/opencode@0.1.42-alpha.0 ## create-factory@0.4.3-alpha.0 ## mastracode@0.49.1-alpha.0 ## @mastra/arize@1.3.30-alpha.0 ## @mastra/arthur@0.4.30-alpha.0 ## @mastra/braintrust@1.3.27-alpha.0 ## @mastra/datadog@1.4.22-alpha.0 ## @mastra/deepeval@0.1.24-alpha.0 ## @mastra/laminar@1.3.32-alpha.0 ## @mastra/langfuse@1.6.6-alpha.0 ## @mastra/langsmith@1.4.3-alpha.0 ## @mastra/observability@1.23.2-alpha.0 ## @mastra/otel-bridge@1.5.22-alpha.0 ## @mastra/otel-exporter@1.5.2-alpha.0 ## @mastra/posthog@1.4.7-alpha.0 ## @mastra/sentry@1.2.32-alpha.0 ## @mastra/agent-builder@1.2.1-alpha.0 ## @mastra/connect@1.3.2-alpha.0 ## create-mastra@1.39.0-alpha.0 ## @mastra/deployer@1.83.0-alpha.0 ## @mastra/editor@0.17.1-alpha.0 ## @mastra/mcp-docs-server@1.3.13-alpha.0 ## @mastra/memory@1.41.1-alpha.0 ## @mastra/rag@2.7.3-alpha.0 ## @mastra/redis-streams@0.8.1-alpha.0 ## @mastra/elysia@0.1.23-alpha.0 ## @mastra/express@1.5.27-alpha.0 ## @mastra/fastify@1.5.27-alpha.0 ## @mastra/hono@1.7.25-alpha.0 ## @mastra/koa@1.7.27-alpha.0 ## @mastra/next@0.2.41-alpha.0 ## @mastra/tanstack-start@0.2.41-alpha.0 ## @mastra/spanner@1.11.2-alpha.0 ## @mastra/turso@0.1.21-alpha.0 ## @mastra/inngest@1.11.2-alpha.0 ## @mastra/gcs@0.3.6-alpha.0 ## @internal/playground@1.39.0-alpha.0 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> |
||
|
|
5dae4bf0b3 |
chore(deps): update dependency @google-cloud/storage to v8 (#29116)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> |
||
|
|
6e8dfcb83f | chore: version - exit prerelease mode | ||
|
|
3bdb4ec5f4 |
chore(deps): update build tools (major) (#29026)
> [!NOTE] > This PR body was truncated due to platform limits. This PR contains the following updates: | Package | Type | Update | Change | Pending | |---|---|---|---|---| | [@vitest/coverage-v8](https://vitest.dev/guide/coverage) ([source](https://redirect.github.com/vitest-dev/vitest/tree/HEAD/packages/coverage-v8)) | pnpm.catalog.default | major | [`4.1.12` → `5.0.5`](https://renovatebot.com/diffs/npm/@vitest%2fcoverage-v8/4.1.12/5.0.5) | `5.1.0` | | [@vitest/mocker@>=2.1.0 <4.1.12](https://redirect.github.com/vitest-dev/vitest/tree/main/packages/mocker) ([source](https://redirect.github.com/vitest-dev/vitest/tree/HEAD/packages/mocker)) | pnpm-workspace.overrides | major | [`4.1.12` → `5.0.5`](https://renovatebot.com/diffs/npm/@vitest%2fmocker@>=2.1.0 <4.1.12/4.1.12/5.0.5) | `5.1.0` | | [@vitest/ui](https://vitest.dev/guide/ui) ([source](https://redirect.github.com/vitest-dev/vitest/tree/HEAD/packages/ui)) | pnpm.catalog.default | major | [`4.1.12` → `5.0.5`](https://renovatebot.com/diffs/npm/@vitest%2fui/4.1.12/5.0.5) | `5.1.0` | | [dotenv](https://redirect.github.com/motdotla/dotenv) | devDependencies | major | [`^17.4.2` → `^18.0.9`](https://renovatebot.com/diffs/npm/dotenv/17.4.2/18.0.9) | | | [dotenv](https://redirect.github.com/motdotla/dotenv) | devDependencies | major | [`17.4.2` → `18.0.9`](https://renovatebot.com/diffs/npm/dotenv/17.4.2/18.0.9) | | | [vitest](https://vitest.dev) ([source](https://redirect.github.com/vitest-dev/vitest/tree/HEAD/packages/vitest)) | devDependencies | major | [`^4.1.12` → `^5.0.5`](https://renovatebot.com/diffs/npm/vitest/4.1.12/5.0.5) | `5.1.0` | | [vitest](https://vitest.dev) ([source](https://redirect.github.com/vitest-dev/vitest/tree/HEAD/packages/vitest)) | pnpm.catalog.default | major | [`4.1.12` → `5.0.5`](https://renovatebot.com/diffs/npm/vitest/4.1.12/5.0.5) | `5.1.0` | | [vitest](https://vitest.dev) ([source](https://redirect.github.com/vitest-dev/vitest/tree/HEAD/packages/vitest)) | devDependencies | major | [`4.1.12` → `5.0.5`](https://renovatebot.com/diffs/npm/vitest/4.1.12/5.0.5) | `5.1.0` | | [vitest@>=2.1.0 <4.1.12](https://vitest.dev) ([source](https://redirect.github.com/vitest-dev/vitest/tree/HEAD/packages/vitest)) | pnpm-workspace.overrides | major | [`4.1.12` → `5.0.5`](https://renovatebot.com/diffs/npm/vitest@>=2.1.0 <4.1.12/4.1.12/5.0.5) | `5.1.0` | --- > [!WARNING] > Some dependencies could not be looked up. Check the [Dependency Dashboard](../issues/9505) for more information. --- ### Release Notes <details> <summary>vitest-dev/vitest (@​vitest/coverage-v8)</summary> ### [`v5.0.5`](https://redirect.github.com/vitest-dev/vitest/releases/tag/v5.0.5) [Compare Source](https://redirect.github.com/vitest-dev/vitest/compare/v5.0.4...v5.0.5) ##### 🐞 Bug Fixes - Keep vite default `fs.deny` with api token file - by [@​hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi Ogawa** and **Claude Opus 5.5** in [#​11578](https://redirect.github.com/vitest-dev/vitest/issues/11578) [<samp>(28dc1)</samp>]( |
||
|
|
886679eb10 |
chore: version packages (alpha) (#29205)
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and publish to npm yourself or [setup this action to publish automatically](https://github.com/changesets/action#with-publishing). If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. ⚠️⚠️⚠️⚠️⚠️⚠️ `main` is currently in **pre mode** so this branch has prereleases rather than normal releases. If you want to exit prereleases, run `changeset pre exit` on `main`. ⚠️⚠️⚠️⚠️⚠️⚠️ # Releases > The changelog information of each package has been omitted from this message, as the content exceeds the size limit. ## @mastra/client-js@1.59.0-alpha.2 ## @mastra/factory@0.27.0-alpha.2 ## @mastra/code-sdk@1.18.0-alpha.2 ## mastra@1.38.0-alpha.2 ## @mastra/core@1.82.0-alpha.2 ## @mastra/editor@0.17.0-alpha.2 ## @mastra/server@1.82.0-alpha.2 ## @mastra/clickhouse@1.29.0-alpha.1 ## @mastra/duckdb@1.18.0-alpha.1 ## @mastra/pg@1.35.0-alpha.2 ## @mastra/platform-workspace@1.12.0-alpha.1 ## @mastra/react@1.14.1-alpha.2 ## @mastra/deployer-cloud@1.82.0-alpha.2 ## @mastra/deployer-sandbox@0.3.26-alpha.1 ## @mastra/longmemeval@1.1.41-alpha.2 ## @mastra/opencode@0.1.41-alpha.2 ## @mastra/parallel@0.1.5-alpha.0 ## create-factory@0.4.2-alpha.2 ## mastracode@0.49.0-alpha.2 ## @mastra/arize@1.3.29-alpha.1 ## @mastra/arthur@0.4.29-alpha.1 ## @mastra/braintrust@1.3.26-alpha.1 ## @mastra/datadog@1.4.21-alpha.1 ## @mastra/deepeval@0.1.23-alpha.1 ## @mastra/laminar@1.3.31-alpha.1 ## @mastra/langfuse@1.6.5-alpha.1 ## @mastra/langsmith@1.4.2-alpha.1 ## @mastra/observability@1.23.1-alpha.1 ## @mastra/otel-bridge@1.5.21-alpha.1 ## @mastra/otel-exporter@1.5.1-alpha.1 ## @mastra/posthog@1.4.6-alpha.1 ## @mastra/sentry@1.2.31-alpha.2 ## @mastra/agent-builder@1.1.33-alpha.2 ## @mastra/deployer@1.82.0-alpha.2 ## @mastra/mcp@2.8.0-alpha.1 ## @mastra/mcp-docs-server@1.3.12-alpha.3 ## @mastra/memory@1.41.0-alpha.2 ## @mastra/playground-ui@68.0.0-alpha.2 ## @mastra/rag@2.7.2-alpha.0 ## @mastra/elysia@0.1.22-alpha.2 ## @mastra/express@1.5.26-alpha.2 ## @mastra/fastify@1.5.26-alpha.2 ## @mastra/hono@1.7.24-alpha.2 ## @mastra/koa@1.7.26-alpha.2 ## @mastra/nestjs@0.2.41-alpha.2 ## @mastra/next@0.2.40-alpha.2 ## @mastra/tanstack-start@0.2.40-alpha.2 ## @mastra/dsql@1.5.6-alpha.0 ## @mastra/libsql@1.29.0-alpha.1 ## @mastra/mongodb@1.26.0-alpha.1 ## @mastra/mssql@1.11.1-alpha.0 ## @mastra/mysql@0.16.0-alpha.2 ## @mastra/oracledb@0.5.6-alpha.0 ## @mastra/spanner@1.11.1-alpha.0 ## @mastra/turso@0.1.20-alpha.1 ## @mastra/voice-google@0.14.5-alpha.0 ## @mastra/inngest@1.11.1-alpha.1 ## @mastra/temporal@0.5.0-alpha.2 ## @mastra/e2b@0.16.1-alpha.1 ## create-mastra@1.38.0-alpha.2 ## @internal/playground@1.38.0-alpha.2 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> |
||
|
|
42004349c1 |
fix(platform-workspace,e2b): kill the processes a background process started (#29238)
## Summary Killing a background process in a Platform or E2B sandbox left the processes it started running. An agent that started a dev server with `npm run dev` and then killed it stopped npm, but the dev server underneath was re-parented to init and kept serving: its preview URL still worked and the port stayed taken, so starting the server again failed with "Port 5173 is already in use". The sandbox's commands API signals only the pid it's given. `LocalSandbox` already kills the whole process group; this brings Platform and E2B sandboxes in line. ## Change `kill()` in the shared commands-API process manager (used by `PlatformSandbox` and `@mastra/e2b`) now: 1. pauses the process, so a wrapper like npm can't exit on its own once its child dies, 2. pauses and kills everything it started, at any depth (a short recursive `pgrep -P` function in the sandbox), 3. kills the process itself, as before. Step 2 is best effort: if it can't run, the process is still killed. ## Testing - New test: a wrapper -> `sh -c` -> server chain (the shape of `npm run dev`), killed through the process manager, takes both the shell and the server down and exits 137. Fails without the change. - `@internal/workspace` 158, `@mastra/platform-workspace` 334, `@mastra/e2b` 349 (34 skipped) pass; typecheck and lint clean. - Live through `PlatformSandbox`, `npm run dev` serving on 5173: | | before | after | |---|---|---| | `processes.kill(npm pid)` | `true` | `true` | | npm | gone | gone | | `sh -c node server.js` + `node server.js` | still running, parent 1 | gone | | `curl localhost:5173` | `hi` | down | - Same result live through `E2BSandbox` (npm -> `sh -c node server.js` -> `node server.js` all gone after `kill()`, port down). - End to end in Factory: a session agent started Vite with `npm run dev` in the background, the port link loaded, then `kill_process` on npm's pid left no npm or Vite processes, `curl localhost:5173` was down, and the link showed "Port closed". Before this change the link kept working. - The test's liveness check counts an unreaped zombie as stopped, so it doesn't depend on the CI container reaping orphans. - Known limit: a server that detaches from the tree (a daemon whose launching shell exits) isn't reached by walking children; that's unchanged from before. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> <!-- coderabbit-ai-generated:v1 --> ## ELI5 When a command stops, programs it started can keep running. This change makes `kill()` try to stop those child programs too, so they do not keep a server or port active after the command stops. ## Changes - `CommandsApiProcessHandle.kill()` pauses the target, then makes a best-effort attempt to pause and kill its descendants before killing the target. - If descendant cleanup fails, the target is still killed. - Added a test that kills a wrapper and checks that its shell and server stop while a separate sibling process remains alive. - Updated the lease-rotation test and added patch changesets for `@mastra/platform-workspace` and `@mastra/e2b`. ## Validation The PR description reports passing tests for `@internal/workspace` (158), `@mastra/platform-workspace` (334), and `@mastra/e2b` (349, with 34 skipped), plus clean typecheck and lint. It also reports live checks in `PlatformSandbox`, `E2BSandbox`, and `Factory` where killing npm stopped the child server and closed port 5173. These results were not independently run for this summary. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: CalebBarnes <CalebBarnes@users.noreply.github.com> Co-authored-by: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com> |
||
|
|
cf67119620 |
feat(factory): let session agents share links to sandbox ports (#28501)
## Summary Factory session agents can start a server in their sandbox (a dev server, a preview, an API), but had no way to give anyone a link to it. - New Factory tool `factory_sandbox_port_url` returns the shareable URL for a port in the calling session's own running sandbox. It gets the URL from the standard `sandbox.networking.getPortUrl()`. On Platform sandboxes it also puts a port auth cookie straight into the session's browser (via `MastraBrowser.setCookies`; browsers that can't take cookies still get the link), so the agent can open the preview itself. The cookie never goes back to the model. - `PlatformSandbox.getPortAuthCookie(port)` returns that cookie, or `null` in the same cases as `getPortUrl()`. Builds on #29227 (merged), which added `networking.getPortUrl()` to `PlatformSandbox`. Part of FACT-535. ## Test plan - `@mastra/platform-workspace`: `getPortAuthCookie` returns the cookie from the preview-grants route, and `null` for ports with no URL without calling Platform. 334 pass, typecheck clean. - `@mastra/factory`: the tool returns only the link, puts the cookie into the calling thread's browser (never into its result), skips the browser without a thread or a cookie, returns the link alone on sandboxes without the cookie method, and reports a missing sandbox, a sandbox that can't expose ports, or a port with no URL. Not setting the cookie fails the test. 276 tool tests pass, typecheck clean. - Tested end to end in a local Factory against a live Platform sandbox: asked from Slack for a Vite app and its link. The agent started Vite in the background without a timeout and set `allowedHosts: true`, the reply held only the `…sandbox.us.mastra.cloud` link, the agent's browser opened the page without signing in, and HTML and CSS edits hot-reloaded in the open page. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> <!-- coderabbit-ai-generated:v1 --> ## ELI5 This PR gives Factory agents a link to a port running in their sandbox. For Platform sandboxes, it also attempts to let the calling browser open that link without signing in. ## Changes - Adds the `factory_sandbox_port_url` tool. It finds the session’s sandbox and returns the requested port URL when available. - When the sandbox supports port-auth cookies and a browser session is available, the tool attempts to add the cookie to that session. Cookie setup failures do not block the URL result. - Adds `PlatformSandbox.getPortAuthCookie(port)` and exports the `SandboxPortAuthCookie` type. The method returns `null` when the URL or cookie is unavailable. - Adds tests and reference documentation for the new tool and API. ## Validation The PR objectives report passing tests and typechecks for `@mastra/platform-workspace` and `@mastra/factory`. They also report a local end-to-end check with a live Platform sandbox: a Vite preview opened without signing in and reflected edits through hot reload. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: CalebBarnes <CalebBarnes@users.noreply.github.com> Co-authored-by: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com> |
||
|
|
f1d933dd35 |
feat(platform-workspace): port URLs on PlatformSandbox (#29227)
## What
`PlatformSandbox` now implements the standard `networking` capability.
`sandbox.networking.getPortUrl(port)` returns the URL of a port in the
running sandbox:
```typescript
await sandbox.processes.spawn('pnpm dev --host 0.0.0.0 --port 3000')
const url = await sandbox.networking.getPortUrl(3000)
// https://3000-<sandbox id>.sandbox.us.mastra.cloud/
```
Ports are private. Anyone in the sandbox's organization can open the URL
in a browser after signing in to Mastra, and anyone else is turned away.
The URL doesn't expire, so it's the one to share.
It returns `null`, without starting anything, when the sandbox isn't
running or has been destroyed, for an invalid port, or for the sandbox's
control port. Other platform errors are thrown.
## Why
Agents and apps running in a Platform sandbox had no way to hand someone
a link to what they built, like a dev server. Other providers already
expose this through `sandbox.networking`, so code written against that
interface now works with Platform sandboxes too.
Core's `SandboxNetworking` doc comment promised a public URL, so it now
says the URL may ask for sign-in, depending on the provider. With
`publicPorts` (coming separately), Platform URLs open without sign-in
like other providers.
This only covers opening a port in a browser. A server-side caller
without a signed-in browser gets a 401 on a private port. The sandbox
deployer's health check used to count that 401 as a running server. It
now treats a response the preview marks as its own
(`x-mastra-preview-error`) as a provider error, like Vercel's
`x-vercel-error`, so a deploy to a private port fails its health check
instead of reporting success.
## Depends on
mastra-ai/platform#4179 (merged and deployed): the preview proxy marks
its own responses with `x-mastra-preview-error`. The deployer change
relies on it. Verified live: an unsigned request to a preview host on
prod US, prod EU and staging returns `401` with `x-mastra-preview-error:
sign-in-required`.
## Testing
- Deployer: `waitForHealthy` tests against a real local server. An app's
own 200 and 401 count as up. A 410, `x-vercel-error`, and a
preview-marked 401 don't. Without the change, the preview case fails.
- Unit: the address from the platform's preview route, without its
one-time sign-in link. `null` before start, after destroy (410), when
previews aren't served (404), for invalid ports and the control port,
with no request in those cases. Other errors are thrown. Removing the
404/410 handling or returning the sign-in link fails the tests. 331
pass, typecheck clean.
- Live against the platform:
| Check | Result |
| --- | --- |
| `getPortUrl(3000)` before `start()` | `null`, no request |
| `supportsNetworking(sandbox)` | `true` |
| `getPortUrl(3000)` | `https://3000-<id>.sandbox.us.mastra.cloud/` |
| Opening it in a browser without signing in | 302 to the sign-in page |
| Fetching it without signing in | 401 "Sign in to see this preview." |
| `getPortUrl(49983)` | `null` |
| After `destroy()` | `null` |
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->
## ELI5
Supported Platform sandboxes can now provide a link to an app port.
Health checks also ignore provider sign-in responses, so they do not
mistake them for a healthy app.
## Summary
- Add `PlatformSandbox.networking.getPortUrl(port)` for E2B-backed
sandboxes. The URL is private and requires a signed-in organization
member.
- Return `null` for invalid or reserved ports, a sandbox that is not
running, or a missing or destroyed sandbox. A 404 or 410 from the
preview grant also returns `null`; a 410 clears the matching sandbox ID
and resets its status. Other errors propagate.
- Document port URL access, expiration, and paused-sandbox behavior.
Update Core networking documentation to note that sign-in may be
required, depending on the provider.
- Update `waitForHealthy` to reject provider-edge responses marked by
`x-mastra-preview-error`, alongside HTTP 410 and `x-vercel-error`.
- Add tests for port URL behavior and health-check responses. Test
results were not provided.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Co-authored-by: CalebBarnes <CalebBarnes@users.noreply.github.com>
Co-authored-by: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com>
|
||
|
|
e562b6bebe |
chore(deps): update cgr.dev/chainguard/minio docker digest to 0a01100 (#29161) | ||
|
|
30046969ad |
chore: version packages (alpha) (#29146)
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and publish to npm yourself or [setup this action to publish automatically](https://github.com/changesets/action#with-publishing). If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. ⚠️⚠️⚠️⚠️⚠️⚠️ `main` is currently in **pre mode** so this branch has prereleases rather than normal releases. If you want to exit prereleases, run `changeset pre exit` on `main`. ⚠️⚠️⚠️⚠️⚠️⚠️ # Releases ## @mastra/client-js@1.59.0-alpha.1 ### Minor Changes - Added the `aggregateTimeToFirstMeasures` observability capability. Trace and span aggregate requests for `timeToFirstToken.*` or `timeToFirstChunk.*` measures now return `501` against stores that can't compute them, and field discovery omits those measures for such stores. ([#29055](https://github.com/mastra-ai/mastra/pull/29055)) ```typescript const { capabilities } = await mastraClient.getObservabilityCapabilities(); if (capabilities.traceAggregate && capabilities.aggregateTimeToFirstMeasures) { const { rows } = await mastraClient.aggregateTraces({ timeRange: { from: '2026-08-01T00:00:00.000Z', to: '2026-08-02T00:00:00.000Z' }, groupBy: ['entityName'], measures: ['timeToFirstChunk.p95', 'timeToFirstChunk.count'], }); } ``` ### Patch Changes - Updated dependencies [[`8751dd7`]( |
||
|
|
5735a50c6c |
chore(deps): update workspace providers to ^2.62.0 (#27993)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> |
||
|
|
77076a1012 | chore: version - exit prerelease mode | ||
|
|
582ef17a2b |
chore: version packages (alpha) (#28888)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> |
||
|
|
51e837a4b8 |
chore(deps): update workspace provider SDKs (#28975) | ||
|
|
fded8da0e0 |
chore(deps): update cgr.dev/chainguard/minio docker digest to e234321 (#28927) | ||
|
|
2e62b365e4 |
chore: version packages (alpha) (#28869) | ||
|
|
7691115f9d |
feat(factory): scope sandbox env to a single factory (#28767)
> Opened by @DSchau
## Summary
Today the env a factory deployment passes to its sandboxes reaches every
factory's sessions. A deployment hosting several factories (Shipyard
runs mastra, platform and website) can't give a credential to just one
of them.
This PR adds two fields to `FactorySandboxContext`:
- `factoryId`: the session's factory project id. Environment builds get
it from the project.
- `factoryName`: the factory's display name, for logs and readable
config.
Every factory sandbox provider (`LocalFactorySandbox`,
`PlatformFactorySandbox`, `E2BFactorySandbox`, `DockerFactorySandbox`)
now accepts `env` as either a record (unchanged) or a function of the
context:
```ts
new PlatformFactorySandbox({
env: ctx => (ctx.factoryId === PLATFORM_FACTORY_ID ? { PLATFORM_TOKEN } : {}),
});
```
Names can be edited and aren't unique, so the docs say to scope secrets
by `factoryId`, never by name. Sessions created before factories existed
carry neither field.
The change is non-breaking. The record form behaves exactly as before,
and both context fields are optional, so third-party `FactorySandbox`
implementations keep compiling.
## Proof
- Every provider gets a new test where an env function gives the
credential to the matching factory and nothing to another factory (or to
a legacy session with no factory). The existing record-form `env` tests
still pass unchanged.
- `workspace.test.ts`: the session sandbox context now includes
`factoryId`/`factoryName` for a factory session and neither for a
session without a factory. `build.test.ts`: the environment build
context carries both.
- `tsc --noEmit` is clean for `@mastra/factory`, `@mastra/e2b`,
`@mastra/docker` and `@mastra/platform-workspace` against freshly built
core.
## Unverified
- I haven't run it end to end on a deployed Factory. Shipyard's own
config change (gating the token to the platform factory) is a follow-up
once this is released.
Risk: low
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->
## ELI5
A factory can choose which environment variables each session receives.
This helps keep one factory’s credentials away from sessions that belong
to other factories.
## What changed
- Added optional `factoryId` and `factoryName` fields to
`FactorySandboxContext`. Sessions created before factories existed do
not have these fields.
- Added the factory ID and name to sandbox contexts for sessions
associated with a factory.
- Updated the Local, Platform, E2B, and Docker sandbox providers to
accept `env` as a fixed record or a function of the session context.
- Documented how to use `factoryId` to scope secrets. Factory names can
change and are not unique.
- Documented that Platform and Docker sandboxes keep their initial
environment when resumed. Recreate a running sandbox to remove a
credential.
## Testing
The PR description reports provider tests for factory-specific
credentials, context tests in `workspace.test.ts` and `build.test.ts`,
and clean `tsc --noEmit` checks for the affected packages. The author
reports that the change was not tested end to end on a deployed Factory.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Co-authored-by: mastra-platform[bot] <284800079+mastra-platform[bot]@users.noreply.github.com>
|
||
|
|
cf92428a76 |
chore(deps): update docker images (#28011)
This PR contains the following updates: | Package | Update | Change | |---|---|---| | amazon/aws-cli | minor | `2.36.44` → `2.39.1` | | clickhouse/clickhouse-server | minor | `26.6.1.1193` → `26.10.3.7` | | cr.weaviate.io/semitechnologies/weaviate | minor | `1.39.13` → `1.40.3` | | [docker.elastic.co/elasticsearch/elasticsearch](https://www.elastic.co/products/elasticsearch) ([source](https://redirect.github.com/elastic/elasticsearch)) | minor | `9.4.3` → `9.5.5` | | edoburu/pgbouncer | minor | `v1.25.2-p0` → `v1.26.1-p0` | | [ghcr.io/shopify/toxiproxy](https://redirect.github.com/Shopify/toxiproxy) | minor | `2.12.0` → `2.13.0` | | inngest/inngest | minor | `v1.34.0` → `v1.49.0` | | mcr.microsoft.com/azure-storage/azurite | minor | `3.35.0` → `3.37.0` | | [mongo](https://hub.docker.com/_/mongo) ([source](https://redirect.github.com/docker-library/mongo)) | patch | `7.0.37` → `7.0.45` | | pgvector/pgvector | patch | `0.8.4-pg16` → `0.8.7-pg16` | --- > [!WARNING] > Some dependencies could not be looked up. Check the [Dependency Dashboard](../issues/9505) for more information. --- ### Release Notes <details> <summary>elastic/elasticsearch (docker.elastic.co/elasticsearch/elasticsearch)</summary> ### [`v9.5.5`](https://redirect.github.com/elastic/elasticsearch/releases/tag/v9.5.5): Elasticsearch 9.5.5 [Compare Source](https://redirect.github.com/elastic/elasticsearch/compare/v9.5.4...v9.5.5) Downloads: <https://elastic.co/downloads/elasticsearch> Release notes: <https://www.elastic.co/docs/release-notes/elasticsearch#elasticsearch-9.5.5-release-notes> ### [`v9.5.4`](https://redirect.github.com/elastic/elasticsearch/releases/tag/v9.5.4): Elasticsearch 9.5.4 [Compare Source](https://redirect.github.com/elastic/elasticsearch/compare/v9.5.3...v9.5.4) Downloads: <https://elastic.co/downloads/elasticsearch> Release notes: <https://www.elastic.co/docs/release-notes/elasticsearch#elasticsearch-9.5.4-release-notes> ### [`v9.5.3`](https://redirect.github.com/elastic/elasticsearch/releases/tag/v9.5.3): Elasticsearch 9.5.3 [Compare Source](https://redirect.github.com/elastic/elasticsearch/compare/v9.5.2...v9.5.3) Downloads: <https://elastic.co/downloads/elasticsearch> Release notes: <https://www.elastic.co/docs/release-notes/elasticsearch#elasticsearch-9.5.3-release-notes> ### [`v9.5.2`](https://redirect.github.com/elastic/elasticsearch/releases/tag/v9.5.2): Elasticsearch 9.5.2 [Compare Source](https://redirect.github.com/elastic/elasticsearch/compare/v9.5.1...v9.5.2) Downloads: <https://elastic.co/downloads/elasticsearch> Release notes: <https://www.elastic.co/docs/release-notes/elasticsearch#elasticsearch-9.5.2-release-notes> ### [`v9.5.1`](https://redirect.github.com/elastic/elasticsearch/releases/tag/v9.5.1): Elasticsearch 9.5.1 [Compare Source](https://redirect.github.com/elastic/elasticsearch/compare/v9.5.0...v9.5.1) Downloads: <https://elastic.co/downloads/elasticsearch> Release notes: <https://www.elastic.co/docs/release-notes/elasticsearch#elasticsearch-9.5.1-release-notes> ### [`v9.5.0`](https://redirect.github.com/elastic/elasticsearch/releases/tag/v9.5.0): Elasticsearch 9.5.0 [Compare Source](https://redirect.github.com/elastic/elasticsearch/compare/v9.4.8...v9.5.0) Downloads: <https://elastic.co/downloads/elasticsearch> Release notes: <https://www.elastic.co/docs/release-notes/elasticsearch#elasticsearch-9.5.0-release-notes> ### [`v9.4.8`](https://redirect.github.com/elastic/elasticsearch/releases/tag/v9.4.8): Elasticsearch 9.4.8 [Compare Source](https://redirect.github.com/elastic/elasticsearch/compare/v9.4.7...v9.4.8) Downloads: <https://elastic.co/downloads/elasticsearch> Release notes: <https://www.elastic.co/docs/release-notes/elasticsearch#elasticsearch-9.4.8-release-notes> ### [`v9.4.7`](https://redirect.github.com/elastic/elasticsearch/releases/tag/v9.4.7): Elasticsearch 9.4.7 [Compare Source](https://redirect.github.com/elastic/elasticsearch/compare/v9.4.6...v9.4.7) Downloads: <https://elastic.co/downloads/elasticsearch> Release notes: <https://www.elastic.co/docs/release-notes/elasticsearch#elasticsearch-9.4.7-release-notes> ### [`v9.4.6`](https://redirect.github.com/elastic/elasticsearch/releases/tag/v9.4.6): Elasticsearch 9.4.6 [Compare Source](https://redirect.github.com/elastic/elasticsearch/compare/v9.4.5...v9.4.6) Downloads: <https://elastic.co/downloads/elasticsearch> Release notes: <https://www.elastic.co/docs/release-notes/elasticsearch#elasticsearch-9.4.6-release-notes> ### [`v9.4.5`](https://redirect.github.com/elastic/elasticsearch/releases/tag/v9.4.5): Elasticsearch 9.4.5 [Compare Source](https://redirect.github.com/elastic/elasticsearch/compare/v9.4.4...v9.4.5) Downloads: <https://elastic.co/downloads/elasticsearch> Release notes: <https://www.elastic.co/docs/release-notes/elasticsearch#elasticsearch-9.4.5-release-notes> ### [`v9.4.4`](https://redirect.github.com/elastic/elasticsearch/releases/tag/v9.4.4): Elasticsearch 9.4.4 [Compare Source](https://redirect.github.com/elastic/elasticsearch/compare/v9.4.3...v9.4.4) Downloads: <https://elastic.co/downloads/elasticsearch> Release notes: <https://www.elastic.co/docs/release-notes/elasticsearch#elasticsearch-9.4.4-release-notes> </details> <details> <summary>Shopify/toxiproxy (ghcr.io/shopify/toxiproxy)</summary> ### [`v2.13.0`](https://redirect.github.com/Shopify/toxiproxy/blob/HEAD/CHANGELOG.md#2130---2026-10-14) [Compare Source](https://redirect.github.com/Shopify/toxiproxy/compare/v2.12.0...v2.13.0) - Reject slicer toxics with `average_size` <= 0 or `size_variation` outside `[0, average_size]`, and stop the slicer from recursing forever on degenerate sizes ([#​774](https://redirect.github.com/Shopify/toxiproxy/issues/774), [@​iyaz-shaikh](https://redirect.github.com/iyaz-shaikh)) - Add optional bearer token auth for the HTTP API via `TOXIPROXY_AUTH_TOKEN`, supported by the Go client and `toxiproxy-cli`, and warn when the API is unauthenticated on a non-loopback address ([#​774](https://redirect.github.com/Shopify/toxiproxy/issues/774), [@​iyaz-shaikh](https://redirect.github.com/iyaz-shaikh)) - Fix removing a toxic hanging forever, and freezing the whole HTTP API, when the downstream toxic or connection is already gone ([#​760](https://redirect.github.com/Shopify/toxiproxy/issues/760), [@​matheusgb](https://redirect.github.com/matheusgb)) - Fix the bandwidth toxic hanging or panicking when `rate` <= 0 ([#​764](https://redirect.github.com/Shopify/toxiproxy/issues/764), [@​jaideeppyne](https://redirect.github.com/jaideeppyne)) - Update go version to 1.27 ([#​777](https://redirect.github.com/Shopify/toxiproxy/issues/777), [@​The-Black-Fox](https://redirect.github.com/The-Black-Fox)) - Update various go packages </details> --- ### Configuration 📅 **Schedule**: (UTC) - Branch creation - "before 6am every weekday" - Automerge - At any time (no schedule defined) 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://redirect.github.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate CLI](https://redirect.github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0NC4xNzUuMSIsInVwZGF0ZWRJblZlciI6IjQ0LjE5Mi4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJhdXRvbWF0aW9uIl19--> --------- Co-authored-by: mastra-platform[bot] <284800079+mastra-platform[bot]@users.noreply.github.com> |
||
|
|
4f12792ed1 |
chore: version packages (alpha) (#28722)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> |
||
|
|
088c84cdb2 |
chore(deps): update cgr.dev/chainguard/minio docker digest to e70b2b1 (#28076)
This PR contains the following updates: | Package | Update | Change | |---|---|---| | cgr.dev/chainguard/minio | digest | `32c504b` → `e70b2b1` | --- > [!WARNING] > Some dependencies could not be looked up. Check the [Dependency Dashboard](../issues/9505) for more information. --- ### Configuration 📅 **Schedule**: (UTC) - Branch creation - "before 6am every weekday" - Automerge - At any time (no schedule defined) 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate CLI](https://redirect.github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0NC4xNzYuMiIsInVwZGF0ZWRJblZlciI6IjQ0LjE5MC4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJhdXRvbWF0aW9uIl19--> |
||
|
|
820bc5eafb |
fix(vercel): clarify sandbox mounting support (#28729)
## Summary - clarify that Mastra's Vercel Sandbox adapter does not implement the Workspace filesystem mounting API - distinguish that adapter limitation from Vercel Sandbox's native FUSE mount support in both documentation and agent-facing default instructions - document the underlying SDK instance as an unmanaged escape hatch for configuring mounts directly - add regression coverage and a patch changeset for `@mastra/vercel` ## Test plan - `pnpm exec vitest run src/microvm/index.test.ts` (from `workspaces/vercel`) - `pnpm lint` (from `workspaces/vercel`) - `pnpm build` (from `workspaces/vercel`) - `pnpm exec oxfmt-mdx --check src/content/en/integrations/sandboxes/vercel.mdx` (from `docs`) - focused Remark validation - `git diff --check` ## Notes - Vale was not available in this workspace, so the focused Vale check could not run. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> <!-- coderabbit-ai-generated:v1 --> ## ELI5 Mastra’s Vercel Sandbox adapter does not provide filesystem mounting tools. Vercel Sandbox supports FUSE mounts, but users must configure them directly on the underlying sandbox. ## Changes - Clarifies in the documentation and default instructions that Mastra does not manage Workspace filesystem mounts, while Vercel Sandbox supports native FUSE mounts. - Adds regression coverage for the updated default instructions. - Adds a patch changeset for `@mastra/vercel`. ## Validation The PR description reports successful Vitest, lint, build, formatting, Remark, and `git diff --check` checks. It also reports that Vale was unavailable. The supplied shell result showed no diff for the requested files, so it does not independently confirm these changes or validation results. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: labifrancis |
||
|
|
6a191d46dc | chore: version - exit prerelease mode | ||
|
|
332eb25cdc |
chore: version packages (alpha) (#28647)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> |
||
|
|
cb99bcf4f5 |
fix(factory): don't name the sandbox provider in the Docker memory tip (#28646)
## What The sandbox Docker setting and its low-memory warning said "E2B recommends at least 2 GB". People on Mastra's Platform sandbox don't need to know which provider runs it underneath, so the text now says "We recommend at least 2 GB of memory for Docker." Changed: - Docker setting description in `@mastra/platform-workspace` - Low-memory warning in the Factory environment settings - The pending Docker changeset, so the release notes don't say it either ## Test plan - [x] `EnvironmentSection.msw.test.tsx` (16 passed), updated to match the new warning - [x] `platform-workspace` factory-sandbox tests (14 passed) --------- Co-authored-by: CalebBarnes <CalebBarnes@users.noreply.github.com> Co-authored-by: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com> |
||
|
|
ef92d71d94 |
chore: version packages (alpha) (#28499)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> |
||
|
|
b6fb8c8d72 |
feat(platform-workspace): opt-in Docker sandbox setting (#27888)
> Opened by @abhiaiyer91 > [!IMPORTANT] > **Merge prerequisite:** mastra-ai/platform#3634 must be merged **and deployed** first. The platform server deployed today rejects unknown template ops, so `POST /sandbox` with `{ method: 'docker' }` returns a 400, and `start()` does not retry a 400. Merging this first would leave anyone who turns on the Docker toggle with a sandbox that never starts. ## What Factory sessions can't run tests that need local infrastructure such as Redis, because there's no Docker in the sandbox. This PR adds an opt-in **Docker** setting to the platform factory sandbox. It's handled like cpu and memory: a template resource. - `Template().docker()` emits `{ method: 'docker', args: [true] }`. - `PlatformFactorySandboxSettings.docker` (default `false`) appears in the settings schema, so the factory UI shows it as a switch. `template()` passes it through to `createRepoTemplate`. - `createRepoTemplate` adds the op after sizing and **keeps it in the resources-only fallback**. That way a Docker session never boots without Docker, even when the repo can't be resolved. - Docker off adds no op, so existing template digests don't change. - The factory settings UI shows a warning when Docker is on with less than 2 GB of memory (E2B's recommendation). The platform side (install steps, socket activation, the `-docker` fallback variant) is in mastra-ai/platform#3634. ## Proof - `workspaces/platform-workspace`: 284 tests pass and typecheck is clean. The 5 new docker tests fail when the `repo-template.ts` / `factory-sandbox.ts` changes are stashed. - `factory-ui`: a new MSW test checks that the tip shows only when Docker is on and memory is under 2 GB. - Tested end to end with platform#3634 (details there): socket-activated daemon, `docker compose up` with Redis, `+PONG` from a Node client. ## Unverified - A full factory session on a real E2B template build with the setting toggled from the UI. ## Risk: low Opt-in, and nothing changes while the setting is off. Refs FACT-519 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> <!-- coderabbit-ai-generated:v1 --> ## ELI5 This PR adds an optional Docker setting for factory sandboxes. When enabled, the sandbox template installs Docker, and the settings page warns users if memory is below the recommended 2 GB. ## Changes - Adds `Template().docker()` and an optional `docker` setting for factory sandboxes. Docker is off by default. - Passes the setting to repository templates. When repository access or head resolution fails, resources-only templates keep Docker if it was enabled. - Shows a warning when Docker is on and effective memory is below 2,048 MB. - Adds tests for Docker template operations, fallback behavior, and the memory warning. ## Validation - The author reports 284 passing tests and a clean typecheck. - The author reports end-to-end testing with Docker Compose and Redis, including a `+PONG` response from a Node client. - A full factory session using a real E2B template build and the UI toggle remains unverified. - The author reports that the platform-side prerequisite must be merged and deployed first. Without it, the deployed server rejects the Docker template operation with a 400, which `start()` does not retry. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: mastra-platform[bot] <284800079+mastra-platform[bot]@users.noreply.github.com> Co-authored-by: CalebBarnes <CalebBarnes@users.noreply.github.com> |
||
|
|
2c646b53d0 |
chore: version packages (alpha) (#28399)
This PR was opened by the [Changesets release](https://github.com/changesets/action) GitHub action. When you're ready to do a release, you can merge this and publish to npm yourself or [setup this action to publish automatically](https://github.com/changesets/action#with-publishing). If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated. ⚠️⚠️⚠️⚠️⚠️⚠️ `main` is currently in **pre mode** so this branch has prereleases rather than normal releases. If you want to exit prereleases, run `changeset pre exit` on `main`. ⚠️⚠️⚠️⚠️⚠️⚠️ # Releases > The changelog information of each package has been omitted from this message, as the content exceeds the size limit. ## @mastra/factory@0.25.0-alpha.5 ## @mastra/langsmith@1.4.0-alpha.2 ## @mastra/connect@1.2.0-alpha.2 ## @mastra/core@1.80.0-alpha.4 ## @mastra/playground-ui@66.0.0-alpha.4 ## @mastra/acp@0.4.4-alpha.0 ## @mastra/claude@0.3.4-alpha.0 ## @mastra/cursor@0.3.4-alpha.0 ## @mastra/openai@1.1.4-alpha.0 ## @mastra/auth-auth0@1.2.6-alpha.0 ## @mastra/auth-better-auth@1.1.9-alpha.0 ## @mastra/auth-clerk@1.3.2-alpha.0 ## @mastra/auth-cloud@1.2.8-alpha.0 ## @mastra/auth-firebase@1.1.5-alpha.0 ## @mastra/auth-google@0.1.7-alpha.0 ## @mastra/auth-neon@0.3.5-alpha.0 ## @mastra/auth-okta@0.2.6-alpha.0 ## @mastra/auth-studio@1.3.11-alpha.1 ## @mastra/auth-supabase@1.1.6-alpha.0 ## @mastra/auth-workos@1.6.8-alpha.0 ## @mastra/agent-browser@0.5.5-alpha.0 ## @mastra/browser-viewer@0.2.6-alpha.0 ## @mastra/browser-firecrawl@0.2.5-alpha.1 ## @mastra/stagehand@0.3.7-alpha.1 ## @mastra/discord@1.3.2-alpha.0 ## @mastra/slack@1.8.0-alpha.1 ## @mastra/teams@0.1.3-alpha.0 ## @mastra/telegram@0.2.4-alpha.0 ## @mastra/client-js@1.57.0-alpha.4 ## @mastra/react@1.13.0-alpha.4 ## @mastra/isolated-vm@0.1.4-alpha.0 ## @mastra/quickjs@0.1.5-alpha.0 ## @mastra/deployer-cloud@1.80.0-alpha.4 ## @mastra/deployer-cloudflare@1.2.39-alpha.1 ## @mastra/deployer-netlify@1.2.39-alpha.1 ## @mastra/deployer-sandbox@0.3.24-alpha.1 ## @mastra/deployer-vercel@1.2.39-alpha.1 ## @mastra/voyageai@0.4.3-alpha.0 ## @mastra/longmemeval@1.1.39-alpha.4 ## @mastra/livekit@0.5.2-alpha.0 ## @mastra/opencode@0.1.39-alpha.4 ## @mastra/parallel@0.1.4-alpha.0 ## create-factory@0.3.1-alpha.4 ## @mastra/code-sdk@1.15.1-alpha.5 ## mastracode@0.48.1-alpha.4 ## @mastra/arize@1.3.27-alpha.2 ## @mastra/arthur@0.4.27-alpha.2 ## @mastra/braintrust@1.3.24-alpha.2 ## @mastra/datadog@1.4.19-alpha.2 ## @mastra/deepeval@0.1.21-alpha.2 ## @mastra/laminar@1.3.29-alpha.2 ## @mastra/langfuse@1.6.3-alpha.2 ## @mastra/observability@1.21.1-alpha.2 ## @mastra/otel-bridge@1.5.19-alpha.2 ## @mastra/otel-exporter@1.4.10-alpha.2 ## @mastra/posthog@1.4.4-alpha.2 ## @mastra/sentry@1.2.29-alpha.2 ## @mastra/agent-builder@1.1.31-alpha.2 ## @mastra/auth@1.1.5-alpha.0 ## mastra@1.36.0-alpha.4 ## @mastra/codemod@1.1.8-alpha.0 ## create-mastra@1.36.0-alpha.4 ## @mastra/deployer@1.80.0-alpha.4 ## @mastra/editor@0.16.5-alpha.2 ## @mastra/evals@1.10.9-alpha.0 ## @mastra/fastembed@1.3.5-alpha.2 ## @mastra/loggers@1.3.10-alpha.1 ## @mastra/mcp@2.6.0-alpha.1 ## @mastra/mcp-docs-server@1.3.10-alpha.7 ## @mastra/mcp-registry-registry@1.1.7-alpha.0 ## @mastra/memory@1.39.1-alpha.2 ## @mastra/rag@2.7.1-alpha.0 ## @mastra/schema-compat@1.3.17-alpha.0 ## @mastra/server@1.80.0-alpha.4 ## @mastra/google-cloud-pubsub@1.1.5-alpha.1 ## @mastra/redis-streams@0.6.5-alpha.1 ## @mastra/valkey-streams@0.5.7-alpha.1 ## @mastra/elysia@0.1.20-alpha.4 ## @mastra/express@1.5.24-alpha.4 ## @mastra/fastify@1.5.24-alpha.4 ## @mastra/hono@1.7.22-alpha.4 ## @mastra/koa@1.7.24-alpha.4 ## @mastra/nestjs@0.2.39-alpha.4 ## @mastra/next@0.2.38-alpha.4 ## @mastra/server-adapters-test-suite@0.1.4-alpha.2 ## @mastra/tanstack-start@0.2.38-alpha.4 ## @mastra/astra@1.1.3-alpha.0 ## @mastra/azure-ai-search@0.1.2-alpha.1 ## @mastra/chroma@1.1.5-alpha.0 ## @mastra/clickhouse@1.27.0-alpha.1 ## @mastra/cloudflare@1.7.6-alpha.0 ## @mastra/cloudflare-d1@1.4.5-alpha.1 ## @mastra/convex@1.7.6-alpha.0 ## @mastra/couchbase@1.1.4-alpha.1 ## @mastra/dsql@1.5.5-alpha.0 ## @mastra/duckdb@1.16.0-alpha.1 ## @mastra/dynamodb@1.4.5-alpha.1 ## @mastra/elasticsearch@1.4.6-alpha.1 ## @mastra/lance@1.5.2-alpha.1 ## @mastra/libsql@1.27.1-alpha.0 ## @mastra/mongodb@1.24.1-alpha.1 ## @mastra/mssql@1.10.6-alpha.0 ## @mastra/mysql@0.14.1-alpha.0 ## @mastra/opensearch@1.1.4-alpha.1 ## @mastra/oracledb@0.5.5-alpha.0 ## @mastra/pg@1.33.0-alpha.2 ## @mastra/pinecone@1.1.3-alpha.0 ## @mastra/qdrant@1.1.6-alpha.0 ## @mastra/redis@1.4.12-alpha.1 ## @mastra/s3vectors@1.1.5-alpha.0 ## @mastra/spanner@1.10.1-alpha.1 ## @mastra/turbopuffer@1.2.3-alpha.0 ## @mastra/turso@0.1.18-alpha.0 ## @mastra/upstash@1.5.5-alpha.1 ## @mastra/valkey@0.2.8-alpha.1 ## @mastra/vectorize@1.1.4-alpha.0 ## @mastra/weaviate@0.1.4-alpha.0 ## @mastra/voice-aws-nova-sonic@0.2.6-alpha.0 ## @mastra/voice-azure@0.12.3-alpha.0 ## @mastra/voice-cloudflare@0.13.4-alpha.0 ## @mastra/voice-deepgram@0.13.3-alpha.0 ## @mastra/voice-elevenlabs@0.13.3-alpha.0 ## @mastra/voice-gladia@0.13.3-alpha.0 ## @mastra/voice-google@0.14.4-alpha.0 ## @mastra/voice-google-gemini-live@0.14.18-alpha.0 ## @mastra/voice-inworld@0.4.6-alpha.0 ## @mastra/voice-mistral@0.1.3-alpha.0 ## @mastra/voice-modelslab@0.2.3-alpha.0 ## @mastra/voice-murf@0.13.3-alpha.0 ## @mastra/voice-openai@0.13.4-alpha.0 ## @mastra/voice-openai-realtime@0.14.8-alpha.0 ## @mastra/voice-playai@0.13.3-alpha.0 ## @mastra/voice-sarvam@1.1.4-alpha.0 ## @mastra/voice-speechify@0.14.3-alpha.0 ## @mastra/voice-xai-realtime@0.2.17-alpha.0 ## @mastra/inngest@1.10.8-alpha.3 ## @mastra/temporal@0.4.18-alpha.4 ## @mastra/agentcore@0.5.3-alpha.0 ## @mastra/agentfs@0.2.3-alpha.0 ## @mastra/apple-container@0.5.2-alpha.0 ## @mastra/archil@0.3.2-alpha.0 ## @mastra/azure@0.3.3-alpha.1 ## @mastra/blaxel@0.10.2-alpha.0 ## @mastra/cloudflare-sandbox@0.5.4-alpha.0 ## @mastra/daytona@0.11.4-alpha.0 ## @mastra/docker@0.12.1-alpha.0 ## @mastra/e2b@0.15.1-alpha.1 ## @mastra/e2b-desktop@0.1.10-alpha.1 ## @mastra/files-sdk@0.3.3-alpha.0 ## @mastra/gcs@0.3.5-alpha.1 ## @mastra/google-drive@0.2.4-alpha.0 ## @mastra/mesa@0.3.3-alpha.0 ## @mastra/modal@0.7.3-alpha.0 ## @mastra/platform-workspace@1.10.0-alpha.1 ## @mastra/railway@0.10.2-alpha.1 ## @mastra/s3@0.6.5-alpha.1 ## @mastra/sprites@0.1.2-alpha.0 ## @mastra/vercel@1.6.2-alpha.0 ## @internal/playground@1.36.0-alpha.4 Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> |
||
|
|
f02d3b711e |
refactor(lint): remove redundant returns while preserving exits (#28448)
Enable `no-useless-return` in the shared configuration. Remove 28 terminal bare returns, use 31 explicit switch breaks, and retain 12 value-returning contracts with explicit `undefined`. Preserve 13 intentional guards with local explanations, including index-skipping property reads and the platform availability probe. Reviewed every edit and checked that removed returns and new switch breaks have no effectful continuation before function exit, including cleanup through `finally`. All other source and emitted JavaScript syntax is preserved apart from formatting, and all 2,020 function return types and 3,280 variable binding types in the 59 affected source files are unchanged. The new rule reports zero violations across 15,106 files. CI lint and build, the local 57-task build, Factory build, core typecheck, formatting, and whitespace checks pass. All 756 focused tests pass across stream conversions, idle-loop cleanup, workflow validation, Factory, Factory UI, Playground UI, Datadog, Sentry, Cloudflare, and E2B. Both selected published-package monorepo E2E cases pass. The extended build case covers a missing application `.npmrc` and verifies successful builds with dependency installation both skipped and enabled. The DuckDB CI job also fails two existing capability-list assertions because their expected arrays omit `span-aggregate`. Both failures were reproduced on unchanged base ` |
||
|
|
d9245dd486 |
fix(workspace): return images and PDFs from sandbox filesystems as media in read_file (#28462) | ||
|
|
ce5d4731ee |
chore(deps): update dependencies across the monorepo (#28417)
Co-authored-by: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com> |
||
|
|
0fa30cfbea |
refactor(lint): remove redundant boolean casts and rethrow catches (#27985)
**─────── TLDR ───────**
> The shared Oxlint config now errors on `!!x` inside a condition and on
a `catch` block that only rethrows.
A `catch (err) { throw err; }` reads like something is handled. Nothing
is. `!!x` inside an `if` reads like a deliberate coercion the `if`
already performs. Ten casts and twelve catches across 14 files go.
Nothing reaches a caller differently.
an error thrown inside one of the twelve removed `try` blocks
└─ **unchanged** — same object, same stack, same caller
receives it
| | | |
|---|---|---|
| **+** | `no-useless-catch` | a catch that only rethrows is dead code |
| **+** | `no-extra-boolean-cast` | `if` and `?:` already coerce |
### Decisions
- **no changeset** — no consumer can observe a difference, so no
release; `changeset add --empty` if the red status check bothers you
- **two monorepo e2e assertions for a no-op** — the gate requires
monorepo coverage for any `packages/deployer/` change; they pin the two
reads touched
### Not verified
- [ ] MSSQL, Spanner, Railway, Pinecone and Vectorize paths — their
suites need live services
---
> ██████████████████ **source** `+122 −169` — net −47
> █████ **tests** `+36 −11`
> █ **lint config** `+2`
|
||
|
|
dacb190944 |
chore: version packages (alpha) (#28009)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> |
||
|
|
323c14179f |
chore(security): bump Node.js to 22.23.4 / 24.22.1 (CVE-2026-111497) (#28170)
Node.js Oct 2026 security release (v22.23.4 / v24.22.1): fixes Brotli
OOB write RCE CVE-2026-111497, TLS hostname-verification bypasses, dns
NUL truncation, eMudhra CA distrust, undici/OpenSSL/c-ares updates.
Bumps the Node pins in this repo: 24.22.1 for CI and the default E2B
template, 24.22.1 and 22.23.4 for the starter templates and the
otel-bridge example. `node:22-*` image tags stay floating, so they
resolve to the patched release on their own, and engine ranges are
unchanged.
⚠️ 24h soak rule: nodejs.org dist published 2026-10-21 10:33 UTC. Docker
`node:22.23.4-slim`/`-bookworm-slim` published 2026-10-21 17:38 UTC (24h
at 1:38 PM EDT Oct 22); `node:22.23.4-alpine` published 2026-10-22 02:39
UTC (24h at 10:39 PM EDT Oct 22). Do not merge before then.
After merge, images must be rebuilt and redeployed for the fix to take
effect.
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->
## ELI5
This PR updates Node.js versions used by CI, templates, and E2B sandbox
defaults. It brings them to the versions identified in the PR
description as security updates.
## Changes
- Updates Node.js 24 pins in GitHub Actions workflows and the setup
action from `24.22.0` to `24.22.1`.
- Updates the default Node.js version for E2B templates to `24.22.1`.
- Updates Node.js pins in two templates and an observability example to
`22.23.4` or `24.22.1`.
- Adds a test for the E2B default template’s version-based identity and
a patch changeset for `@mastra/e2b`.
The supplied change summary does not confirm updates to floating
`node:22-*` tags. It does not provide test results or current review
findings.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Co-authored-by: Justin Levine <20596508+jal-co@users.noreply.github.com>
|
||
|
|
95c6e7caf4 |
feat(s3): recognize Neon Object Storage endpoints and document integration (#28032)
Co-authored-by: Rishi Raj Jain <jain71000@gmail.com> |
||
|
|
5d403b6fb4 |
chore(deps): update google cloud (#28012)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> |
||
|
|
40a522c142 |
chore(deps): update build tools (#27997) | ||
|
|
578cb670bd |
feat(platform-workspace): full process manager on PlatformSandbox (#27919)
## What
`PlatformSandbox` now has a full process manager. Background processes:
- stream stdout and stderr while they run, instead of only when they
exit
- can be stopped with `kill()`
- show up in `list()` (running ones, plus exited ones whose output
hasn't been read)
- can be attached to with `get(pid)`, for example after your app
restarts
Processes have no time limit unless you set `timeout`. A long-running
process's output stream reconnects periodically; output written during a
reconnect is lost.
Also:
- **`@mastra/core`:** `SandboxProcessManager.get(pid, { release: false
})` reads an exited process without dismissing it, so one reader doesn't
take output from another (such as the agent's `get_process_output`). The
default is unchanged.
- **`@mastra/e2b`:** `E2BProcessManager` now uses the same shared
implementation. `list()` also returns exited processes until they're
read and shows the command you ran instead of the `/bin/bash -l -c`
wrapper, and a process attached with `get(pid)` is no longer cut off
after 60 seconds.
## How
- The process manager lives in `@internal/workspace`
(`CommandsApiProcessManager`), next to the shared files code. Each
provider supplies one hook, `runCommands(operation, fn)`, that runs a
call with its own retry rules. `E2BProcessManager` is a thin subclass.
- `PlatformSandbox` supplies its own hook and handle. It never replays a
spawn or kill, and maps a destroyed sandbox to `SandboxDestroyedError`.
## Proof
Live, on a real `PlatformSandbox`:
- A `for … echo; sleep 1` loop streamed stdout and stderr while running.
`kill()` → `true`, `wait()` → exit `-1`, it left the running list,
stayed readable with `release: false`, and a second `kill()` → `false`.
- A second `PlatformSandbox` on the same sandbox listed and attached to
the running process and received its new output.
- A 420s process kept streaming past a reconnect and `wait()` returned
its real exit code `5`.
Live, on E2B: the sandbox conformance suite gives identical results with
this branch and with `main`'s process manager (93 passed, 35 skipped).
## Tests
- `@internal/workspace`: shared manager over real host processes
(streaming, exit mapping, kill, stdin, attach, list with exited, no
deadline on attach).
- `@mastra/platform-workspace`: `sandbox-processes.test.ts`
(reconnecting, a process that ended before it could be reattached,
retrying after an unreachable sandbox, destroyed sandbox, no replay,
timeouts).
- `@mastra/e2b`: existing suite plus `list()` returning an unread exited
process.
- `@mastra/core`: `get(pid, { release: false })`.
Each fix has a test that fails without it.
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->
## ELI5
This PR lets sandbox processes run in the background, stream output,
stop, and reconnect later. It also preserves process status and unread
output when sandbox leases change.
## Summary
- Added shared command-based process management in
`@internal/workspace`.
- Added streaming `spawn()`, `list()`, `get()`, `kill()`, stdin support,
timeouts, and process reattachment.
- Kept unread exited processes in `list()` until `get()` consumes them.
- Added `get(pid, { release: false })` to inspect exited processes
without releasing them.
- Updated `E2BProcessManager` to use the shared implementation.
- Added lease-aware E2B command access with authentication retries and
sandbox-destruction handling.
- Added E2B process support to `PlatformSandbox`.
- Kept Railway sandboxes on the existing exec-backed process manager.
- Added documentation, changesets, and tests.
Known limitation: output produced during stream reconnection can be
lost.
Reported validation covers the core process manager, workspace, E2B, and
platform-workspace suites. Reported TypeScript checks for E2B and
platform-workspace and the MDX format check passed.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Co-authored-by: CalebBarnes <CalebBarnes@users.noreply.github.com>
Co-authored-by: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com>
|
||
|
|
fbd27197d7 |
refactor(lint): simplify literal strings and const assertions (#27982)
Enable `no-useless-concat` and `typescript/prefer-as-const` in the
shared Oxlint config. Simplify 15 string concatenations and use const
assertions for four readonly SDK specification versions. Existing
package filters stay as configured.
String contents and expression evaluation order are preserved, and the
SDK fields keep their readonly `v1`–`v4` literal types. A documented
exception keeps NUL-delimited fixture records separate so the next
record’s leading digit cannot become an octal escape.
261 focused tests pass. A fresh scan clears both rules across 14,747
files, and emitted-JavaScript and declaration comparisons preserve
values and public field types. [CI lint and formatting
pass](https://github.com/mastra-ai/mastra/actions/runs/39583377036/job/119166317139)
for `
|
||
|
|
f1ef7854a8 |
chore(deps): update azure-sdk-for-js monorepo (#27995)
This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [@azure/core-auth](https://redirect.github.com/Azure/azure-sdk-for-js/tree/main/sdk/core/core-auth/README.md) ([source](https://redirect.github.com/Azure/azure-sdk-for-js/tree/HEAD/sdk/core/core-auth)) | dependencies | minor | [`^1.7.2` → `^1.11.0`](https://renovatebot.com/diffs/npm/@azure%2fcore-auth/1.10.1/1.11.0) | | [@azure/search-documents](https://redirect.github.com/Azure/azure-sdk-for-js/tree/main/sdk/search/search-documents/README.md) ([source](https://redirect.github.com/Azure/azure-sdk-for-js/tree/HEAD/sdk/search/search-documents)) | dependencies | patch | [`^12.0.0` → `^12.2.0`](https://renovatebot.com/diffs/npm/@azure%2fsearch-documents/12.2.0/12.2.0) | | [@azure/storage-blob](https://redirect.github.com/Azure/azure-sdk-for-js/tree/main/sdk/storage/storage-blob/README.md) ([source](https://redirect.github.com/Azure/azure-sdk-for-js/tree/HEAD/sdk/storage/storage-blob)) | dependencies | minor | [`^12.31.0` → `^12.34.0`](https://renovatebot.com/diffs/npm/@azure%2fstorage-blob/12.31.0/12.34.0) | --- > [!WARNING] > Some dependencies could not be looked up. Check the [Dependency Dashboard](../issues/9505) for more information. --- ### Release Notes <details> <summary>Azure/azure-sdk-for-js (@​azure/core-auth)</summary> ### [`v1.11.0`](https://redirect.github.com/Azure/azure-sdk-for-js/blob/HEAD/sdk/core/core-auth/CHANGELOG.md#1110-2026-07-13) [Compare Source](https://redirect.github.com/Azure/azure-sdk-for-js/compare/@azure/core-auth_1.10.1...@azure/core-auth_1.11.0) ##### Other Changes - Update `engines` to `"node": ">=22.0.0"`. Please refer to our [support policy](https://redirect.github.com/Azure/azure-sdk-for-js/blob/main/SUPPORT.md) for more information on our supported Node.js versions. </details> <details> <summary>Azure/azure-sdk-for-js (@​azure/storage-blob)</summary> ### [`v12.34.0`](https://redirect.github.com/Azure/azure-sdk-for-js/compare/@azure/storage-blob_12.33.0...@azure/storage-blob_12.34.0) [Compare Source](https://redirect.github.com/Azure/azure-sdk-for-js/compare/@azure/storage-blob_12.33.0...@azure/storage-blob_12.34.0) ### [`v12.33.0`](https://redirect.github.com/Azure/azure-sdk-for-js/compare/@azure/storage-blob_12.32.0...@azure/storage-blob_12.33.0) [Compare Source](https://redirect.github.com/Azure/azure-sdk-for-js/compare/@azure/storage-blob_12.32.0...@azure/storage-blob_12.33.0) ### [`v12.32.0`](https://redirect.github.com/Azure/azure-sdk-for-js/compare/@azure/storage-blob_12.31.0...@azure/storage-blob_12.32.0) [Compare Source](https://redirect.github.com/Azure/azure-sdk-for-js/compare/@azure/storage-blob_12.31.0...@azure/storage-blob_12.32.0) </details> --- ### Configuration 📅 **Schedule**: (UTC) - Branch creation - "before 6am every weekday" - Automerge - At any time (no schedule defined) 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 👻 **Immortal**: This PR will be recreated if closed unmerged. Get [config help](https://redirect.github.com/renovatebot/renovate/discussions) if that's undesired. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR has been generated by [Mend Renovate CLI](https://redirect.github.com/renovatebot/renovate). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0NC4xNzUuMSIsInVwZGF0ZWRJblZlciI6IjQ0LjE3NS4xIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJhdXRvbWF0aW9uIl19--> --------- Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> |
||
|
|
b83ffd96a5 |
chore(deps): update dependency railway to ^3.16.0 (#28003)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com> |