0
Fork 0
mirror of https://github.com/mastra-ai/mastra.git synced 2026-11-17 08:44:46 +00:00
Commit graph

199 commits

Author SHA1 Message Date
shreyas-mastra
8d4abc4f88
chore(deps): Vanta 2026-11-12 — raise undici to 8.12.4 / 7.30.2 (#30205) 2026-11-12 07:20:12 -08:00
Ward Peeters
1892f79532
chore: remove stale scripts, workspace entries and package metadata (#29891)
Co-authored-by: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com>
2026-11-10 14:09:52 +01:00
Tyler Barnes
3a01ed16f4
ci: cache what affected-test detection parses, so PR test selection takes ~4s instead of ~40s (#29133)
## What

"Detect affected tests" decides which test files a PR runs. Today it
parses ~15,000 files on every PR run: madge builds the import graph,
then a second pass extracts exported names and symbol edges. That takes
~40s on the 5 vCPU runner, and almost none of those files changed since
the last run.

This change caches the parse results in a file, keyed by a hash of each
file's content:

- `scripts/affected-tests-cache.mjs` stores, per file, only what its own
text decides: the import specifiers precinct finds and the exports and
symbol edges the second pass extracts. Records are keyed by
`sha1(extension + content)`.
- Resolving those specifiers to files is **not** cached. It still runs
live through filing-cabinet with madge's exact options, so a rename, a
moved file or an alias change can't be hidden by a cache hit.
- The cache file records its schema version and the precinct and
typescript versions. If any of them differ, the run starts cold. It is
never wrong.
- `.github/workflows/prebuild.yml` restores the cache before detection
(restore only; PRs never save). The key is
`affected-graph-v1-<os>-<sha>` with the prefix restore-key
`affected-graph-v1-<os>-`, so a PR gets the newest main seed.
- The new `.github/workflows/affected-graph-seed.yml` refreshes the seed
on every push to main. It runs detection once on core's entry point,
which touches the whole graph, then saves the cache. A newer push
cancels an older seed run.

The detection output (selected files, graph nodes, test files) is
unchanged.

## Numbers

Measured on a 5 vCPU / 16 GB container like the CI runner, Node 24.22.1:

| | time |
|---|---|
| Uncached (today) | 40.3s |
| Cached, current seed | 4.0s |
| Cached, seed ~300 commits old | ~13s |
| Seed run on main | ~40s |

The seed file is 14.8 MB raw and 1.7 MB in the actions cache.

Compute: about 36s saved per PR run, against about 90s per merge to main
for the seed run.

## Testing

- Ran detection uncached and cached on 20 recent merged PRs (between 1
and 3,532 files selected): output identical on all 20.
- Renamed `retry-after.ts`, updated its importers and added a new test
file importing the renamed module: identical output (2,849 selected),
the new test is selected and the old path is gone from the graph.
- `packages/core/src/affected-tests-cache.test.ts` covers cold, warm and
changed-import runs. It fails if records are keyed by file name instead
of content.
- `packages/core/src/affected-tests-resolution.test.ts` and
`.github/scripts/ci-routing.test.ts` pass. oxlint and prettier are
clean.

Stacked on #29091 (cancelled runs stop downstream jobs). It will be
retargeted to main once that merges.


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->

## ELI5
The affected-test detector checks which tests may need to run after code
changes. This PR saves file-parsing results so later checks can reuse
them, while still resolving file links against the current code.

## What changed
- Added a content-addressed cache for file parsing. It stores import
specifiers, exported names, and symbol edges, and checks a schema and
extractor-version string before reusing records.
- Kept file resolution live through filing-cabinet and Madge’s existing
options. Updated affected-test detection to use the cache and save
records used during the run.
- Added a workflow to refresh the cache seed on pushes to `main`.
Updated prebuild to restore the seed for affected-test detection.
- Added a test for uncached, cold-cache, and warm-cache graphs,
including after a file’s imports change.

## Validation
Test, lint, formatting, output-comparison, runtime, and review-finding
results: not available.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: remy-builder[bot] <324360501+remy-builder[bot]@users.noreply.github.com>
2026-11-05 20:02:44 +00:00
Tyler Barnes
43f77e77a0
ci: delete the Changed Test Gate (#29099)
## What this does

Deletes the Changed Test Gate workflow, its labeler workflow (which
labels PRs from the gate's result) and `scripts/pr-test-gate/`. The
gate's deployer rule is kept: it moves into Prebuild as a small
`Deployer E2E coverage` job.

## What the gate enforced, and what goes

The gate checked out the base branch, restored the PR's changed test
files on top of it, and ran them. Removing it drops two rules:

1. **Fail-before-fix.** If a PR changed tests, those tests had to fail
against the base branch ("Changed tests passed against the base branch.
They should fail before the PR code is applied."). This rule goes.
2. **External contributors must add tests.** A PR from outside the org
(`AUTHOR_ASSOCIATION` not OWNER/MEMBER/COLLABORATOR) with no changed
test files failed. This rule goes.

A third rule stays: **a PR that changes `packages/deployer/` must also
change `e2e-tests/monorepo/`** (`packages/deployer/AGENTS.md` and
`CHANGELOG.md` exempt; the same-repo Changesets release PR skipped).
It's now `Deployer E2E coverage` in `prebuild.yml`: a `git diff
--name-only` against the merge base, no install or build. It's its own
job rather than a step in `changes`, because a failing `changes` job
would skip every test job. `packages/deployer/AGENTS.md` now names that
job.

## Why dropping 1 and 2 is acceptable

- Neither rule was enforced at merge time: the gate isn't a required
check. The required checks are `Lint` and `Unit and E2E Tests / Merge
Test Reports`, and this PR touches neither.
- Of the gate's last 1000 runs, 8 failed. All 8 were the fail-before-fix
rule firing on tests that passed without the fix; each PR resolved it by
rewriting its tests. Across 812 gate logs from Aug–Oct, every run that
executed tests took the passing path (changed tests failed against base,
as required). So it shaped how a few tests were written, but no run
showed it stopping broken code from merging.
- It costs a runner, a checkout and a test run on every non-draft PR, on
top of Prebuild running the same changed tests against the PR head.
- External contributions still go through maintainer review, which can
ask for tests.

## Test plan

- [x] `rg` for remaining references: only two "former" comments and an
unrelated fixture name
- [x] `pnpm install --frozen-lockfile` works after removing
`scripts/pr-test-gate` (192 projects)
- [x] Deployer check shell logic run locally under `bash -eo pipefail`
with a stubbed diff: deployer-only change fails with the annotation;
deployer + `e2e-tests/monorepo/` passes; `AGENTS.md`/`CHANGELOG.md`-only
passes; no deployer change passes
- [ ] CI on this PR: no Changed Test Gate check appears; `Deployer E2E
coverage` passes


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

<!-- coderabbit-ai-generated:v1 -->

## ELI5

This change removes the old system that checked whether pull requests
added and tested tests. It keeps one focused rule: changes to the
deployer package must include a monorepo E2E test change, with specified
documentation files exempt.

## Changes

- Deleted the Changed Test Gate workflow, its labeler workflow, and the
`scripts/pr-test-gate/` package.
- Added a separate `Deployer E2E coverage` job to Prebuild. The job
checks the merge-base diff and fails when a non-exempt file under
`packages/deployer/` changes without a file under `e2e-tests/monorepo/`.
- Exempted `packages/deployer/AGENTS.md` and
`packages/deployer/CHANGELOG.md` from the coverage check.
- Updated `packages/deployer/AGENTS.md` to refer to the Prebuild job.
- Updated comments in the memory simulation config and two test
link-provider files.

## Validation

The PR description reports that `pnpm install --frozen-lockfile`
succeeded across 192 projects and that the deployer-check shell logic
passed the listed local cases. CI validation is not confirmed: the
description says it is not yet known whether the old check disappears
and the new job passes.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: remy-builder[bot] <324360501+remy-builder[bot]@users.noreply.github.com>
2026-11-05 19:42:33 +00:00
Lennart
ee5a1b0282
docs: make packages frontmatter more precise (#29499)
Co-authored-by: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com>
2026-11-04 17:49:54 -08:00
mastra-platform[bot]
0893940ca2
fix(docs): generate SOURCE_MAP.json from public export names (#29328)
Co-authored-by: Lennart <lekoarts@gmail.com>
2026-11-04 09:58:46 -08:00
shreyas-mastra
f0ad164646
chore(security): Vanta 2026-11-02 - @hono/node-server 2.1.6 (MCP SDK/templates), graphql-scalars 2.0.1, raw-body 4, jose 6 (overrides) (#29199) 2026-11-04 07:58:48 -08:00
Dane - AI (Mastra)
9ce7e350ea
chore(deps): lock file maintenance (#29341)
Co-authored-by: wardpeet <ward@coding-tech.com>
Co-authored-by: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com>
2026-11-04 15:03:55 +01:00
Dane - AI (Mastra)
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 (@&#8203;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
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **Claude Opus 5.5** in
[#&#8203;11578](https://redirect.github.com/vitest-dev/vitest/issues/11578)
[<samp>(28dc1)</samp>](28dc1edfb)
- Handle quoted file names in `--changed`  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11583](https://redirect.github.com/vitest-dev/vitest/issues/11583)
[<samp>(14921)</samp>](14921e962)
- Add `data` to the `import.meta.hot` stub  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11590](https://redirect.github.com/vitest-dev/vitest/issues/11590)
[<samp>(3a828)</samp>](3a8289ac3)
- Set `skip` in `skipIf`, ignore `undefined` options  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11591](https://redirect.github.com/vitest-dev/vitest/issues/11591)
[<samp>(d523a)</samp>](d523a15f2)
- Skip builtin loading in async leak detector  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11598](https://redirect.github.com/vitest-dev/vitest/issues/11598)
[<samp>(fe86a)</samp>](fe86a64c6)
- Keep the import frame in native loader errors  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11599](https://redirect.github.com/vitest-dev/vitest/issues/11599)
[<samp>(9697b)</samp>](9697b3894)
- Run hook cleanups when a later hook fails  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11605](https://redirect.github.com/vitest-dev/vitest/issues/11605)
[<samp>(6c5a4)</samp>](6c5a44720)
- Release mocks of finished test files  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11607](https://redirect.github.com/vitest-dev/vitest/issues/11607)
[<samp>(e9c3d)</samp>](e9c3d72f0)
- Abort all running tests on cancel  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11606](https://redirect.github.com/vitest-dev/vitest/issues/11606)
[<samp>(6621a)</samp>](6621a72d6)
- **browser**:
- Ignore synthetic pagehide events  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11582](https://redirect.github.com/vitest-dev/vitest/issues/11582)
[<samp>(ca081)</samp>](ca0813584)
- Run plugin buildStart on server creation  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11593](https://redirect.github.com/vitest-dev/vitest/issues/11593)
[<samp>(ea611)</samp>](ea611e44c)
- Drop late connections of closed sessions  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11600](https://redirect.github.com/vitest-dev/vitest/issues/11600)
[<samp>(f161e)</samp>](f161e6df2)
- Wait 30s for the browser to close  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11601](https://redirect.github.com/vitest-dev/vitest/issues/11601)
[<samp>(6498b)</samp>](6498b666a)
- Run global setup once with instances  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11596](https://redirect.github.com/vitest-dev/vitest/issues/11596)
[<samp>(8dd67)</samp>](8dd67c262)
- **reporter**:
- End reason `&#&#8203;39;failed&#&#8203;39;` on worker crash  -  by
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;11568](https://redirect.github.com/vitest-dev/vitest/issues/11568)
[<samp>(6ae8e)</samp>](6ae8e89ff)

#####     [View changes on
GitHub](https://redirect.github.com/vitest-dev/vitest/compare/v5.0.4...v5.0.5)

###
[`v5.0.4`](https://redirect.github.com/vitest-dev/vitest/releases/tag/v5.0.4)

[Compare
Source](https://redirect.github.com/vitest-dev/vitest/compare/v5.0.3...v5.0.4)

#####    🚀 Features

- **experimental**:
- Tag cache directories with CACHEDIR.TAG  -  by
[@&#8203;lifeiscontent](https://redirect.github.com/lifeiscontent) in
[#&#8203;11461](https://redirect.github.com/vitest-dev/vitest/issues/11461)
[<samp>(a8ea3)</samp>](a8ea3c8fd)
- Support `test.ui.theme` option  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11499](https://redirect.github.com/vitest-dev/vitest/issues/11499)
[<samp>(1da66)</samp>](1da66405d)
- Highlight selector multiple matches in trace view  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **Claude Opus 5.5** in
[#&#8203;11489](https://redirect.github.com/vitest-dev/vitest/issues/11489)
[<samp>(5abba)</samp>](5abba1e1b)
- Print how many tests were affected and a total when running
`--changed`  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11424](https://redirect.github.com/vitest-dev/vitest/issues/11424)
[<samp>(a2336)</samp>](a23368585)
- Add an option to cache dependencies instead of statically parsing them
 -  by [@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11515](https://redirect.github.com/vitest-dev/vitest/issues/11515)
[<samp>(c0601)</samp>](c06012ac8)
- Add fit and zoom controls to trace viewer  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **Claude Opus 5.5** in
[#&#8203;11490](https://redirect.github.com/vitest-dev/vitest/issues/11490)
[<samp>(f5dd9)</samp>](f5dd99ed0)

#####    🐞 Bug Fixes

- Fail the run on git and location filter errors  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11430](https://redirect.github.com/vitest-dev/vitest/issues/11430)
[<samp>(30d03)</samp>](30d0304d2)
- Enable fsModuleCache by default  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11435](https://redirect.github.com/vitest-dev/vitest/issues/11435)
[<samp>(ad208)</samp>](ad208cc29)
- Track project files and mocks with --changed  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11432](https://redirect.github.com/vitest-dev/vitest/issues/11432)
[<samp>(b0f2b)</samp>](b0f2b3bb9)
- Refactor caching, fix `:` in project and change the shape of `results`
cache  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11453](https://redirect.github.com/vitest-dev/vitest/issues/11453)
[<samp>(9673c)</samp>](9673c49a4)
- Keep full `$` string values when `taskTitleValueFormatTruncate` is 0
 -  by [@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa),
**Hiroshi Ogawa** and **Claude Opus 5.5** in
[#&#8203;11485](https://redirect.github.com/vitest-dev/vitest/issues/11485)
[<samp>(4f7e1)</samp>](4f7e1799b)
- Resolve node builtins in client environments  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11417](https://redirect.github.com/vitest-dev/vitest/issues/11417)
[<samp>(56b31)</samp>](56b319ac6)
- Fix module graph builtin externals after
[#&#8203;11421](https://redirect.github.com/vitest-dev/vitest/issues/11421)
 -  by [@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa),
**Hiroshi Ogawa** and **Claude Opus 5.5** in
[#&#8203;11491](https://redirect.github.com/vitest-dev/vitest/issues/11491)
and
[#&#8203;11421](https://redirect.github.com/vitest-dev/vitest/issues/11421)
[<samp>(008e1)</samp>](008e184cb)
- Wrap module mocks during in-source testing  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11505](https://redirect.github.com/vitest-dev/vitest/issues/11505)
[<samp>(36d19)</samp>](36d19cb00)
- Handle line endings in snapshot  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11522](https://redirect.github.com/vitest-dev/vitest/issues/11522)
[<samp>(4c468)</samp>](4c468aa40)
- Respect root in projects  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11521](https://redirect.github.com/vitest-dev/vitest/issues/11521)
[<samp>(26642)</samp>](26642f793)
- Resolve mocks in directories with spaces  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11539](https://redirect.github.com/vitest-dev/vitest/issues/11539)
[<samp>(caaef)</samp>](caaef9416)
- **api**:
- Publish the api token atomically  -  by
[@&#8203;umairnawaz333](https://redirect.github.com/umairnawaz333) in
[#&#8203;11323](https://redirect.github.com/vitest-dev/vitest/issues/11323)
[<samp>(6f990)</samp>](6f990fef1)
- **browser**:
- Close the mock route interception race  -  by
[@&#8203;cplieger](https://redirect.github.com/cplieger) and
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;8339](https://redirect.github.com/vitest-dev/vitest/issues/8339)
and
[#&#8203;11083](https://redirect.github.com/vitest-dev/vitest/issues/11083)
[<samp>(d6620)</samp>](d6620fae6)
- Allow toHaveTextContent without arguments  -  by
[@&#8203;nomadical](https://redirect.github.com/nomadical) in
[#&#8203;11425](https://redirect.github.com/vitest-dev/vitest/issues/11425)
[<samp>(8ebcf)</samp>](8ebcf5f8a)
- Apply API options without browser config  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10852](https://redirect.github.com/vitest-dev/vitest/issues/10852)
[<samp>(ad055)</samp>](ad055837b)
- Preserve undefined command arguments  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) and
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;11497](https://redirect.github.com/vitest-dev/vitest/issues/11497)
[<samp>(1576d)</samp>](1576d3d89)
- Wait for setup mocks before importing a test file  -  by
[@&#8203;kasperpeulen](https://redirect.github.com/kasperpeulen) in
[#&#8203;11520](https://redirect.github.com/vitest-dev/vitest/issues/11520)
[<samp>(b61d1)</samp>](b61d1ced3)
- Avoid extra scroll outside the iframe  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11523](https://redirect.github.com/vitest-dev/vitest/issues/11523)
[<samp>(662e8)</samp>](662e8a363)
- Run browser instances as workers  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11525](https://redirect.github.com/vitest-dev/vitest/issues/11525)
[<samp>(bf04b)</samp>](bf04b9ccc)
- ⚠️ This can degrade performance if you have a custom `maxWorkers`
setting. Previously, it was applied incorrectly and could lead to Vitest
using too many resources. For example, a lower number would still open
too many browsers. Fixing it means Vitest opens less instances by
default now.
- Open one cdp session per tester  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11542](https://redirect.github.com/vitest-dev/vitest/issues/11542)
[<samp>(69e63)</samp>](69e6369f6)
- Clean up unmocked and pending mocks  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11537](https://redirect.github.com/vitest-dev/vitest/issues/11537)
[<samp>(5c955)</samp>](5c9552173)
- **coverage**:
- V8 browser memory leak between test files  -  by
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;11466](https://redirect.github.com/vitest-dev/vitest/issues/11466)
[<samp>(2297d)</samp>](2297d93a8)
- `allowExternal` fails to include uncovered files  -  by
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;11513](https://redirect.github.com/vitest-dev/vitest/issues/11513)
[<samp>(4ef00)</samp>](4ef000a93)
- Filenames containing brackets incorrectly showing as uncovered  -  by
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;11531](https://redirect.github.com/vitest-dev/vitest/issues/11531)
[<samp>(0fa80)</samp>](0fa80f53c)
- Istanbul coverage wrong when module transform warmups  -  by
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;11529](https://redirect.github.com/vitest-dev/vitest/issues/11529)
[<samp>(9f61d)</samp>](9f61dcca2)
- **deps**:
- Update all non-major dependencies  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11167](https://redirect.github.com/vitest-dev/vitest/issues/11167)
[<samp>(c74e0)</samp>](c74e099a9)
- **expect**:
- Fix `Map` and `Set` deep equality in some assertions  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **Claude Opus 5.5** in
[#&#8203;11402](https://redirect.github.com/vitest-dev/vitest/issues/11402)
[<samp>(b4e79)</samp>](b4e79fd7a)
- Check value in chai-style returned  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11500](https://redirect.github.com/vitest-dev/vitest/issues/11500)
[<samp>(1aca0)</samp>](1aca02a21)
- **mocker**:
- Fix native loader mocking edge cases  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11540](https://redirect.github.com/vitest-dev/vitest/issues/11540)
[<samp>(cd423)</samp>](cd423ba04)
- **pretty-format**:
- Support boxed symbols  -  by
[@&#8203;lehni](https://redirect.github.com/lehni) in
[#&#8203;11445](https://redirect.github.com/vitest-dev/vitest/issues/11445)
and
[#&#8203;11446](https://redirect.github.com/vitest-dev/vitest/issues/11446)
[<samp>(eba44)</samp>](eba44926e)
- **reporters**:
- Junit to strip ANSI sequences from all XML attributes  -  by
[@&#8203;meganemura](https://redirect.github.com/meganemura) and
**Claude Opus 5.5** in
[#&#8203;11407](https://redirect.github.com/vitest-dev/vitest/issues/11407)
[<samp>(e1a73)</samp>](e1a731470)
- **runner**:
- Don't cache failed fixture setups  -  by
[@&#8203;hamed-bavar](https://redirect.github.com/hamed-bavar) in
[#&#8203;11237](https://redirect.github.com/vitest-dev/vitest/issues/11237)
and
[#&#8203;11238](https://redirect.github.com/vitest-dev/vitest/issues/11238)
[<samp>(4ee66)</samp>](4ee66c021)
- **typecheck**:
- Use typescript pool in toTestSpecification  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11451](https://redirect.github.com/vitest-dev/vitest/issues/11451)
[<samp>(5f273)</samp>](5f2739e74)
- **ui**:
- Remove duplicate browser-open call opening two tabs  -  by
[@&#8203;feastyr69](https://redirect.github.com/feastyr69) in
[#&#8203;11356](https://redirect.github.com/vitest-dev/vitest/issues/11356)
and
[#&#8203;11358](https://redirect.github.com/vitest-dev/vitest/issues/11358)
[<samp>(d7e13)</samp>](d7e1315c1)
- Simplify explorer filtering + fix nested tests when search matches a
suite  -  by [@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa),
**Hiroshi Ogawa**, **Codex** and **Claude Opus 5.5** in
[#&#8203;11262](https://redirect.github.com/vitest-dev/vitest/issues/11262)
[<samp>(a627b)</samp>](a627be498)
- Store module graph once per environment  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **Claude Opus 5.5** in
[#&#8203;11421](https://redirect.github.com/vitest-dev/vitest/issues/11421)
[<samp>(af903)</samp>](af903c65e)
- Mount index.html handler on the ui base path  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **Claude Opus 5.5** in
[#&#8203;11517](https://redirect.github.com/vitest-dev/vitest/issues/11517)
[<samp>(1bc24)</samp>](1bc2495c7)
- Center split pane resize handle  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **Claude Opus 5.5** in
[#&#8203;11506](https://redirect.github.com/vitest-dev/vitest/issues/11506)
[<samp>(e658b)</samp>](e658b9b6a)
- **vm**:
- Bind `this` to `module.exports`  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11504](https://redirect.github.com/vitest-dev/vitest/issues/11504)
[<samp>(b618a)</samp>](b618afd5c)

#####    🏎 Performance

- Reuse fsModuleCache when filtering by source  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11428](https://redirect.github.com/vitest-dev/vitest/issues/11428)
[<samp>(7ebd9)</samp>](7ebd95fdd)
- **spy**: Reset only mocks that were called or reconfigured  -  by
[@&#8203;johan-gorter](https://redirect.github.com/johan-gorter) and
**Claude Opus 5.5** in
[#&#8203;11197](https://redirect.github.com/vitest-dev/vitest/issues/11197)
[<samp>(28ef9)</samp>](28ef93df2)

#####     [View changes on
GitHub](https://redirect.github.com/vitest-dev/vitest/compare/v5.0.3...v5.0.4)

###
[`v5.0.3`](https://redirect.github.com/vitest-dev/vitest/releases/tag/v5.0.3)

[Compare
Source](https://redirect.github.com/vitest-dev/vitest/compare/v5.0.2...v5.0.3)

#####    🐞 Bug Fixes

- Isolate `result.status` between `repeats` runs  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **Codex (GPT-6)** in
[#&#8203;11218](https://redirect.github.com/vitest-dev/vitest/issues/11218)
[<samp>(5dbeb)</samp>](5dbebe9e3)
- Don't print an interceptor warning in browser mode  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11377](https://redirect.github.com/vitest-dev/vitest/issues/11377)
[<samp>(15cc0)</samp>](15cc006aa)
- Don't retry when `test.fails` expectedly failed  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **Codex (GPT-6)** in
[#&#8203;11219](https://redirect.github.com/vitest-dev/vitest/issues/11219)
[<samp>(b2458)</samp>](b24585f08)
- Scope cache key generators to projects  -  by
[@&#8203;ecoyoung](https://redirect.github.com/ecoyoung) in
[#&#8203;11281](https://redirect.github.com/vitest-dev/vitest/issues/11281)
and
[#&#8203;11301](https://redirect.github.com/vitest-dev/vitest/issues/11301)
[<samp>(92ba7)</samp>](92ba7fc1d)
- **browser**:
- Delay server `listen` until tests start running  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11366](https://redirect.github.com/vitest-dev/vitest/issues/11366)
[<samp>(7d8ed)</samp>](7d8ed3e9b)
- Check mock path boundaries  -  by
[@&#8203;saryn17](https://redirect.github.com/saryn17), **Ryosei Sato**
and [@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11361](https://redirect.github.com/vitest-dev/vitest/issues/11361)
and
[#&#8203;11362](https://redirect.github.com/vitest-dev/vitest/issues/11362)
[<samp>(1c388)</samp>](1c3888bce)
- Keep config of browser-consumed environments  -  by
[@&#8203;kasperpeulen](https://redirect.github.com/kasperpeulen) and
**Claude** in
[#&#8203;11378](https://redirect.github.com/vitest-dev/vitest/issues/11378)
[<samp>(aafc0)</samp>](aafc0996f)
- Ignore page crash while cancelling  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11386](https://redirect.github.com/vitest-dev/vitest/issues/11386)
[<samp>(7c367)</samp>](7c36748fa)
- `toMatchScreenshot` uses wrong reference on retried tests  -  by
[@&#8203;macarie](https://redirect.github.com/macarie) in
[#&#8203;11393](https://redirect.github.com/vitest-dev/vitest/issues/11393)
[<samp>(c22ab)</samp>](c22aba992)
- **cache**:
- Revalidate imports of cached modules  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11381](https://redirect.github.com/vitest-dev/vitest/issues/11381)
[<samp>(38f98)</samp>](38f98855f)
- **deps**:
- Pin `why-is-node-running` to `3.2.1` to avoid users running into
`ERR_PNPM_TRUST_DOWNGRADE`  -  by
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;11403](https://redirect.github.com/vitest-dev/vitest/issues/11403)
[<samp>(f6c9a)</samp>](f6c9a4977)
- **expect**:
- Pass current equality testers to `expect.extend` asymmetric matchers
 -  by [@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa),
**Hiroshi Ogawa** and **Claude** in
[#&#8203;11401](https://redirect.github.com/vitest-dev/vitest/issues/11401)
[<samp>(3e794)</samp>](3e794a96b)
- **jsdom**:
- Support Blob on jsdom 30.1  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11379](https://redirect.github.com/vitest-dev/vitest/issues/11379)
[<samp>(6c49b)</samp>](6c49b7197)
- **pool**:
- Preserve unique pool ids when `groupOrder` is set  -  by
[@&#8203;mtorp](https://redirect.github.com/mtorp) in
[#&#8203;11392](https://redirect.github.com/vitest-dev/vitest/issues/11392)
[<samp>(50312)</samp>](50312ebb4)
- **ui**:
- Split-pane handle overlapping iframe  -  by
[@&#8203;macarie](https://redirect.github.com/macarie) in
[#&#8203;11221](https://redirect.github.com/vitest-dev/vitest/issues/11221)
[<samp>(f91db)</samp>](f91db0dfd)
- **vitest**:
- Remove root temp dir on close  -  by
[@&#8203;abhinav-phi](https://redirect.github.com/abhinav-phi) in
[#&#8203;11248](https://redirect.github.com/vitest-dev/vitest/issues/11248)
[<samp>(7c711)</samp>](7c7119cf7)
- **vm**:
- Do not optimize deps from index.html  -  by
[@&#8203;ezefernandezyf](https://redirect.github.com/ezefernandezyf),
**Hiroshi Ogawa** and **Codex (GPT-6)** in
[#&#8203;11329](https://redirect.github.com/vitest-dev/vitest/issues/11329)
and
[#&#8203;11360](https://redirect.github.com/vitest-dev/vitest/issues/11360)
[<samp>(caf28)</samp>](caf2887de)
- Don't reuse scripts across vite environments  -  by
[@&#8203;MO2k4](https://redirect.github.com/MO2k4), **Martin Oehlert**
and **Claude** in
[#&#8203;11395](https://redirect.github.com/vitest-dev/vitest/issues/11395)
[<samp>(346d3)</samp>](346d3896b)

#####     [View changes on
GitHub](https://redirect.github.com/vitest-dev/vitest/compare/v5.0.2...v5.0.3)

###
[`v5.0.2`](https://redirect.github.com/vitest-dev/vitest/releases/tag/v5.0.2)

[Compare
Source](https://redirect.github.com/vitest-dev/vitest/compare/v5.0.1...v5.0.2)

#####    🐞 Bug Fixes

- Bind `process` in case global is overwritten  -  by
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;11343](https://redirect.github.com/vitest-dev/vitest/issues/11343)
[<samp>(0b792)</samp>](0b79231ad)
- **detect-async-leaks**:
- Ignore `process.stdio` handles  -  by
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;11333](https://redirect.github.com/vitest-dev/vitest/issues/11333)
[<samp>(0fd6b)</samp>](0fd6b9790)
- **expect**:
- Fix `toMatchObject` with asymmetric matchers  -  by
[@&#8203;ShreeBohara](https://redirect.github.com/ShreeBohara), **Claude
Opus 5**, [@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa),
**Hiroshi Ogawa** and **Codex (GPT-5)** in
[#&#8203;11100](https://redirect.github.com/vitest-dev/vitest/issues/11100)
[<samp>(42523)</samp>](42523289e)
- **jsdom**:
- Fix `Request` with `Blob` body on jsdom 28+  -  by
[@&#8203;harshit-d3v](https://redirect.github.com/harshit-d3v) in
[#&#8203;11295](https://redirect.github.com/vitest-dev/vitest/issues/11295)
[<samp>(d1c3e)</samp>](d1c3ecc93)
- **reporter**:
- `agent` to respect `--silent`  -  by
[@&#8203;Raj4478](https://redirect.github.com/Raj4478) and
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;11271](https://redirect.github.com/vitest-dev/vitest/issues/11271)
[<samp>(5b95e)</samp>](5b95efb6d)
- **reporters**:
- Handle concurrent `createReport` calls  -  by
[@&#8203;7rulnik](https://redirect.github.com/7rulnik) in
[#&#8203;11278](https://redirect.github.com/vitest-dev/vitest/issues/11278)
[<samp>(e8e55)</samp>](e8e556ff7)
- `hanging-process` to use ESM entrypoint  -  by
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;11316](https://redirect.github.com/vitest-dev/vitest/issues/11316)
[<samp>(4e91e)</samp>](4e91e5668)
- **spy**:
- Fix stack overflow when spying `Set.prototype.add`  -  by
[@&#8203;fengmk2](https://redirect.github.com/fengmk2) in
[#&#8203;11299](https://redirect.github.com/vitest-dev/vitest/issues/11299)
[<samp>(a0a93)</samp>](a0a939653)
- **ui**:
- Persist authentication cookie beyond current browser session  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **OpenCode (gpt-5.6-sol)** in
[#&#8203;11066](https://redirect.github.com/vitest-dev/vitest/issues/11066)
[<samp>(f8819)</samp>](f88195e16)

#####     [View changes on
GitHub](https://redirect.github.com/vitest-dev/vitest/compare/v5.0.1...v5.0.2)

###
[`v5.0.1`](https://redirect.github.com/vitest-dev/vitest/releases/tag/v5.0.1)

[Compare
Source](https://redirect.github.com/vitest-dev/vitest/compare/v5.0.0...v5.0.1)

#####    🚀 Features

- **ui**:
- Move trace attempts selector to viewer header  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **Codex** in
[#&#8203;11189](https://redirect.github.com/vitest-dev/vitest/issues/11189)
[<samp>(5dc4b)</samp>](5dc4b5c92)
- Add focused trace view layout mode  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa**, **OpenCode (gpt-5.6-sol)** and **Codex** in
[#&#8203;11190](https://redirect.github.com/vitest-dev/vitest/issues/11190)
[<samp>(376dc)</samp>](376dc3bc1)

#####    🐞 Bug Fixes

- Exit 1 when vitest list fails collection  -  by
[@&#8203;hamed-bavar](https://redirect.github.com/hamed-bavar) in
[#&#8203;11145](https://redirect.github.com/vitest-dev/vitest/issues/11145)
and
[#&#8203;11146](https://redirect.github.com/vitest-dev/vitest/issues/11146)
[<samp>(6108b)</samp>](6108b8197)
- Keep parse error details in static collection  -  by
[@&#8203;hamed-bavar](https://redirect.github.com/hamed-bavar) in
[#&#8203;11150](https://redirect.github.com/vitest-dev/vitest/issues/11150)
and
[#&#8203;11151](https://redirect.github.com/vitest-dev/vitest/issues/11151)
[<samp>(7c818)</samp>](7c818153a)
- Avoid recursive prototype in automocking  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11195](https://redirect.github.com/vitest-dev/vitest/issues/11195)
[<samp>(99fc5)</samp>](99fc52591)
- Prevent false Vitest import resolution  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11196](https://redirect.github.com/vitest-dev/vitest/issues/11196)
[<samp>(b426c)</samp>](b426c1976)
- Keep metadata file when clearing the cache  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11199](https://redirect.github.com/vitest-dev/vitest/issues/11199)
[<samp>(73614)</samp>](73614654a)
- Correct typos in error message and comments  -  by
[@&#8203;shinji00222](https://redirect.github.com/shinji00222) and
**Shinji** in
[#&#8203;11187](https://redirect.github.com/vitest-dev/vitest/issues/11187)
[<samp>(115c3)</samp>](115c3f6d2)
- Resolve ResolvedConfig exactOptionalPropertyTypes errors  -  by
[@&#8203;LukeAbby](https://redirect.github.com/LukeAbby) in
[#&#8203;11175](https://redirect.github.com/vitest-dev/vitest/issues/11175)
[<samp>(498fb)</samp>](498fbe922)
- Share the server on self-referencing `extends`  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11034](https://redirect.github.com/vitest-dev/vitest/issues/11034)
[<samp>(23dda)</samp>](23dda738c)
- Warn when deprecated `deps.optimizer.web` is used  -  by
[@&#8203;im10furry](https://redirect.github.com/im10furry) in
[#&#8203;11214](https://redirect.github.com/vitest-dev/vitest/issues/11214)
[<samp>(2ce29)</samp>](2ce29d5fa)
- **browser**:
- Avoid double quotes in `config.define`  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11198](https://redirect.github.com/vitest-dev/vitest/issues/11198)
[<samp>(972e2)</samp>](972e24bab)
- **doctor**:
- Measure vm pools for custom environments  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11212](https://redirect.github.com/vitest-dev/vitest/issues/11212)
[<samp>(91ab1)</samp>](91ab1588c)
- **expect**:
- Correct return value in `toMatchAriaSnapshot`  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11208](https://redirect.github.com/vitest-dev/vitest/issues/11208)
[<samp>(c119b)</samp>](c119be016)
- **fakeTimers**:
- Force `queueMicrotask` and `nextTick` in `toNotFake`  -  by
[@&#8203;kingmakeruix](https://redirect.github.com/kingmakeruix),
**kingmakeruix**, **Hiroshi Ogawa**, **Codex** and
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa) in
[#&#8203;11261](https://redirect.github.com/vitest-dev/vitest/issues/11261)
[<samp>(a47d7)</samp>](a47d7908f)
- **snapshot**:
- Report obsolete keys next to skipped tests  -  by
[@&#8203;hamed-bavar](https://redirect.github.com/hamed-bavar),
**Hiroshi Ogawa** and **OpenCode (gpt-5.6-sol)** in
[#&#8203;11157](https://redirect.github.com/vitest-dev/vitest/issues/11157)
and
[#&#8203;11158](https://redirect.github.com/vitest-dev/vitest/issues/11158)
[<samp>(17e2b)</samp>](17e2b22dd)
- **types**:
- Make public declarations self-contained  -  by
[@&#8203;ZoeySigel](https://redirect.github.com/ZoeySigel) in
[#&#8203;11141](https://redirect.github.com/vitest-dev/vitest/issues/11141)
[<samp>(45546)</samp>](455466c16)
- **ui**:
- Fix collapse/expand suite with file name search  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **Codex** in
[#&#8203;11260](https://redirect.github.com/vitest-dev/vitest/issues/11260)
[<samp>(0a712)</samp>](0a7122daa)
- Fix explorer file summary count  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa**, **OpenCode (gpt-5.6-sol)** and **Codex** in
[#&#8203;11125](https://redirect.github.com/vitest-dev/vitest/issues/11125)
[<samp>(05982)</samp>](05982297d)
- **utils**:
- Fix `deepMerge` to handle prototype  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **Codex** in
[#&#8203;11215](https://redirect.github.com/vitest-dev/vitest/issues/11215)
[<samp>(4944c)</samp>](4944cf498)

#####     [View changes on
GitHub](https://redirect.github.com/vitest-dev/vitest/compare/v5.0.0...v5.0.1)

###
[`v5.0.0`](https://redirect.github.com/vitest-dev/vitest/releases/tag/v5.0.0)

[Compare
Source](https://redirect.github.com/vitest-dev/vitest/compare/v4.1.12...v5.0.0)

Vitest 5 is officially out! This release focuses on performance and
brings a lot of new features while fixing long-standing bugs. See our
[blog post](https://vitest.dev/blog/vitest-5.html) for the official
announcement.

#####    🚨 Breaking Changes

- Replace `loupe.inspect` with pretty-format  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Claude Opus
5 (1M context)** and **OpenAI Codex** in
[#&#8203;9609](https://redirect.github.com/vitest-dev/vitest/issues/9609)
[<samp>(3f802)</samp>](3f802da4b)
- Remove quotes from string values in `test.for/each` title `$` variable
(take 2)  -  by [@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa)
in
[#&#8203;10170](https://redirect.github.com/vitest-dev/vitest/issues/10170)
[<samp>(04d37)</samp>](04d37e9d7)
- Default `attachmentsDir` from `.vitest-attachements/` to
`.vitest/attachments/`  -  by
[@&#8203;MdSadiqMd](https://redirect.github.com/MdSadiqMd) in
[#&#8203;10186](https://redirect.github.com/vitest-dev/vitest/issues/10186)
[<samp>(1ba73)</samp>](1ba7338c3)
- Remove `sequential` test/suite options in favor of `concurrent`  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa) and **OpenAI
Codex** in
[#&#8203;10198](https://redirect.github.com/vitest-dev/vitest/issues/10198)
[<samp>(9229f)</samp>](9229f2edc)
- Represent locator as an object instead of a string  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10212](https://redirect.github.com/vitest-dev/vitest/issues/10212)
[<samp>(80f07)</samp>](80f07edf6)
- Inline `expect` package  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10221](https://redirect.github.com/vitest-dev/vitest/issues/10221)
[<samp>(ad162)</samp>](ad16223e7)
- Remove deprecated entry points  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10222](https://redirect.github.com/vitest-dev/vitest/issues/10222)
[<samp>(994c6)</samp>](994c6ddb9)
- Require Node.js 22 and Vite 6.4  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10178](https://redirect.github.com/vitest-dev/vitest/issues/10178)
[<samp>(38762)</samp>](3876283e8)
- Fail `expect.poll` when function didn't resolve in time  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa) and **OpenAI
Codex** in
[#&#8203;10233](https://redirect.github.com/vitest-dev/vitest/issues/10233)
[<samp>(4df04)</samp>](4df048c11)
- Throw an error if hoistable methods are outside the top level scope
 -  by [@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10460](https://redirect.github.com/vitest-dev/vitest/issues/10460)
[<samp>(d0b4f)</samp>](d0b4fddcb)
- `toHaveTextContent` is strict, add `toMatchTextContent` as alternative
 -  by [@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10473](https://redirect.github.com/vitest-dev/vitest/issues/10473)
[<samp>(18f30)</samp>](18f303079)
- Don't lookup config file from ancestor directories  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **OpenAI
Codex** and **Hiroshi Ogawa** in
[#&#8203;10428](https://redirect.github.com/vitest-dev/vitest/issues/10428)
[<samp>(945d9)</samp>](945d9090e)
- Inline `@vitest/runner` package, do not publish it anymore  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10511](https://redirect.github.com/vitest-dev/vitest/issues/10511)
[<samp>(6d6e4)</samp>](6d6e46b1e)
- Allow mutating happy-dom/jsdom window object  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **OpenAI Codex** in
[#&#8203;10373](https://redirect.github.com/vitest-dev/vitest/issues/10373)
[<samp>(206e8)</samp>](206e8cff8)
- Expose `concurrencyId`/`workerId` on TestModule's diagnostics, make id
1-based  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10516](https://redirect.github.com/vitest-dev/vitest/issues/10516)
[<samp>(bdd98)</samp>](bdd985433)
- Add `screenshotDirectory` config to `browser.expect.toMatchScreenshot`
 -  by [@&#8203;macarie](https://redirect.github.com/macarie) in
[#&#8203;10592](https://redirect.github.com/vitest-dev/vitest/issues/10592)
[<samp>(a60de)</samp>](a60ded0fb)
- Update `@sinonjs/fake-timers` and support mocking `Temporal`  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **OpenCode (gpt-5.6-sol)** in
[#&#8203;10654](https://redirect.github.com/vitest-dev/vitest/issues/10654)
[<samp>(f8b15)</samp>](f8b1532fe)
- Remove webdriverio package  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10675](https://redirect.github.com/vitest-dev/vitest/issues/10675)
[<samp>(5fed6)</samp>](5fed68f72)
- Clear mocks by default before each test  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10613](https://redirect.github.com/vitest-dev/vitest/issues/10613)
[<samp>(0f646)</samp>](0f6463bf2)
- Don't emit localStorage warnings on Node 26, fail gracefully when
worker fails to start  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10293](https://redirect.github.com/vitest-dev/vitest/issues/10293)
[<samp>(334ed)</samp>](334edef92)
- Separate config resolution from the server creation  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10554](https://redirect.github.com/vitest-dev/vitest/issues/10554)
[<samp>(1c0ec)</samp>](1c0ec3444)
- Inline projects extend the root config by default  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10750](https://redirect.github.com/vitest-dev/vitest/issues/10750)
[<samp>(fec00)</samp>](fec001ad3)
- Enable mocking Temporal without fake timers  -  by
[@&#8203;fabon-f](https://redirect.github.com/fabon-f), **Hiroshi
Ogawa** and **OpenCode (gpt-5.6-sol)** in
[#&#8203;10757](https://redirect.github.com/vitest-dev/vitest/issues/10757)
[<samp>(ac2d4)</samp>](ac2d46b42)
- Support nested projects  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10846](https://redirect.github.com/vitest-dev/vitest/issues/10846)
[<samp>(ec367)</samp>](ec367cf2a)
- Use `>` as separator in `-t`, calculate `only` once  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10686](https://redirect.github.com/vitest-dev/vitest/issues/10686)
[<samp>(a0b20)</samp>](a0b20bc86)
- Fail the test when an asynchronous assertion is not awaited  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10868](https://redirect.github.com/vitest-dev/vitest/issues/10868)
[<samp>(86d4a)</samp>](86d4a9da9)
- Share the Vite server between inline projects  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10848](https://redirect.github.com/vitest-dev/vitest/issues/10848)
[<samp>(d87c9)</samp>](d87c96ee4)
- Parse files statically in vitest list by default  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11088](https://redirect.github.com/vitest-dev/vitest/issues/11088)
[<samp>(51e94)</samp>](51e949416)
- **benchmark**:
- Rewrite the public API  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10113](https://redirect.github.com/vitest-dev/vitest/issues/10113)
[<samp>(19f6e)</samp>](19f6e8947)
- **browser**:
- Iframe scale  -  by
[@&#8203;macarie](https://redirect.github.com/macarie) in
[#&#8203;9745](https://redirect.github.com/vitest-dev/vitest/issues/9745)
[<samp>(b6398)</samp>](b639852cc)
- Enable `locators.exact` by default  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10430](https://redirect.github.com/vitest-dev/vitest/issues/10430)
[<samp>(e2032)</samp>](e203202f9)
- Require `sessionId` for orchestrator html request  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **OpenAI Codex** in
[#&#8203;10522](https://redirect.github.com/vitest-dev/vitest/issues/10522)
[<samp>(79b7d)</samp>](79b7d8fcc)
- Save failure screenshots in `attachmentsDir`  -  by
[@&#8203;macarie](https://redirect.github.com/macarie) in
[#&#8203;10917](https://redirect.github.com/vitest-dev/vitest/issues/10917)
[<samp>(3b5bb)</samp>](3b5bbd8b4)
- **coverage**:
- `include/exclude` globs too eager  -  by
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;9818](https://redirect.github.com/vitest-dev/vitest/issues/9818)
[<samp>(edacb)</samp>](edacb0fd4)
- Allow `thresholds.perFile` to accept an object  -  by
[@&#8203;vladlenskiy](https://redirect.github.com/vladlenskiy) and
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;10190](https://redirect.github.com/vitest-dev/vitest/issues/10190)
[<samp>(13b78)</samp>](13b78d98b)
- **expect**:
- Fix `toThrow("")` behavior by reverting
[#&#8203;6710](https://redirect.github.com/vitest-dev/vitest/issues/6710)
 -  by [@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa) in
[#&#8203;9643](https://redirect.github.com/vitest-dev/vitest/issues/9643)
and
[#&#8203;6710](https://redirect.github.com/vitest-dev/vitest/issues/6710)
[<samp>(6c3e4)</samp>](6c3e4bdbf)
- **mocker**:
- Deserialize automock as automock  -  by
[@&#8203;nami8824](https://redirect.github.com/nami8824) in
[#&#8203;10192](https://redirect.github.com/vitest-dev/vitest/issues/10192)
[<samp>(2f892)</samp>](2f892712d)
- **reporters**:
- `blob` reporter and `--merge-reports` default to `.vitest/blob/`  - 
by [@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;10232](https://redirect.github.com/vitest-dev/vitest/issues/10232)
[<samp>(d22b0)</samp>](d22b029ae)
- Write json and junit reporter output files to `.vitest` by default  - 
by [@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa**, **OpenCode (gpt-5.6-sol)** and
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;10621](https://redirect.github.com/vitest-dev/vitest/issues/10621)
[<samp>(58577)</samp>](58577290a)
- **spy**:
- Preserve class mock prototype methods on instances  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10910](https://redirect.github.com/vitest-dev/vitest/issues/10910)
[<samp>(6093d)</samp>](6093d764a)
- **types**:
- Add better promise support in expects and matchers  -  by
[@&#8203;samchungy](https://redirect.github.com/samchungy) and
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;8266](https://redirect.github.com/vitest-dev/vitest/issues/8266)
[<samp>(41f55)</samp>](41f551bce)
- **ui**:
- Harden UI API access  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Hiroshi
Ogawa** and **OpenAI Codex** in
[#&#8203;10583](https://redirect.github.com/vitest-dev/vitest/issues/10583)
[<samp>(4c26d)</samp>](4c26d7675)
- Change html reporter default output to `.vitest`  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa) and **Hiroshi
Ogawa** in
[#&#8203;10620](https://redirect.github.com/vitest-dev/vitest/issues/10620)
[<samp>(29c36)</samp>](29c364d50)

#####    🚀 Features

- Add `createReport` and `.vitest` report directory convention  -  by
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;9993](https://redirect.github.com/vitest-dev/vitest/issues/9993)
[<samp>(72a6d)</samp>](72a6dc257)
- Expose default reporters through `configDefaults.reporters`  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa) and **Claude
Opus 5 (1M context)** in
[#&#8203;10219](https://redirect.github.com/vitest-dev/vitest/issues/10219)
[<samp>(083f6)</samp>](083f6bdd6)
- Support merge reports for non-sharded multi-environment runs (take 2)
 -  by [@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa),
**Claude Opus 5 (1M context)**, **OpenAI Codex** and
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;10031](https://redirect.github.com/vitest-dev/vitest/issues/10031)
[<samp>(e60b2)</samp>](e60b2f49e)
- Add `logger.formatError`  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa) and **OpenAI
Codex** in
[#&#8203;10268](https://redirect.github.com/vitest-dev/vitest/issues/10268)
[<samp>(2c5f3)</samp>](2c5f3ee2f)
- Support typescript build mode  -  by
[@&#8203;lishaduck](https://redirect.github.com/lishaduck) in
[#&#8203;9870](https://redirect.github.com/vitest-dev/vitest/issues/9870)
[<samp>(106da)</samp>](106da5896)
- Add toggable `injectCjsGlobals` option  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10709](https://redirect.github.com/vitest-dev/vitest/issues/10709)
[<samp>(82671)</samp>](826714ece)
- Promote fsModuleCache to a top-level option  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10734](https://redirect.github.com/vitest-dev/vitest/issues/10734)
[<samp>(78ed7)</samp>](78ed73afd)
- Support non-ascii characters in `for/each` title placeholders  -  by
[@&#8203;k-yle](https://redirect.github.com/k-yle) in
[#&#8203;10773](https://redirect.github.com/vitest-dev/vitest/issues/10773)
[<samp>(15e0a)</samp>](15e0af953)
- Report the duration breakdown as percentages  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) and
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in
[#&#8203;10820](https://redirect.github.com/vitest-dev/vitest/issues/10820)
[<samp>(c67d2)</samp>](c67d296f4)
- Promote parseSpecifications out of experimental  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11087](https://redirect.github.com/vitest-dev/vitest/issues/11087)
[<samp>(b628c)</samp>](b628cb680)
- Promote clearCache out of experimental  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;11086](https://redirect.github.com/vitest-dev/vitest/issues/11086)
[<samp>(d4fe1)</samp>](d4fe1986f)
- **api**:
- Expose logs recorded during the test  -  by
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10277](https://redirect.github.com/vitest-dev/vitest/issues/10277)
[<samp>(cba20)</samp>](cba2036a1)
- **benchmark**:
- Add pluggable benchmark provider API  -  by
[@&#8203;GuillaumeLagrange](https://redirect.github.com/GuillaumeLagrange)
and [@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10799](https://redirect.github.com/vitest-dev/vitest/issues/10799)
[<samp>(86c70)</samp>](86c700ed8)
- **browser**:
- Export aria tree utils  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa) in
[#&#8203;10171](https://redirect.github.com/vitest-dev/vitest/issues/10171)
[<samp>(c3423)</samp>](c3423014c)
- Support dom snapshot trace view  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa), **Claude Opus
5 (1M context)** and **OpenAI Codex** in
[#&#8203;10102](https://redirect.github.com/vitest-dev/vitest/issues/10102)
[<samp>(7eddd)</samp>](7eddd273d)
- Provide project reference in `ToMatchScreenshotResolvePath`  -  by
[@&#8203;macarie](https://redirect.github.com/macarie) and
[@&#8203;sheremet-va](https://redirect.github.com/sheremet-va) in
[#&#8203;10138](https://redirect.github.com/vitest-dev/vitest/issues/10138)
[<samp>(16654)</samp>](166544e39)
- Show aria tree on locator element error  -  by
[@&#8203;hi-ogawa](https://redirect.github.com/hi-ogawa) and **OpenAI
Codex** in
[#&#8203;10257](https://redirect.github.com/vitest-dev/vitest/issues/10257)
[<samp>(04f04)</samp>](04f04cdd1)
- Support custom `kind` in `page.mark`  -  by
[@&#8203;AriPerkkio](https://redirect.github.com/AriPerkkio) in

> [!IMPORTANT]
> ✂ PR body was truncated to here.


</details>

---

### Configuration

📅 **Schedule**: (UTC)

- Branch creation
  - "before 6am every weekday"
- Automerge
  - At any time (no schedule defined)

🚦 **Automerge**: Enabled.

♻ **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:eyJjcmVhdGVkSW5WZXIiOiI0NC4xOTguMiIsInVwZGF0ZWRJblZlciI6IjQ0LjIwNS4xIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJhdXRvbWF0aW9uIl19-->

---------

Co-authored-by: wardpeet <ward@coding-tech.com>
Co-authored-by: mastracode <284800079+mastra-platform[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-11-03 20:18:21 +01:00
Dane - AI (Mastra)
47a6cd82e5
chore(deps): update ai sdk (#29242)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-11-03 16:12:54 +01:00
Dane - AI (Mastra)
278ecceb2d
chore(deps): update ai sdk (#28928)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-10-30 17:19:19 +01:00
Dane - AI (Mastra)
f6cd11f348
chore(deps): lock file maintenance (#28672)
This PR contains the following updates:

| Update | Change |
|---|---|
| lockFileMaintenance | All locks refreshed |

---

> [!WARNING]
> Some dependencies could not be looked up. Check the [Dependency
Dashboard](../issues/9505) for more information.

🔧 This Pull Request updates lock files to use the latest dependency
versions.

---

### Configuration

📅 **Schedule**: (UTC)

- Branch creation
  - "before 6am on wednesday"
- Automerge
  - At any time (no schedule defined)

🚦 **Automerge**: Enabled.

♻ **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:eyJjcmVhdGVkSW5WZXIiOiI0NC4xOTAuMCIsInVwZGF0ZWRJblZlciI6IjQ0LjE5MC4wIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJhdXRvbWF0aW9uIl19-->

---------

Co-authored-by: mastra-platform[bot] <284800079+mastra-platform[bot]@users.noreply.github.com>
2026-10-29 10:02:15 +00:00
shreyas-mastra
6deb7c0a1e
chore(security): Vanta 2026-10-28 - qs 6.16.1, @modelcontextprotocol/node 2.1.1 floors (#28716)
Refs mastra-ai/platform#2931

Vanta remediation pass for 2026-10-28. It follows #28325, which has
merged.

## 2026-10-28 update
Today's live Vanta export added 3 advisory IDs on `mastra-ai/mastra`
(GitHub/Dependabot). This PR fixes the two that have a published fix and
leaves deepmerge, which has none.

| Package | From → To | Finding | Where | How |
|---|---|---|---|---|
| qs | 6.16.0 → 6.16.1 | CVE-2026-110816 / GHSA-6pq8-jhm2-2vcw (Medium
×4) | root `pnpm-lock.yaml`, 9 `e2e-tests/*` lockfiles,
`scripts/gh-issue-triage/package-lock.json` | Raised the existing floors
`qs@>=6.7.0 <6.16.0: 6.16.0` → `<6.16.1: 6.16.1` and `'qs@<6.7.0':
6.16.0` → `6.16.1`. Raised the npm override in gh-issue-triage. |
| @modelcontextprotocol/node | 2.0.0 → 2.1.1 | GHSA-f897-62hf-6gxq (High
×2; HTTP transports had no body-size or batch-length limit) | root
`pnpm-lock.yaml` (published `@mastra/mcp` 1.18.0, used as `mcp-legacy`),
`scripts/gh-issue-triage/package-lock.json` | New pnpm override
`'@modelcontextprotocol/node@>=2.0.0 <2.1.0': 2.1.1` and a new npm
override in gh-issue-triage. I used 2.1.1 rather than 2.1.2 because
2.1.2 needs a `@modelcontextprotocol/server` peer of `^2.4.0`, while
`@mastra/mcp` 1.18 resolves server 2.3.1. `packages/mcp` itself already
uses node 2.1.2. |

- Both versions are older than the 1-day `minimumReleaseAge`: qs 6.16.1
was published 10-14 and node 2.1.1 on 10-02. I did not use qs 6.16.2
(10-27), which is too new.
- No floors or overrides were removed; existing ones were only raised.
- `pnpm install --frozen-lockfile --lockfile-only` passes at the root.
Each nested e2e workspace was regenerated with `pnpm install
--lockfile-only`.
- Added the empty changeset
`.changeset/vanta-2026-10-28-security-floors.md`. No published package
changes.
- After this change, osv-scanner over all 33 lockfiles reports only the
documented leftovers:
  - zod 3.25.76 (zod v3 compat line on purpose)
  - ai 4.3.19 / `@ai-sdk/provider-utils` 2.2.8 (vendored v4 line)
- `@azure/msal-node` 5.6.0 / 6.0.1 (fix 7.1.0 needs majors in identity
and teams)
  - `@opentelemetry/core` 1.30.1 (needs pubsub 6)
  - extract-zip 2.0.1 (no patched release)
- deepmerge 4.3.1 (CVE-2026-93753 / GHSA-gcqx-w48m-w2h4; no patched
release, 4.3.1 is the latest)


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->

## ELI5

This PR updates dependency rules and package versions to use newer
releases, including security fixes for `qs` and
`@modelcontextprotocol/node`. It also updates AI SDK dependencies and
does not include published package changes.

## Summary

- Raise the `qs` override target to `6.16.1` in the root and e2e
workspaces and in `scripts/gh-issue-triage`.
- Add an `@modelcontextprotocol/node` override at `2.1.1` in the root
workspace and `scripts/gh-issue-triage`.
- Update AI SDK dependency versions across package manifests and add a
changeset describing the provider-utils update.
- Add an empty changeset for the security-only dependency updates.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

## Update 2026-10-28 (afternoon)
- Merged origin/main (clean).
- Bumped the AI SDK v5 compat line from @ai-sdk/provider-utils 3.0.41 to
3.0.42 (patch, published 2026-10-21; it blocks `.internal` hostnames in
download URL validation and encodes provider-returned IDs in request
paths). This addresses the Aikido /mastra Highs AIKIDO-2026-10990 and
AIKIDO-2026-10981:
- ai 5.0.277 → 5.0.282, @ai-sdk/gateway 2.0.168 → 2.0.173 (vendored
ai_v5)
- anthropic 2.0.109 → 2.0.110, google 2.0.103 → 2.0.106, groq 2.0.58 →
2.0.59, openai 2.0.135 → 2.0.137, openai-compatible 1.0.58 → 1.0.59, xai
2.0.99 → 2.0.100
- Nested lockfiles updated: memory/integration-tests and
playground/e2e/kitchen-sink.
- No new overrides. Changeset:
`vanta-2026-10-28-ai-sdk-v5-provider-utils.md`.
2026-10-28 18:51:27 -04:00
shreyas-mastra
34983c9bbb
chore(security): Vanta 2026-10-23/26 - storybook 9.1.21, body-parser, fast-uri, multer, serialize-javascript, zod pins, esbuild/bundle-name overrides (#28325)
## Update 2026-10-26 afternoon (Vanta pass)
Added commit `f6e4b670` on top of the 16:20 ET main merge:
- **esbuild 0.18.20 → 0.25.12** (GHSA-67mh-4wv8-2f99) and **bundle-name
3.0.0 → 4.1.1** (AIKIDO-2026-886499): the 12:43 ET merge of main dropped
the two `pnpm-workspace.yaml` entries this PR added on 10-23
(`'@esbuild-kit/core-utils>esbuild': 0.25.12` and
`'default-browser@4.0.0>bundle-name': 4.1.1`), so both old versions were
back in `pnpm-lock.yaml`. This commit puts them back exactly as before.
No other overrides changed.
- Added the empty changeset
`.changeset/vanta-2026-10-26-afternoon-overrides.md`.
- `pnpm install --frozen-lockfile --lockfile-only` passes.

After this, `osv-scanner` on all 34 lockfiles finds only the documented
leftovers: zod 3.25.76, ai 4.3.19 / `@ai-sdk/provider-utils` 2.2.8 (the
v4 line), extract-zip 2.0.1 (no patch), `@opentelemetry/core` 1.30.1,
and `@azure/msal-node` 5.6.0 / 6.0.1.

---

## Update 2026-10-26 (Vanta pass)
Merged `origin/main` (no conflicts) and added commits `9b169f0f` and
`94e183ff`:

| Package | From → To | Finding | Where | How |
|---|---|---|---|---|
| body-parser | 2.3.0 → 2.4.0 | CVE-2026-111181 / GHSA-27r3-jxmh-p828
(High) | root `pnpm-lock.yaml`, `examples/agent`, refund and genui
templates (npm) | Raised the root floor `body-parser@<2.3.0: 2.3.0` →
`<2.4.0: 2.4.0`. Added a floor in `examples/agent`. `npm update` in the
templates. `patches/body-parser@2.3.0.patch` renamed to `@2.4.0` (same
one-line raw-body interop; it applies cleanly). |
| body-parser | 1.20.6 → 1.20.9 | same advisory, 1.x line | all 10
`e2e-tests/*` lockfiles (verdaccio → express 4) | New floor
`body-parser@<1.20.9: 1.20.9`. The `patches/body-parser@1.20.6.patch`
files are renamed to `@1.20.9` (they apply cleanly). |
| fast-uri | 3.1.8 → 3.1.9 | CVE-2026-110095/-110180/-110306/-110725 |
root, e2e-tests ×10, `examples/agent`, otel-bridge `agent-hub`,
`acp-validator`, `gh-issue-triage`, refund and genui templates | Raised
the existing floors/pins from 3.1.8 to 3.1.9 |
| fast-uri | 4.2.1 → 4.2.3 | GHSA-333x-w4r6-6crp, GHSA-w74x-v6f9-j3xg,
GHSA-wjr9-j795-jxcr, GHSA-xhq7-xmqj-769h | otel-bridge `agent-hub` |
Raised the existing floor `fast-uri@>=4.0.0 <4.1.5: 4.2.1` → `<4.2.3:
4.2.3` |
| multer | 2.4.0 → 2.5.0 | CVE-2026-113872 / GHSA-q7qp-rjg7-q26m (High)
| root | Floor `multer@<2.3.0: 2.4.0` → `multer@<2.5.0: 2.5.0` |
| serialize-javascript | 7.1.2 → 7.1.4 | CVE-2026-115897 /
GHSA-m5mm-p8h7-m29v | root | Floor `<7.0.5: ^7.0.5` → `<7.1.3: ^7.1.3` |
| zod | 4.3.6 / 4.4.3 / 4.5.4 → 4.6.7 | CVE-2023-54404 /
GHSA-mrhx-c7xc-m3w5 (High) | exact pins in
`templates/template-kyc-customer-onboarding`,
`templates/template-security-incident-triage`,
`packages/mcp/integration-tests/{v2,published-v1}`,
`e2e-tests/commonjs/template` | Direct pin bump (same major) |
| fastify | `^5.12.5` → `^5.12.6` | CVE-2026-107832 | devDependency
specifiers in `server-adapters/fastify` and `workflows/inngest` (the
lock already had 5.12.6) | Specifier bump |

- Every new version is older than 24h: body-parser 2.4.0 and 1.20.9
(10-22), multer 2.5.0 (10-22), serialize-javascript 7.1.4 (10-23),
fast-uri 3.1.9 (10-19), fast-uri 4.2.3 (10-19), qs 6.16.1 (10-14, pulled
in by body-parser 2.4.0), zod 4.6.7 (10-12).
- No overrides or floors were removed; the existing ones were only
raised.
- `pnpm install --frozen-lockfile --lockfile-only` passes at the root
and in the nested e2e/example workspaces.
- Added the empty changesets
`.changeset/vanta-2026-10-26-security-floors.md` and
`.changeset/vanta-2026-10-26-fast-uri-4.md`.
- **Not changed:**
- zod 3.25.76: the fix exists only on zod 4, and the zod-v3 support and
compat tests intentionally stay on 3.
- `@azure/msal-node` 5.6.0: the fix is 7.1.0, but `@azure/identity` 4.14
pins `^6` and `@microsoft/teams.apps` 2.1.1 pins `^5.6.0`, so this would
be a two-major runtime jump.
- extract-zip 2.0.1: no patched release (the advisory lists `>=2.0.2`,
which has not been published).
- `@opentelemetry/core` 1.x: needs pubsub 6 / spanner 9, which are
majors.
  - ai v4 / provider-utils: the v4 line is vendored on purpose.

---

Refs mastra-ai/platform#2931

Vanta remediation, 2026-10-23 (follow-up to #28138, which has merged).

| Package | From → To | Finding | Where | How |
|---|---|---|---|---|
| storybook, @storybook/react-vite (+ react, builder-vite, csf-plugin,
react-dom-shim) | 9.1.20 → 9.1.21 | CVE-2026-114125 (Critical),
CVE-2026-114126 (High) | `client-sdks/react` devDependencies | Direct
bump `^9.1.20` → `^9.1.21` |
| esbuild | 0.18.20 → 0.25.12 | GHSA-67mh-4wv8-2f99 | better-auth →
drizzle-kit 0.31.10 → @esbuild-kit/esm-loader → @esbuild-kit/core-utils
(pins `~0.18.20`) | Override `'@esbuild-kit/core-utils>esbuild':
0.25.12` |
| bundle-name | 3.0.0 → 4.1.1 | AIKIDO-2026-886499 | @mastra/deepeval →
deepeval → open@9 → default-browser@4 (pins `^3`) | Override
`'default-browser@4.0.0>bundle-name': 4.1.1` |

### Why there is a `trustPolicyExclude` for storybook 9.1.21
`client-sdks/react` stays on the storybook 9 line; we are not doing the
storybook 10 major here. The only patched 9.x release is 9.1.21. It was
published on 2026-10-12 without the trusted-publisher evidence that
earlier 9.1.x releases had, so `trustPolicy: no-downgrade` fails with
`ERR_PNPM_TRUST_DOWNGRADE`. The exclude covers exactly the six packages
pnpm rejects, each pinned to `@9.1.21`: `@storybook/react-vite`,
`storybook`, `@storybook/react`, `@storybook/builder-vite`,
`@storybook/csf-plugin` and `@storybook/react-dom-shim`. No other
versions or packages are excluded. The packages come from the official
storybook monorepo release, 9.1.21 on the v9 line.

### Notes
- Every new version is older than 24h, so it satisfies
`minimumReleaseAge: 1440`. storybook 9.1.21 is 11 days old, esbuild
0.25.12 is from Nov 2025 and bundle-name 4.1.1 is from 2026-09-25.
- The esbuild override is dev-only: drizzle-kit is a CLI pulled in by
better-auth. I checked that `@esbuild-kit/core-utils` `transform()`
works against esbuild 0.25.12.
- bundle-name 4.x keeps the same `bundleName()` API. It is used only by
`open`'s macOS default-browser lookup.
- `pnpm build-storybook` in `client-sdks/react` fails on main too. The
error is a Babel 8 `loadPartialConfig` error, which happens with 9.1.20
as well, so it is not caused by this PR.
- I ran `pnpm install --frozen-lockfile` and it passes. The changeset is
empty because no published package changes.


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
<!-- coderabbit-ai-generated:v1 -->

## ELI5

This PR updates dependency versions and rules that keep older,
reported-vulnerable versions out of the project. It also updates
Storybook and records the changes in changesets.

## Summary

- Raises security-related dependency versions or minimums across the
root project, examples, templates, packages, and e2e workspaces. The
updates include `body-parser`, `fast-uri`, `multer`,
`serialize-javascript`, `zod`, and Fastify.
- Renames `body-parser` patch files and updates workspace references to
match the new versions.
- Updates Storybook packages in `client-sdks/react` from 9.1.20 to
9.1.21. Adds an `esbuild` override and updates the `bundle-name`
override.
- Adds changesets for the dependency updates. No tests were added.

## Validation

The author reports that frozen-lockfile installs pass at the root and in
nested e2e and example workspaces. The author also reports that `pnpm
build-storybook` fails on `main` as well as this branch, with a Babel 8
`loadPartialConfig` error.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-10-26 16:39:13 -04:00
Damien Schneider
0f82b38ed4
refactor(lint): flatten lone if statements in else branches (#28431)
Enable `no-lonely-if` in the shared Oxlint config and flatten 38 lone
`if` statements in `else` blocks across 35 files. For example, `else {
if (condition) { ... } }` becomes `else if (condition) { ... }`.
Conditions, evaluation order, statements, comments, and local bindings
are preserved. No package filters or lint exceptions are added.

Strengthen the existing monorepo test to execute another named export
from an optimized dependency. Comparisons of TypeScript syntax, emitted
JavaScript, raw template text, comments, and local bindings pass for all
35 migrated files after normalizing only the redundant else blocks. The
rule clears all 15,094 scanned files.

[CI lint and formatting
pass](https://github.com/mastra-ai/mastra/actions/runs/40344286057/job/121647174331)
for `36ca4471f9`. All 634 focused tests, four package typechecks (core,
playground, connect, and deployer), 57 packaged build tasks, and two
selected published-package monorepo E2E cases pass. The broader local
lint run hit a Tailwind design-system precomputation timeout; CI lint
succeeds. Live vendor and external-database suites were not run locally.

[DuckDB CI has two existing capability-list assertion
failures](https://github.com/mastra-ai/mastra/actions/runs/40344286246/job/121649643109):
its implementation advertises `span-aggregate`, while the expected lists
omit it. The failures reproduce locally, and the relevant implementation
and tests are unchanged from the base commit.

This maintenance PR intentionally contains no changeset and requests no
package releases. The missing-changeset check may fail.


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

<!-- coderabbit-ai-generated:v1 -->

## ELI5
This PR turns on a lint rule that asks for simpler branching in code. It
updates the affected code and adds a leap-year check to an existing
test.

## Changes
- Enables Oxlint’s `no-lonely-if` rule in the shared configuration.
- Flattens 38 lone `if` statements across 35 files. The PR description
reports that the changes preserve behavior.
- Extends the optimized-dependency monorepo test to check `isLeapYear`.

## Validation
- The PR description reports that CI lint and formatting pass.
- It also reports 634 focused tests, four package typechecks, 57
packaged build tasks, and two selected monorepo E2E cases pass.
- The PR description notes two existing DuckDB CI capability-list
assertion failures. It reports that the related implementation and tests
are unchanged from the base commit.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-10-26 18:44:48 +01:00
Dane - AI (Mastra)
2f485b2d56
chore(deps): update security updates [security] (#28222) 2026-10-22 21:58:08 -04:00
Dane - AI (Mastra)
82e82fb5a7
chore(deps): update security updates [security] (#27869)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-10-22 14:54:47 +02:00
Dane - AI (Mastra)
40a522c142
chore(deps): update build tools (#27997) 2026-10-22 14:33:21 +02:00
shreyas-mastra
a15ea70e71
security: Vanta remediation (2026-10-21) (#28018) 2026-10-21 09:12:30 -07:00
mastra-platform[bot]
353b4811df
test(libsql): port T81 recovered-history cross-process coverage (#27945)
Ports T81 using a real child process, shared LibSQL storage and
UNIX-socket pubsub. The original parks in a blocking tool; the
replacement confirms live-owner recovery is refused, waits for real
lease expiry while the original is SIGSTOPped, then recovers without
force. After SIGCONT and full original execution settlement, persisted
history must still contain exactly one replacement-authored final answer
with unchanged message IDs, ordering and content. Existing pause/resume
helpers are reused; only a test and fixture are added, with no runtime
changes or changeset.

Both durable and evented controls are enabled, as is durable recovery.
Evented recovery is explicitly skipped: one uninstrumented run stalled
in recover() before returning its stream (20s guard, repetition 8); 50
instrumented repeats passed without explaining it. The assertions remain
in-tree for re-enablement after diagnosis. This is not COR-1334
reproduction, a runtime fix, or proof that a stale write was attempted
and rejected.

Validation: 20 final uninstrumented fresh-process runs, each 3 passed /
1 explicitly skipped; 28 neighboring helper, ownership, T79 and T80
tests passed; temporary stale-overwrite and duplicate-answer negative
controls failed on the intended assertions for both engines and were
removed. Package tsc --noEmit, type-aware lint, formatting and git diff
--check pass. No orphan T81 peers or cross-process sockets remain.
Independent final reviews found no remaining must-fix issues.

Test command: pnpm --filter @mastra/libsql exec vitest run
src/__tests__/cross-process/xproc-recovered-original-write.test.ts

Related:
https://linear.app/kepler-crm/issue/COR-1444/port-t81-xproc-recovered-original-write-pause-and-resume-a-cross.
Records the in-tree port for COR-1388; does not close COR-1334. Evented
recovery coverage remains incomplete as documented above.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

<!-- coderabbit-ai-generated:v1 -->

## ELI5

This PR adds a test that starts work in one process, pauses it, and
checks that another process can safely finish it after the first process
loses its lease. It confirms that the saved conversation has one correct
final answer and no duplicate messages.

## Changes

- Added the `t81-peer` cross-process fixture.
- Added durable LibSQL recovery coverage with:
  - A real child process.
  - Shared LibSQL storage.
  - UNIX-socket pubsub.
  - Lease-expiry handling.
  - `SIGSTOP` and resume behavior.
  - Message ID, order, content, and replacement-author checks.
- Added a control test for normal completion.
- Confirmed recovery is rejected while the original process still owns
the run.
- Skipped evented recovery because an instrumented setup stall remains
unresolved.
- Added no runtime changes or changeset.

## Validation

The PR reports passing results for:

- 20 fresh-process runs.
- 28 neighboring tests.
- Type checking.
- Linting.
- Formatting.
- Diff checks.

Validation command:

```bash
pnpm --filter @mastra/libsql exec vitest run src/__tests__/cross-process/xproc-recovered-original-write.test.ts
```

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: NikAiyer <nick.aiyer@gmail.com>
Co-authored-by: mastra-platform[bot] <284800079+mastra-platform[bot]@users.noreply.github.com>
2026-10-21 10:20:41 -05:00
Dane - AI (Mastra)
4f60903242
chore(deps): lock file maintenance (#27013) 2026-10-21 09:25:38 +02:00
shreyas-mastra
f3cf77305f
security: Vanta remediation (2026-10-20) (#27828) 2026-10-20 08:39:07 -07:00
Dane - AI (Mastra)
dbde4bf36a
chore(deps): update ai sdk (#27728)
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-10-19 19:04:28 -07:00
shreyas-mastra
fa409d430b
security: Vanta remediation pass 2026-10-14/15/19 (zod 4.6.7, @ai-sdk/provider-utils, @copilotkit template) (#27023) 2026-10-19 11:32:32 -07:00
Tyler Barnes
4bb2f0ad72
feat(ci): fail PRs and publishes on packages missing from npm (#26721)
## Why

Alpha.9 publish run 38152562840 published 7 packages, then failed
partway through on the brand-new `@mastra/sprites` with `E404 PUT` /
`ERR_PNPM_AUTH_TOKEN_EXCHANGE`. `npm-publish.yml` uses npm trusted
publishing (OIDC) with no token fallback. npm only exchanges the job's
GitHub OIDC token for a publish token if the package exists and has a
trusted publisher matching this repo and workflow, and npm only allows a
trusted publisher on a package that already exists. So a never-published
workspace package, or an existing one with no trusted publisher (or one
for another workflow), breaks the release after other packages have
already gone out. Recovery took an npm org admin doing a manual first
publish and an `npm trust` call, then a rerun.

## What

- **`.github/scripts/check-npm-packages-exist.mjs`** checks that every
non-private workspace package exists on npm, using anonymous registry
reads (works in PR workflows without secrets). `--since <ref>` limits
the check to packages whose `package.json` changed, which catches new
packages and private→public promotions. `--retry-404` waits out registry
propagation delay. A registry it can't reach (exit 2) is reported
separately from a missing package (exit 1), so registry flakiness is
never reported as a missing package.
- **Trusted-publishing check (`--oidc`, publish jobs only; new in this
PR)**: for every package in scope, the script requests a GitHub OIDC
token (audience `npm:registry.npmjs.org`) and POSTs it to
`/-/npm/v1/oidc/token/exchange/package/<name>`. This is the exchange
pnpm 11 and npm 11 perform at publish time (endpoint and request shape
taken from pnpm 11.21's `publish/oidc/authToken.js` and npm 12.2's
`lib/utils/oidc.js`). The token npm returns is discarded and never
printed. A granted token proves npm accepts this job as the package's
trusted publisher (repo, workflow and, if the publisher names one,
GitHub environment). It does not prove the publish itself will be
accepted: npm uses the same exchange for publish, stage publish and
dist-tag, so a trusted publisher limited to staged publishing passes
this check. The placeholder script below checks that permission when it
configures or reads back trust. A refused exchange fails with the
packages named and the fix (`scripts/npm-placeholder-publish.mjs` or
`npm trust github … --file npm-publish.yml`). Registry or GitHub-token
errors are reported separately as "could not verify". The check covers
every package in scope, not just those with a new version, because
stable and snapshot run it before versioning. All 163 current public
packages already have a version published through trusted publishing.
- **PR gate** (`lint.yml`, job *New packages exist on npm*): Changesets
release PRs check every package. Other PRs only check packages whose
`package.json` changed, and PRs that touch none make no registry calls.
PR refs stay out of shell: routing is done with `if:` and the base ref
is passed through `env:`. The gate has no OIDC token, so it only
**warns** (`:⚠️:`, never fails) when a package exists but no
version of it was ever published through trusted publishing. A fresh
placeholder looks like that until CI's first publish.
- **Publish check** in all four publish jobs (prerelease, stable,
snapshot, playground-snapshot): existence check, then the
trusted-publishing check. Each check makes one pass over every package,
then re-checks only the missing or refused ones against one shared
5-minute deadline, which picks up a package or trusted publisher an
admin fixed minutes ago. A failing job therefore takes about one retry
window, however many packages fail. If every package is refused, which
points to a misconfigured job rather than the packages, the check fails
after the first pass. It runs before anything publishes, and for stable
before the version commit is pushed to `main`.
- **`scripts/npm-placeholder-publish.mjs`**: the recovery both checks
point to. An npm org admin runs `node
scripts/npm-placeholder-publish.mjs <package>` after `npm login`. For a
never-published name it publishes an empty `0.0.0` placeholder
(package.json + README, no code from any branch). It then configures
trusted publishing for `npm-publish.yml` (with npm ^11.15.0, the first
version with `--allow-publish`) and reads it back with `npm trust list`.
It skips the setup when a usable trusted publisher is already present,
and fails if npm doesn't report one afterwards. A trusted publisher for
this repo and workflow is usable only if it allows publishing
(`createPackage`; older settings with no permissions field count) and is
not restricted to a GitHub environment, because the publish jobs declare
none. A stage-only or environment-restricted one is reported with the
`npm trust revoke --id` command to remove it, instead of being treated
as configured. CI then publishes the real versions. Prereleases go out
under `alpha`, so `latest` stays on the placeholder until the first
stable release, and the placeholder's description and README point
installers to `<package>@alpha`. The script refuses unknown or private
names, an unreachable registry and a logged-out session, publishes
nothing for a name already on npm, and supports `--dry-run`.

CI-only change, so there is no changeset.

## Testing

- `node --test .github/scripts/check-npm-packages-exist.test.mjs
scripts/npm-placeholder-publish.test.mjs`: 37/37, all against local mock
registries. Against the previous scripts, 12 of the 13 new tests fail,
as does the tightened trust-configuration test. The one exception is the
"no warning" test, which passes on both.
- Trusted-publishing check: trust present (exchange granted), no trust
(exchange refused, package named, fix printed), every package refused
(points at the job), exchange endpoint unreachable (exit 2, not "no
trust"), transient 503/429 recovery, GitHub token endpoint failing,
missing `id-token: write`, and trust appearing within the retry window.
Timing tests cover a run where every package is refused (fails in under
a second with a 60-second window; the earlier per-package polling took
144 seconds) and 24 refused or 24 missing packages (about one 3-second
window; per-package polling took about 7.6 seconds). The tests assert
the request shape (audience, POST path, bearer token) and that no token
appears in the output.
- Placeholder script: runs the real `npm publish`, `npm trust github`
and `npm trust list`, and asserts the uploaded tarball holds only
`README.md` and `package.json` at 0.0.0, with the `@alpha` install
pointer. Trust read-back is covered for already configured, configured
but not reported back (fails), an existing package trusting another
workflow, a stage-only publisher and an environment-restricted publisher
(both fail with revoke steps; both were accepted before), and older
settings with no permissions field (accepted).
- **The token exchange has not been run against live npm with a real
GitHub OIDC token.** That needs `npm-publish.yml` in mastra-ai/mastra,
so the first real run will be the next publish. Locally, read-only: a
fake id token sent to the live exchange endpoint gets `401 OIDC token
exchange error - unauthorized`, which the check reports as refused (exit
1). Without `id-token: write` it exits 2.
- Current main against live npm: all 163 publishable packages exist
(exit 0), with no trusted-publishing warnings.
- Incident replay (tree before the alpha.9 version commit, registry in
its publish-day state): flags only `@mastra/sprites`. Running the
placeholder script then publishes 0.0.0 and sets up trust, and the
re-run check passes.
- The PR that added sprites (#26650, which added the `@mastra/sprites`
package) would have been flagged by the PR gate: of the 32 packages it
changed, only sprites is flagged.
- Live npm, read-only: `--dry-run` for an existing name and for a
never-published name (nothing uploaded).
- actionlint on `lint.yml` and `npm-publish.yml` (no findings besides
the repo-wide custom runner labels); `yaml-lint` on both workflows;
`oxfmt --check` on the scripts.


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## ELI5

This PR checks that packages exist on npm before release workflows use
them. It also adds a script to prepare new packages for their first npm
release.

## Changes

- Added a pull request check. Changesets release PRs check all
publishable packages. Other PRs check packages whose `package.json`
changed. PRs that change no package manifests make no registry calls.
- Added package-existence and trusted-publishing preflights to the
prerelease, stable, snapshot, and playground-snapshot jobs.
- Added optional `--oidc` checks. A successful token exchange shows that
npm granted the job a token; it does not prove that the token has
publish permission. Without OIDC, the check warns when a package has no
version previously published through trusted publishing.
- Added retries for missing packages and refused token exchanges, using
a shared deadline. The check stops polling when every package’s first
OIDC exchange is refused.
- Added `scripts/npm-placeholder-publish.mjs`. It can publish a public
`0.0.0` placeholder and configure trusted publishing. It rejects
unknown, private, already-published, unverifiable, or unauthenticated
cases, and supports `--dry-run`.
- Added tests for the package checks and placeholder-publishing flows.
- The PR objectives report 37/37 tests passing against local mock
registries and workflow and script lint checks. These results were not
independently verified.
- The PR objectives report that live npm token exchange with a real
GitHub OIDC token has not yet been tested.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: remy-builder[bot] <324360501+remy-builder[bot]@users.noreply.github.com>
2026-10-14 16:28:27 -07:00
shreyas-mastra
7aec8b0d95
security: Vanta remediation pass 2026-10-12 (better-auth, MCP SDK) (#26773)
## Summary
Vanta remediation for 2026-10-12. Target list is today's live export (77
findings, 44 unique IDs). Platform findings are handled in
mastra-ai/platform#3317.

### What changed
| Package | From → To | Findings | Where | How |
|---|---|---|---|---|
| better-auth | 1.7.5 → 1.7.7 | AIKIDO-2026-373183 (Critical) | root +
`examples/agent` | raise override `better-auth: ^1.7.7`; direct dep
`@mastra/auth-better-auth` ^1.7.7 |
| @better-auth/drizzle-adapter | 1.7.5 → 1.7.7 | AIKIDO-2026-261025
(Low) | root + `examples/agent` | floor
`'@better-auth/drizzle-adapter@<1.7.7': 1.7.7` (also pulled by
better-auth 1.7.7) |
| @modelcontextprotocol/sdk | 1.31.0 → 1.32.1 | AIKIDO-2026-365378
(High), -156139, -344432 | root, nested locks, `scripts/gh-issue-triage`
| raise floor to `<1.32.0 → 1.32.1`; bump direct pins/ranges |

Nested `pnpm-workspace.yaml` floors raised in e2e-tests/*, examples/*,
integration-tests, etc., and those lockfiles regenerated. Versions used
were published >24h ago (minimumReleaseAge). Patch changeset included
for published packages whose dependency ranges changed.

Aikido lens on this branch: better-auth and MCP SDK findings are gone.
OSV: handlebars already clear on main; remaining high are
braces/extract-zip (no patch).

### Left as-is (no patch, or major-only)
- extract-zip ≤2.0.1: no fix (overdue; removed by #25855 when that
lands). Needs Vanta risk acceptance.
- braces 3.0.3, sprintf-js 1.0.3/1.1.3: no patched release
- postcss-selector-parser 6.x: @tailwindcss/typography pins 6.0.10
- katex 0.16: mermaid declares ^0.16.47
- @ag-ui/client 0.0.59: fix only in 1.0.0 (major). Parent
`@copilotkit/channels-*` 0.11.0 pins 0.0.59 exactly
(template-genui-data-explorer)
- @hono/node-server 1.19 (fix 2.1.3), undici 6.29 (fix 7.23/8.10),
raw-body 3 in templates (fix 4), bundle-name 3 (fix 4.1.1), got 15 (fix
16), zod 3.25 (fix 4.x), @bufbuild/protobuf 1.10 (fix 2.x), openai 6.49
(fix 7.x), jose 5.10 via @segment/analytics-node in template (fix 6.x),
@ai-sdk/provider-utils 2.2.8 / 3.0.x Aikido ranges wanting 4.0.18+:
major-only or scanner range noise

Do not merge unless reviewed. No CI weakened.


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## ELI5

This PR updates shared dependency versions so the project uses newer
releases of Better Auth and the MCP SDK. It also updates workspace rules
to keep older versions from being selected.

## Changes

- Updated Better Auth requirements and workspace overrides to `^1.7.7`.
- Updated `@modelcontextprotocol/sdk` requirements and overrides to
`1.32.1` across affected packages and workspaces.
- Added overrides for older `@better-auth/drizzle-adapter` versions to
use `1.7.7`.
- Added a patch changeset for `@mastra/auth-better-auth`,
`@mastra/mcp-registry-registry`, and `@mastra/playground-ui`.

Test results and review findings were not provided.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-10-13 07:41:26 -07:00
shreyas-mastra
ea7ca755a4
security: Vanta remediation pass 2026-10-07 (MCP SDK, sharp, hono) (#26260) 2026-10-07 09:29:07 -07:00
shreyas-mastra
4358322b7b
chore(deps): override upstream-blocked vulnerable transitive deps (#25853) 2026-10-02 18:03:50 -07:00
shreyas-mastra
aeddbc9909
security: Vanta 2026-09-28 residuals (template proxy-addr, nested undici/next/shell-quote/form-data, OTEL, onnxruntime) (#25344) 2026-09-28 10:45:13 -07:00
shreyas-mastra
7b777d38d9
security: Vanta zero pass 2026-09-23 (grpc/compression/provider-utils floors) (#24848) 2026-09-23 13:58:39 -07:00
Abhi Aiyer
fdcd75925f
Make the affected-test detector see packages that import with .js specifiers (#24488)
## Summary

CI picks which tests to run on a PR by building a module graph of the
repo and walking it backwards from the changed files. That graph is
built by madge, which resolves imports through enhanced-resolve using
`scripts/madge.webpack.config.cjs`.

That config had no `extensionAlias`. Packages written for TypeScript's
NodeNext resolution import their own relative files as `'../tools.js'`
even though the file on disk is `../tools.ts` — and without
`extensionAlias` the resolver looks for a literal `.js` file, finds
nothing, and silently drops the edge. `mastracode/sdk` is written
entirely in that style (212 of 256 source files), so its portion of the
graph was essentially empty and any PR touching SDK source was told no
tests were affected. The full-suite jobs did not catch this either, so
those changes shipped with no test signal at all.

Two changes: teach the resolver to map `.js`/`.mjs`/`.cjs` specifiers
onto their TypeScript sources, and let madge traverse `.mts`/`.cts`
files, which this package uses for its child-process fixtures.

Fixes #24218

## Test plan

Detector output for the same inputs, before and after:

| changed file | before | after |
| --- | --- | --- |
| `mastracode/sdk/src/agent-connections/tools.ts` | 0 tests | 20 tests,
including its own colocated `__tests__/tools.test.ts` |
| `mastracode/sdk/src/index.ts` | 0 tests | 19 tests |
| `packages/core/src/agent/index.ts` (control) | 1229 tests | 1470 tests
|

The control case was already working but was also under-selecting, since
workspace packages consumed by core use the same import style; it now
resolves those edges too.

Graph is denser, so selection is slightly slower — 21.4s to 23.5s for
the core case, about 10%. That is well worth the correctness.

Note: registering the SDK's own vitest project is separate work, as the
issue describes — `vitest.config.ts` points at a
`mastracode/vitest.config.ts` that does not exist, and the SDK suite is
currently red on main. This PR only fixes the detector.


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## ELI5

This PR helps the test selector follow SDK imports correctly. It ensures
source changes select the tests that depend on them.

## Changes

- Added Madge aliases for `.js`, `.mjs`, and `.cjs` imports.
- Added `.mts` and `.cts` files to Madge traversal.
- Added a NodeNext import-resolution test.
- Added a guard for missing colocated tests.
- Added two retries for failed TUI E2E shard tests.

## Reported results

- SDK tool changes select 20 tests instead of none.
- SDK index changes select 19 tests instead of none.
- A core control case selects 1,470 tests, up from 1,229.
- Runtime increased from 21.4 to 23.5 seconds.
- SDK Vitest project registration remains out of scope.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: tyler-mastra[bot] <331730378+tyler-mastra[bot]@users.noreply.github.com>
Co-authored-by: Tyler Barnes <tylerdbarnes@gmail.com>
2026-09-21 14:58:17 -07:00
shreyas-mastra
5bfe0af40c
security: clear remaining Dependabot alerts + raise Aikido floors (round 2) (#24391) 2026-09-18 07:48:18 -07:00
shreyas-mastra
95f1ad9148
security: raise pnpm override floors for Vanta/Dependabot (proxy-addr critical) (#24327) 2026-09-17 14:57:25 -07:00
Daniel Lew
80845a3559
fix(ci): build local @mastra/core before packing it for the import floor check (#23907)
`check:core-imports` falls back to packing the local `packages/core`
when a package's core peer floor names a version that isn't published
yet. The "Validate peer dependencies" CI job never builds core, so that
fallback packed a tarball with no `dist/` and every `@mastra/core/*`
subpath import failed to resolve — e.g. `Resolved 0/23 @mastra/core
import paths` for `@mastra/server` on #23875, the first PR to raise a
floor to an unpublished core.

The script now builds core (`pnpm turbo build --filter ./packages/core`)
before packing when `dist/` is absent. Reproduced locally by deleting
`dist/`, bumping core to `999.0.0` and pointing `@mastra/server`'s floor
at it: before the change the server check resolved 0 paths; after, it
builds, packs and resolves all imports.

No changeset: script-only change.

Co-authored-by: Mastra Code (anthropic/claude-fable-5-1) <noreply@mastra.ai>
2026-09-16 12:49:28 -05:00
shreyas-mastra
164e197aa5
fix: bump vulnerable dependencies to patched releases (#24027)
Co-authored-by: Cursor Agent <cursoragent@cursor.com>
2026-09-15 13:58:48 -07:00
Lennart
d77518bd2a
chore: update package READMEs and add conditional CI validation (#23488)
Co-authored-by: Mastra Code (openai/gpt-6-astra) <noreply@mastra.ai>
2026-09-10 13:46:36 +02:00
Lennart
e983f74987
chore(*): Update/unify/add READMEs (#22858)
Co-authored-by: Mastra Code (openai/gpt-5.6-sol) <noreply@mastra.ai>
2026-09-02 14:36:59 +02:00
Ward Peeters
c975ebdb0b
fix: validate core imports against peer dependency floors (#22564)
Co-authored-by: Mastra Code (openai/gpt-5.6-sol) <noreply@mastra.ai>
2026-09-01 17:32:58 +02:00
Ward Peeters
d50fe06cbf
chore: upgrade monorepo to TypeScript 7 (#22459)
Co-authored-by: Mastra Code (openai/gpt-5.6-sol) <noreply@mastra.ai>
2026-08-28 23:55:51 +02:00
Abhi Aiyer
8d368276f6
fix: secure issue triage dependencies (#22501)
Co-authored-by: Mastra Code (openai/gpt-5.6-sol) <noreply@mastra.ai>
2026-08-27 13:59:10 -07:00
Abhi Aiyer
7d35cca22b
fix: raise dependency security floors (#22484)
Co-authored-by: Mastra Code (openai/gpt-5.6-sol) <noreply@mastra.ai>
2026-08-27 13:15:40 -07:00
Ward Peeters
de8784224a
fix(ci): include exported server subpaths in affected tests (#21140)
Before, `@mastra/server/server-adapter` was resolved as if it lived
directly under `packages/server/src`, so affected-test selection skipped
adapter coverage.

This now follows workspace export paths back to source modules, so
server handler changes select dependent adapter tests. For the workflow
change from #20184, the analyzer now includes 9 Express and 11 Fastify
tests.

I checked formatting and graph resolution, then ran the affected-test
analyzer. Running the Express suite now reaches the existing 409
expectation failures that this CI gap had hidden.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## ELI5

The test tool now follows workspace package links to the real source
files. It selects tests that depend on changed server handlers,
including 9 Express tests and 11 Fastify tests.

## Changes

- Added `buildWorkspaceSourceAliases` in
`scripts/workspace-source-aliases.cjs`.
- Reused shared workspace alias logic in affected-test analysis and
Madge Webpack configuration.
- Added support for workspace export subpaths and exact aliases.
- Removed duplicated package discovery and alias construction logic.
- The Express suite now exposes existing 409 expectation failures that
CI previously missed.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2026-08-10 10:53:46 +02:00
Noah Crowley
cc85af2425
fix(deps): update fast-uri (#20557)
Updates all tracked fast-uri resolutions to 3.1.5 to address
CVE-2026-18446 and the earlier Aikido findings. Moves the agent-hub pnpm
overrides into its workspace config so pnpm 11 enforces the security
floor.

Also refreshes the stale gh-issue-triage pnpm-lock to match its
manifest.

Validated frozen lockfile installs, the triage npm install, and the
agent-hub tests. No related issue.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## ELI5

This PR updates `fast-uri` to a safer version that fixes security
problems. It also moves dependency rules so pnpm 11 applies them
correctly.

## Changes

- Updated all tracked `fast-uri` resolutions to `3.1.5`.
- Updated security override constraints from `<3.1.2` to `<3.1.5`.
- Moved `agent-hub` pnpm overrides into `agent-hub/pnpm-workspace.yaml`.
- Preserved local Mastra package links and dependency version overrides.
- Excluded `fast-uri@3.1.5` from minimum release age checks.

## Validation

- Ran frozen lockfile installs.
- Ran the triage npm install.
- Ran `agent-hub` tests.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2026-07-31 17:14:25 -07:00
Dane - AI (Mastra)
9a20c3fa52
chore(deps): update mastra (#20410) 2026-07-29 23:25:14 +02:00
Ward Peeters
bdeaef58f0
chore: migrate linting to oxlint (#20173)
Co-authored-by: GitHub Action <action@github.com>
Co-authored-by: Mastra Code (openai/gpt-5.6-sol) <noreply@mastra.ai>
2026-07-25 01:04:02 +02:00
Dane - AI (Mastra)
1aad6198fd
chore(deps): lock file maintenance (#19903) 2026-07-22 17:05:00 +02:00
Dane - AI (Mastra)
de2e407f7a
chore(deps): update dependency typescript to v7 (#19271)
Co-authored-by: wardpeet <ward@coding-tech.com>
2026-07-20 14:15:43 +02:00
Dane - AI (Mastra)
2592c7226a
chore(deps): lock file maintenance (#19457)
This PR contains the following updates:

| Update | Change |
|---|---|
| lockFileMaintenance | All locks refreshed |

🔧 This Pull Request updates lock files to use the latest dependency
versions.

---

### Configuration

📅 **Schedule**: (UTC)

- Branch creation
  - "before 6am on wednesday"
- Automerge
  - At any time (no schedule defined)

🚦 **Automerge**: Enabled.

♻ **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](https://redirect.github.com/renovatebot/renovate).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My4yNjMuNSIsInVwZGF0ZWRJblZlciI6IjQzLjI2My41IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJhdXRvbWF0aW9uIl19-->
2026-07-17 20:28:50 +02:00
Dane - AI (Mastra)
d709df0053
chore(deps): update build tools to ^4.23.1 (#19612)
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [tsx](https://tsx.hirok.io)
([source](https://redirect.github.com/privatenumber/tsx)) |
devDependencies | patch | [`^4.23.0` →
`^4.23.1`](https://renovatebot.com/diffs/npm/tsx/4.23.0/4.23.1) |

---

### Release Notes

<details>
<summary>privatenumber/tsx (tsx)</summary>

###
[`v4.23.1`](https://redirect.github.com/privatenumber/tsx/releases/tag/v4.23.1)

[Compare
Source](https://redirect.github.com/privatenumber/tsx/compare/v4.23.0...v4.23.1)

##### Bug Fixes

- support tsImport after global preload
([8d4ffc2](8d4ffc24f3))
- **watch:** avoid clearing piped output
([95d0672](95d0672e02))
- **watch:** treat script and dependency paths literally
([79fddde](79fddde523))

##### Performance Improvements

- index transform cache lazily
([e818ad6](e818ad6081))
- load esbuild lazily in CLI
([d067938](d0679381b6))
- map Node TypeScript formats directly
([cdcc623](cdcc6232a3))
- use sync module hooks on Node v22.22.3+
([f8992f1](f8992f1a50))

***

This release is also available on:

- [npm package (@&#8203;latest
dist-tag)](https://www.npmjs.com/package/tsx/v/4.23.1)

</details>

---

### Configuration

📅 **Schedule**: (UTC)

- Branch creation
  - "before 6am every weekday"
- Automerge
  - At any time (no schedule defined)

🚦 **Automerge**: Enabled.

♻ **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](https://redirect.github.com/renovatebot/renovate).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0My4yNjUuMyIsInVwZGF0ZWRJblZlciI6IjQzLjI2NS4zIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJhdXRvbWF0aW9uIl19-->
2026-07-17 08:55:39 +02:00
Dane - AI (Mastra)
0532405a28
chore(deps): update build tools (#18043) 2026-07-14 23:01:34 +02:00