Skip to content

fix(build): repair root workspace and sync stale Cargo.lock - #240

Merged
adamgell merged 1 commit into
mainfrom
fix/workspace-lockfile-sync
Jul 11, 2026
Merged

fix(build): repair root workspace and sync stale Cargo.lock#240
adamgell merged 1 commit into
mainfrom
fix/workspace-lockfile-sync

Conversation

@adamgell

Copy link
Copy Markdown
Owner

Problem

main's Check & Test (Rust) gate is red on the cargo audit step (it stays hidden until the earlier cargo deny step passes). Root cause: the tracked root Cargo.lock has been orphaned since the v1.3.2 release.

src-tauri/Cargo.toml carried a leftover empty [workspace] table that detached it from the root workspace. With src-tauri both declaring its own workspace and listed as a root member, cargo update at the root fails:

error: multiple workspace roots found in the same workspace

So the root lockfile could never be refreshed. It still pinned evtx 0.11.2 even though the manifest now requires evtx = "0.12", and cargo audit (which reads that stale root lock) failed on 5 vulnerabilities that aren't in what actually builds and ships (CI builds resolve a fresh lock inside src-tauri):

  • RUSTSEC-2026-0204 — crossbeam-epoch <0.9.20
  • RUSTSEC-2026-0194 / RUSTSEC-2026-0195 — quick-xml <0.41

Changes

  • Remove the obsolete empty [workspace] from src-tauri/Cargo.toml so the root workspace resolves and the single root Cargo.lock is maintainable again. The tracked root Cargo.toml already shields against the worktree parent-capture case the old comment guarded against.
  • Pin build.target-dir to src-tauri/target in .cargo/config.toml so making src-tauri a member doesn't relocate build output. Every release / nightly / CI artifact + cache path (all reference src-tauri/target/...) keeps working with no workflow edits.
  • Minimally sync Cargo.lock: evtx 0.11.2 → 0.12.2 (manifest requirement) and crossbeam-epoch 0.9.18 → 0.9.20 (fixes RUSTSEC-2026-0204). The webview stack (tauri / wry / tao unchanged) is deliberately left alone — this is a lockfile-sync, not a dependency-modernization.
  • Add .cargo/audit.toml ignoring RUSTSEC-2026-0194/-0195 for the remaining quick-xml <0.41, which enters transitively via plist (Tauri) and the Linux wayland-scanner build tooling and can't be bumped without moving the Tauri stack. Mirrors the entries already in src-tauri/deny.toml.

Verification

Local (macOS): cargo check, cargo test (64 passed), cargo clippy -- -D warnings, cargo check --no-default-features, cargo deny check, and cargo audit all pass. CI confirms across Linux/Windows/macOS.

🤖 Generated with Claude Code

Copilot AI review requested due to automatic review settings July 11, 2026 00:27

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR repairs the Rust workspace layout so the repository uses a single, maintainable root Cargo.lock, unblocking CI’s cargo audit gate by ensuring the lockfile matches what actually builds in src-tauri.

Changes:

  • Removes the obsolete empty [workspace] table from src-tauri/Cargo.toml to eliminate the “multiple workspace roots” conflict.
  • Adds .cargo/config.toml to pin Cargo build artifacts to src-tauri/target even when building from the workspace root.
  • Updates the root Cargo.lock (notably evtx and crossbeam-epoch) and adds .cargo/audit.toml to mirror the existing quick-xml advisory ignores.

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src-tauri/Cargo.toml Removes the local workspace root so src-tauri participates in the root workspace/lockfile.
Cargo.lock Synces the root lockfile to current manifest requirements and relevant security fixes.
.cargo/config.toml Pins target-dir to src-tauri/target to preserve existing artifact/cache paths.
.cargo/audit.toml Configures cargo-audit ignores for advisories that can’t be resolved without upgrading the Tauri stack.
src-tauri/deny.toml Aligns advisory ignore commentary for quick-xml with the new audit configuration.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@adamgell
adamgell force-pushed the fix/workspace-lockfile-sync branch from 25f9acd to 5b65ee9 Compare July 11, 2026 00:40
… to npm

The root Cargo.lock had been orphaned since the v1.3.2 release: src-tauri
carried a leftover empty `[workspace]` table that detached it from the
root workspace, so `cargo update` at the root failed with "multiple
workspace roots" and the lockfile could never be refreshed. Two failures
resulted, the second hidden behind the first:

1. The required Rust checks (cargo deny / cargo audit, which scan the root
   lockfile) failed on advisories not present in what actually ships:
     - RUSTSEC-2026-0204 (crossbeam-epoch <0.9.20)
     - RUSTSEC-2026-0194 / -0195 (quick-xml <0.41)
     - RUSTSEC-2026-0190 (anyhow <1.0.103, Error::downcast_mut unsound)
2. The lock froze the Rust `tauri` crate at 2.10.3 while the frontend
   already uses `@tauri-apps/api` ^2.11.1, so `tauri build` aborts with
   "version mismatched Tauri packages" -- breaking the Build jobs, the
   nightly, and releases. This only surfaced once (1) was fixed and the
   Build jobs could run at all.

Changes:
- Remove the obsolete empty `[workspace]` from src-tauri/Cargo.toml so the
  root workspace resolves and the single root Cargo.lock is maintainable
  again. The tracked root Cargo.toml already shields against the worktree
  parent-capture case the old comment guarded against.
- Pin build.target-dir to src-tauri/target in .cargo/config.toml so the
  workspace change does not relocate build output; every release, nightly,
  and CI artifact/cache path (which reference src-tauri/target/...) keeps
  working without edits.
- Sync Cargo.lock: evtx 0.11.2 -> 0.12.2 (manifest requirement),
  crossbeam-epoch 0.9.18 -> 0.9.20 (RUSTSEC-2026-0204), anyhow 1.0.102 ->
  1.0.103 (RUSTSEC-2026-0190), and the Tauri stack (tauri 2.10.3 -> 2.11.5,
  wry 0.54 -> 0.55, tao 0.34 -> 0.35, plugins/runtime) to match the
  frontend's 2.11.
- Add .cargo/audit.toml ignoring RUSTSEC-2026-0194/-0195 for the remaining
  quick-xml <0.41 that enters transitively via plist (Tauri) and the Linux
  wayland-scanner build tooling. Mirrors src-tauri/deny.toml.

Verified locally: cargo check/test/clippy -D warnings/check
--no-default-features, cargo deny check, and cargo audit all pass.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@adamgell
adamgell force-pushed the fix/workspace-lockfile-sync branch from 5b65ee9 to 8ad55ab Compare July 11, 2026 01:02
@adamgell
adamgell merged commit 3ae15a6 into main Jul 11, 2026
15 checks passed
adamgell added a commit that referenced this pull request Jul 11, 2026
Document the user-facing work merged since the 1.3.2 release: log error
navigation (#192), Teams MSIX log collection (#242), session filter
restore + error logging (#244), tail truncation/rotation reset (#243),
and the Tauri 2.11 / build repair (#240). Dependency bumps, CI-internal
changes, and README-only docs are intentionally omitted.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
adamgell added a commit that referenced this pull request Jul 11, 2026
….3.2 (#247)

* chore(deps-dev): upgrade TypeScript 6 -> 7 (native compiler, GA)

TypeScript 7.0.2 -- the native Go compiler, GA'd 2026-07-09 -- is a clean
drop-in for this frontend. No source changes were required:

- `tsc --noEmit`: 0 errors
- `tsc && vite build`: passes
- vitest: 123/123 tests pass

Type-checking is ~5.5x faster: `tsc --noEmit` drops from ~3.79s to ~0.69s
(macOS, warm). vite and vitest transpile via esbuild and are unaffected;
tsc is used only for the type-check gate (CI "TypeScript Check" and the
`frontend:build` script), so both simply get faster.

The lockfile grows because the native compiler ships as per-platform
binary packages (@typescript/typescript-<os>-<arch>) via
optionalDependencies, resolved per-platform on install -- the same model
as esbuild/swc. linux-x64, win32-x64 and darwin binaries are all present,
so `npm ci` resolves correctly on every CI platform.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* docs(changelog): note TypeScript 7 upgrade (#247)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

* docs(changelog): catch up [Unreleased] with changes since 1.3.2

Document the user-facing work merged since the 1.3.2 release: log error
navigation (#192), Teams MSIX log collection (#242), session filter
restore + error logging (#244), tail truncation/rotation reset (#243),
and the Tauri 2.11 / build repair (#240). Dependency bumps, CI-internal
changes, and README-only docs are intentionally omitted.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
adamgell added a commit that referenced this pull request Jul 25, 2026
…rectory (#274)

* chore(ci): pin download-metrics actions to SHAs and fix dependabot cargo dir

download-metrics.yml was the only workflow still using mutable tag refs
(actions/checkout@v7, actions/setup-node@v7) while every other call site in
the repo is SHA-pinned with a version trailer. It is also the worst place to
keep a floating ref: it runs unattended on cron with `contents: write`, passes
github.token into the collector, and pushes commits to the download-metrics
branch. Pin both to the same SHAs the rest of the repo now uses.

This is also why dependabot titled the recent bumps "from 4 to 7" -- it reports
the lowest version present, and these two floating tags were the only v4 left.

Separately, the cargo ecosystem pointed at /src-tauri, but PR #240 moved the
workspace lockfile to the repo root; there is no src-tauri/Cargo.lock. As a
result dependabot has opened no cargo PRs since the move and the Rust
dependency half never self-heals. Point it at "/".

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016nQJNW7RKRuRRfzfdvtQYR

* chore(deps): align tauri-plugin-dialog Rust half to 2.7.2

PR #272 bumped the npm half of @tauri-apps/plugin-dialog to 2.7.2 while the
Rust half stayed at 2.7.1, since dependabot's cargo ecosystem was pointed at a
directory with no lockfile (fixed in the previous commit).

No functional impact today -- 2.7.2 is an Android-only fix and the npm tarballs
for 2.7.1/2.7.2 differ only in the version field -- but this repo keeps the two
halves aligned by convention, and the frontend suite cannot catch plugin drift
at all (src/test-setup.ts mocks @tauri-apps/plugin-dialog wholesale).

Edited surgically rather than via `cargo update`, which additionally unified
windows-sys to 0.61.2 across ~15 crates and bumped getrandom 0.3.4 -> 0.4.2 --
unrelated churn on the Windows build surface. Dependency sets for 2.7.1/2.7.2
are identical (log's req tightens to ^0.4.21; resolved log is 0.4.29).

Verified: cargo metadata --locked exits 0, cargo check --locked --workspace
passes, and cargo leaves the lockfile untouched at 2 changed lines.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016nQJNW7RKRuRRfzfdvtQYR

* docs(changelog): record the 2026-07-20 dependency batch and pin follow-ups

Adds an [Unreleased] entry covering #268, #269, #270, #271, #272 and this
branch's own fixes.

Describes the action bumps by what they actually change rather than echoing
dependabot's titles: main was already SHA-pinned to checkout v7.0.0 everywhere
except download-metrics.yml, so "checkout from 4 to 7" is really v7.0.0 ->
v7.0.1 across ten steps. Version claims verified against the merged lockfile.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016nQJNW7RKRuRRfzfdvtQYR

---------

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
@adamgell
adamgell deleted the fix/workspace-lockfile-sync branch July 30, 2026 00:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants