Skip to content

chore(deps-dev): bump vitest from 4.1.0 to 4.1.5 in /crates/librefang-api/dashboard#3989

Closed
dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/npm_and_yarn/crates/librefang-api/dashboard/vitest-4.1.5
Closed

chore(deps-dev): bump vitest from 4.1.0 to 4.1.5 in /crates/librefang-api/dashboard#3989
dependabot[bot] wants to merge 1 commit into
mainfrom
dependabot/npm_and_yarn/crates/librefang-api/dashboard/vitest-4.1.5

Conversation

@dependabot

@dependabot dependabot Bot commented on behalf of github Apr 28, 2026

Copy link
Copy Markdown
Contributor

⚠️ Dependabot is rebasing this PR ⚠️

Rebasing might not happen immediately, so don't worry if this takes some time.

Note: if you make any changes to this PR yourself, they will take precedence over the rebase.


Bumps vitest from 4.1.0 to 4.1.5.

Release notes

Sourced from vitest's releases.

v4.1.5

   🚀 Experimental Features

   🐞 Bug Fixes

    View changes on GitHub

v4.1.4

   🚀 Experimental Features

   🐞 Bug Fixes

    View changes on GitHub

v4.1.3

   🚀 Experimental Features

... (truncated)

Commits
  • e399846 chore: release v4.1.5
  • 7dc6d54 Revert "fix: respect diff config options in soft assertions (#8696)"
  • 9787ded fix: respect diff config options in soft assertions (#8696)
  • 325463a fix(ast-collect): recognize _vi_import prefix in static test discovery (#10...
  • 0e0ff41 feat(coverage): istanbul to support instrumenter option (#10119)
  • 663b99f fix: alias agent reporter to minimal (#10157)
  • 122c25b fix: fix vi.defineHelper called as object method (#10163)
  • 6abd557 feat(api): make test-specification options writable (#10154)
  • 596f739 fix: project color label on html reporter (#10142)
  • 9423dc0 fix: --project negation excludes browser instances (#10131)
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

@dependabot dependabot Bot added the dependencies Pull requests that update a dependency file label Apr 28, 2026
@houko
houko enabled auto-merge (squash) April 28, 2026 11:45
@houko

houko commented Apr 28, 2026

Copy link
Copy Markdown
Contributor

@dependabot recreate

@github-actions
github-actions Bot requested a review from houko April 28, 2026 12:35
@houko

houko commented Apr 28, 2026

Copy link
Copy Markdown
Contributor

Superseded by manual rebase in #to-be-opened — pnpm-lock conflicted with #3989-#3995's dashboard dep merges.

@houko houko closed this Apr 28, 2026
auto-merge was automatically disabled April 28, 2026 12:44

Pull request was closed

@dependabot @github

dependabot Bot commented on behalf of github Apr 28, 2026

Copy link
Copy Markdown
Contributor Author

OK, I won't notify you again about this release, but will get in touch when a new version is available. If you'd rather skip all updates until the next major or minor version, let me know by commenting @dependabot ignore this major version or @dependabot ignore this minor version. You can also ignore all major, minor, or patch releases for a dependency by adding an ignore condition with the desired update_types to your config file.

If you change your mind, just re-open this PR and I'll resolve any conflicts on it.

@dependabot
dependabot Bot deleted the dependabot/npm_and_yarn/crates/librefang-api/dashboard/vitest-4.1.5 branch April 28, 2026 12:44
houko added a commit that referenced this pull request Apr 28, 2026
Re-do of dependabot's #3989 on top of latest main: the original PR
conflicted on pnpm-lock.yaml after #3989-#3995's other dashboard dep
bumps merged. Regenerated lockfile via pnpm install.
@github-actions github-actions Bot added has-conflicts PR has merge conflicts that need resolution size/M 50-249 lines changed no-rust-required This task does not require Rust knowledge labels Apr 28, 2026
houko added a commit that referenced this pull request May 4, 2026
…3378 part 1 fixup)

Addresses review feedback on PR #4544.

* Extract remove_agent_inner / vacuum_inner free fns. The sync method
  takes its own conn lock and forwards; the async wrapper takes the
  lock inside spawn_blocking and forwards. One transaction body, one
  truth — a future change to the agent-deletion strategy or the VACUUM
  flow (e.g. adding a new per-agent table) only has to land in one
  place. Substrate.rs:203-205 already warned about exactly this kind
  of cross-place coupling.

* Rewrite async_wrappers_do_not_park_current_thread_runtime to assert
  on ordering instead of a 25 ms wall-clock threshold. The blocker
  thread captures released_at the instant the lock guard drops; a
  tokio task captures tick_at after a 20 ms sleep. The test asserts
  tick_at < released_at — true in the correct (offloaded) case
  because the tick fires during the 100 ms hold; false in the broken
  case because the runtime is parked until the lock releases, so
  released_at lands first. No timing budget — the test stays
  decisive under heavy CI jitter (Windows / llvm-cov instrumentation
  has been observed to add 30-80 ms per scheduler hop on this repo,
  see #3989 series).

* Add tracking comments to the three async wrappers that don't yet
  have an in-tree caller (structured_get_async,
  get_agent_session_ids_async, delete_canonical_session_async).
  Staged for #3378 part 2 — the comment marks them so a future
  dead-code sweep doesn't remove them before the kernel-side
  migration lands.
houko added a commit that referenced this pull request May 4, 2026
…#4544)

* fix(memory): async wrappers for kernel substrate calls (#3378 part 1)

The hottest async kernel paths today take `std::sync::Mutex<Connection>`
synchronously on the tokio worker thread. Per #3378, when one holder
runs a slow `INSERT` (FTS5 tokenization, transactional cascades), the
worker stalls and every unrelated future scheduled on it is delayed
until the lock is released. Only `save_session_async` and the embedding
helpers used `spawn_blocking`; the rest of the surface did not.

This change wires every substrate method that is reached from an async
fn through `tokio::task::spawn_blocking`, so the connection mutex is
always acquired on the blocking pool, never on a runtime worker:

- `save_agent_async`
- `load_all_agents_async`
- `remove_agent_async`
- `structured_get_async`
- `get_session_async`
- `get_agent_session_ids_async`
- `delete_canonical_session_async`
- `append_canonical_async`
- `vacuum_if_shrank_async`

The original sync methods are kept verbatim. Tests, migrations, and
the (still-sync) `KernelHandle` trait methods that aren't on a hot
async path use them unchanged, so no caller's signature shifts.

Inside `crates/librefang-kernel/src/kernel/mod.rs` the seven async-fn
call sites that took the connection mutex on a runtime worker are
migrated to the new `_async` siblings:

- `execute_llm_agent` — `save_agent`, `append_canonical`
- `start_background_agents` — `load_all_agents`, `remove_agent`,
  `vacuum_if_shrank`
- `replace_tool_result_in_session` — `get_session` (×2)

These are the high-frequency paths: every LLM turn fires
`execute_llm_agent`, every reboot fires `start_background_agents`,
and every approval / replay fires `replace_tool_result_in_session`.

A regression test in `substrate.rs` (`async_wrappers_do_not_park_
current_thread_runtime`) holds the connection mutex from a non-tokio
OS thread for ~30 ms, then drives `save_agent_async` on a single-
threaded tokio runtime concurrently with a 5 ms `tokio::time::sleep`.
If the wrapper had taken the mutex on the runtime worker (the pre-fix
pattern) the sleep would block for the full hold time; the test
asserts it returns within 25 ms.

This is a partial fix for #3378. Three other surfaces are still
synchronous and called from async paths and need follow-up:

1. ~21 sync kernel methods called from axum handlers (`kill_agent`,
   `reset_session`, `set_agent_model`, etc.). These need their
   `KernelHandle` trait counterparts converted to async, or each
   axum call site wrapped in `spawn_blocking`. Bigger surface,
   warrants its own PR.

2. `MeteringEngine` (`librefang-kernel-metering`) — `record`,
   `check_all_and_record`, `check_user_budget`,
   `check_global_budget` are sync and called from
   `send_message_full_with_upstream` and `execute_llm_agent`.

3. `AuditLog` (`librefang-runtime/src/audit.rs`) — `record` /
   `record_with_context` are sync, called from the same async
   hot paths as #2.

Refs #3378.

* refactor(memory): share inner fns + ordering-based regression test (#3378 part 1 fixup)

Addresses review feedback on PR #4544.

* Extract remove_agent_inner / vacuum_inner free fns. The sync method
  takes its own conn lock and forwards; the async wrapper takes the
  lock inside spawn_blocking and forwards. One transaction body, one
  truth — a future change to the agent-deletion strategy or the VACUUM
  flow (e.g. adding a new per-agent table) only has to land in one
  place. Substrate.rs:203-205 already warned about exactly this kind
  of cross-place coupling.

* Rewrite async_wrappers_do_not_park_current_thread_runtime to assert
  on ordering instead of a 25 ms wall-clock threshold. The blocker
  thread captures released_at the instant the lock guard drops; a
  tokio task captures tick_at after a 20 ms sleep. The test asserts
  tick_at < released_at — true in the correct (offloaded) case
  because the tick fires during the 100 ms hold; false in the broken
  case because the runtime is parked until the lock releases, so
  released_at lands first. No timing budget — the test stays
  decisive under heavy CI jitter (Windows / llvm-cov instrumentation
  has been observed to add 30-80 ms per scheduler hop on this repo,
  see #3989 series).

* Add tracking comments to the three async wrappers that don't yet
  have an in-tree caller (structured_get_async,
  get_agent_session_ids_async, delete_canonical_session_async).
  Staged for #3378 part 2 — the comment marks them so a future
  dead-code sweep doesn't remove them before the kernel-side
  migration lands.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file has-conflicts PR has merge conflicts that need resolution no-rust-required This task does not require Rust knowledge size/M 50-249 lines changed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant