35 Commits
Author SHA1 Message Date
dependabot[bot] fdc51a8f2a build(deps): Bump rusqlite from 0.42.0 to 0.43.0 (#114)
Bumps [rusqlite](https://github.com/rusqlite/rusqlite) from 0.42.0 to 0.43.0.
- [Release notes](https://github.com/rusqlite/rusqlite/releases)
- [Changelog](https://github.com/rusqlite/rusqlite/blob/master/Changelog.md)
- [Commits](https://github.com/rusqlite/rusqlite/compare/v0.42.0...v0.43.0)

---
updated-dependencies:
- dependency-name: rusqlite
  dependency-version: 0.42.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-11-21 23:54:33 +07:00
poli0981andClaude Opus 5.5 38e0226878 chore(release): 1.6.0
The five places the version lives, moved together: Cargo.toml, Cargo.lock,
package.json, package-lock.json and tauri.conf.json. `cargo metadata
--locked` agrees.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-21 23:22:12 +07:00
poli0981andClaude Opus 5.5 ccae96dbeb chore: move to poli0981org — self-contained CI, Qodana, an npm licence gate, this week's dependencies (#119)
The repository now lives in the poli0981org organization, and this makes it at home there.

- main was red since 2026-11-18: RUSTSEC-2026-0543 (chrono), in Cargo.lock only through serde_with's weak features and compiled into nothing; ignored with its reason and exit condition.
- Supersedes #113–#118 (Rust 1.100.0, rusqlite 0.42.0, Tauri 2.12.6, code-health pins, actions, npm) plus jsdom 31.0.1; minimatch 11 closes GHSA-g3hv-75wg-m249. rfd 0.18 (#112) is held again until tauri-plugin-dialog moves.
- Dependabot's tauri groups never worked (it picks the most specific group); exclude-patterns on the catch-alls fix it.
- CI is self-contained: no workflow calls poli0981/.github; every action is pinned by commit; notify.yml vendors the Discord notifier.
- npm licences: scripts/check-licenses.mjs, deny.toml's allowlist for the npm half. Required, with cargo deny and tauri lockstep — eight required checks.
- Qodana in two parts (Rust, TS/JS), full scans, a triaged Rust baseline, fail on anything new. The Rust container needed its toolchain and CARGO_HOME pointed somewhere writable before it analysed anything.
- SonarQube Cloud analyses into poli0981org_pipdock; every npm ci runs with --ignore-scripts (S6505).
- Every repository URL points at the organization. README's attestation command for 1.4.0/1.5.0 had stopped working; it now says --owner poli0981 --signer-repo poli0981/pipdock.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-21 21:50:41 +07:00
poli0981andClaude Fable 5.2 95e45d7acc chore(release): 1.5.0
The five places the version lives, moved together: Cargo.toml, Cargo.lock,
package.json, package-lock.json and tauri.conf.json. `cargo metadata --locked`
agrees.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-10 20:01:03 +07:00
poli0981andClaude Opus 5.5 093ea4fce4 build(deps): dependencies to latest; classify pip 26.3's backend-unavailable (#102)
- cargo update (~60 bumps, 627 -> 616 crates) clears the yanked async-executor 1.14.0 that
  had turned cargo audit red on main and on every Dependabot PR since 2026-11-03 (Linux-only,
  never in the shipped binary). rusqlite 0.41.1 (SQLite 3.54.1), no code change. rfd 0.17 with
  tauri-plugin-dialog 2.8.4, which met the rfd ignore's own condition, so the ignore goes.
- npm: thirteen packages to latest; TypeScript still held at 6.0.3 (typescript-eslint peers <6.1).
- Tools: ruff 0.17.3, certifi, msgpack, platformdirs; constraints regenerated.
- Actions: taiki-e/install-action v2.87.32, sonarqube-scan-action v8.4.0; Node 24 -> 26 LTS.
  "Latest" means the newest release past each ecosystem's Dependabot cooldown.
- pip 26.3 renders an unloadable build backend as `error: backend-unavailable`, which fell
  through to PD-BLD-003; a classifier rule restores PD-BLD-002. Found by the drift job; live
  corpus re-captured with pip 26.3 / uv 0.13.7, the 26.2.1 capture frozen as pip-26.2/, and a
  test holds both renderings to one code.
- Docs: ARCHITECTURE §10 re-verified, ERROR-CATALOG, TESTING, ROADMAP, CLAUDE.md.

Supersedes #97, #98, #99, #100, #101.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-04 10:21:48 +07:00
dependabot[bot] df1ad1518d build(deps): Bump rfd (#96)
Bumps the cargo-minor-patch group with 1 update: [rfd](https://github.com/PolyMeilex/rfd).


Updates `rfd` from 0.16.0 to 0.16.1
- [Release notes](https://github.com/PolyMeilex/rfd/releases)
- [Changelog](https://github.com/PolyMeilex/rfd/blob/master/CHANGELOG.md)
- [Commits](https://github.com/PolyMeilex/rfd/commits)

---
updated-dependencies:
- dependency-name: rfd
  dependency-version: 0.16.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: cargo-minor-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-10-28 09:33:31 +07:00
dependabot[bot] 41ab1e8085 build(deps): Bump the cargo-minor-patch group across 1 directory with 3 updates (#92)
Bumps the cargo-minor-patch group with 3 updates in the / directory: [tokio](https://github.com/tokio-rs/tokio), [tauri](https://github.com/tauri-apps/tauri) and [tauri-build](https://github.com/tauri-apps/tauri).


Updates `tokio` from 1.53.3 to 1.54.1
- [Release notes](https://github.com/tokio-rs/tokio/releases)
- [Commits](https://github.com/tokio-rs/tokio/compare/tokio-1.53.3...tokio-1.54.1)

Updates `tauri` from 2.12.4 to 2.12.5
- [Release notes](https://github.com/tauri-apps/tauri/releases)
- [Commits](https://github.com/tauri-apps/tauri/compare/tauri-v2.12.4...tauri-v2.12.5)

Updates `tauri-build` from 2.7.3 to 2.7.4
- [Release notes](https://github.com/tauri-apps/tauri/releases)
- [Commits](https://github.com/tauri-apps/tauri/compare/tauri-build-v2.7.3...tauri-build-v2.7.4)

---
updated-dependencies:
- dependency-name: tokio
  dependency-version: 1.54.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
  dependency-group: cargo-minor-patch
- dependency-name: tauri
  dependency-version: 2.12.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: cargo-minor-patch
- dependency-name: tauri-build
  dependency-version: 2.7.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: cargo-minor-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-10-25 07:47:00 +07:00
poli0981andClaude Opus 5.5 4a617722d6 ci(sonar): CI-based SonarQube Cloud analysis, with Rust and TypeScript coverage (#85)
Automatic analysis could not build, so it never analysed the Rust two
thirds of the code and imported no coverage; it also sent no project
version, leaving the previous-version new-code period anchored to the
first analysis. sonar.yml runs on Windows, produces cargo-llvm-cov and
vitest LCOV plus clippy's JSON, and scans with sonarqube-scan-action
v8.3.0 (pinned), passing the version from package.json. The token
reaches the scan step alone; the job is skipped without one (Dependabot,
forks) and refuses a dispatch off main, which this plan cannot analyse.

Unblocks the required audits, red on main since 2026-10-21:
rustls-webpki 0.103.16, webpki-root-certs 1.0.11, clipboard-win 5.4.3,
zod 4.6.7. Dependabot groups vitest with @vitest/*.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-25 06:38:10 +07:00
poli0981andClaude Opus 5.5 6cd7e99385 chore(release): 1.4.0
The version in all five places it lives — Cargo.toml, Cargo.lock, package.json,
package-lock.json and tauri.conf.json — checked with `cargo metadata --locked` and with the
release workflow's own tag check run locally against v1.4.0.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 00:55:27 +07:00
poli0981andClaude Opus 5.5 42f227c1aa fix: what installing the build found, and what the doc pass turned up
The release build was installed and driven before tagging. Two defects showed up that no suite
could see:
- Every dialog opened in the window's top-left corner. Tailwind's preflight sets `margin: 0` on
  everything, which removes the `margin: auto` a modal <dialog> is centred by; PdDialog (and so the
  uninstall guard, since it was written) and the Ctrl+K palette were both affected. `m-auto` /
  `mx-auto`, measured in the dev server: (0,0) before, centred after.
- On a profile that had never downloaded the index, Search said "preparing the package index"
  for ever and never offered the download. Moving the load into the background let a failed load
  restart on the next search, which reset the slot to Warming before the failure could be read,
  and the screen asked again every 150 ms. A failed load now stays failed until a refresh; a test
  in state.rs failed first against the old rule.

From the documentation pass, each checked against the code:
- The GUI's snapshot diff used the plain diff while the CLI's and the rollback used the
  engine-aware one, so the two heads disagreed about pip and setuptools across engines (G5).
- `--json`'s help still promised NDJSON; `--yes`, `--quiet`, `--verbose`, `--log-file`, the
  install spec and `engine` described behaviour they did not have. Corrected, and the 32 help
  goldens re-blessed for exactly those lines. `pipdock engine` now marks the configured engine,
  as its help always said; `health --fix` printed a dirty-tree warning to stdout before its JSON;
  the text preview now lists withdrawn releases, as the GUI's does.
- Copy that promised what the code does not do: a pinned package "can still be updated on its
  own" (an Exclude pin filters a named package too), a held pin left only "out of bulk updates",
  and an empty Environments screen pointing at a Browse… button that does not exist.
- Stale comments in exec, the pip and uv parsers, index refresh, health, the pin screen, the
  status line, the settings store and i18n.ts (whose missing-key warning never fires). The
  ExecutionSummary.cancelled description is part of the public schema, so that golden and the
  TypeScript bindings move with it.
- Metadata lookups reuse the shared HTTP client (M37 had been half done); insta was a dev
  dependency of core that nothing in core used; the integration workflow's checkouts no longer
  persist credentials; the capability file cites SECURITY §4, where the rule lives.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 00:55:27 +07:00
poli0981andClaude Opus 5.5 040571c7f7 fix(cli)!: one JSON document per command, env use is honoured, Ctrl-C stops the run
Changed for scripts: every `--json` invocation now prints exactly one document on stdout
(CLI-SPEC §6), with prompts, previews-before-a-prompt and prose on stderr (X5). The preview and
then the summary used to be two documents, so `pipdock install x --json | ConvertFrom-Json`
failed on the second. The document is: the ResolutionReport when nothing runs (a dry run, an
empty plan, a declined prompt - exit 2), the ExecutionSummary when something does, the FlowStep
when there is nothing to plan, the GuardReport for a refused removal (with --force, only the
summary), and the entity itself for env use, pin add/remove, snapshot create, engine and
pip-upgrade ({before, after}). Prompts moved to stderr in both modes.

- `env use` is honoured (X3): --env, then the default it set, then a .venv here - as --env's help
  always said. It was written and never read. A default whose interpreter is gone is said and
  skipped. The help line says "the one `env use` set" now (32 help snapshots re-blessed for that
  line alone).
- Ctrl-C (and Ctrl-Break, which a supervisor can send) trips the flow's token (X6): the engine's
  process tree is killed, what ran is summarized with the snapshot to roll back to, and the exit
  is 130; a second press quits at once. Verified against a resolve hung on a server that never
  answers: exit 130 the instant the signal arrived, no python left running.
- `update` with neither names nor --all exits 2 instead of planning nothing (X16); `audit` uses
  --engine (X14); `engine` needs no environment (X15); `doctor` judges the configured engine, not
  pip, so a uv-only venv passes (no pip is the uv default); an impossibility skipped off a TTY says
  what and why (X26); `list` probes once instead of twice (X28); names and versions honour
  `{:<32}` (X27); `snapshot diff` compares the way a rollback would across engines.

Verified with a script driving the real binary through each of these: every stdout parses as one
JSON document and every exit matches CLI-SPEC §5.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 00:55:27 +07:00
poli0981andClaude Opus 5.5 77ca18cc33 feat(app): the GUI logs, says when it cannot start, and shows where the log is
- The GUI writes data\logs\pipdock.<date>.log through the same core::logging the CLI uses, with
  the panic hook installed, so a crash leaves a record where it used to leave nothing.
- A data folder that cannot be opened is said in a dialog before any window exists (U18). The
  store was opened inside Tauri's setup hook, whose failure is a panic in the event loop: a
  release build has no console, so the user double-clicked and nothing happened. It now opens
  before Tauri starts, and the failure shows the code, the message and the log path through
  rfd - already in the tree via tauri-plugin-dialog, so Cargo.lock gains one dependency edge and
  no crate. It is the one place GUI copy is written in Rust (both languages at once), because no
  webview exists yet to load a catalog.
- logs_tail returns LogTail { dir, lines } - a new schema, so schema-LogTail is blessed and
  schema-unknown-type lists one more type. NOT_YET is down to one entry, env_add_manual.
- Settings gains a Logs row: the folder, as a path, and "Copy recent log", which re-reads the tail
  at the moment of copying so the clipboard holds the run that just went wrong. The clipboard
  permission "Copy full log" already had is enough; no capability changes. en + vi copy.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 00:55:27 +07:00
poli0981andClaude Opus 5.5 91a846c0fd build(deps): every dependency to its latest release
Supersedes Dependabot #75, #76 and #77, which could not merge while `main`'s audits were red.

Rust (floors raised to what is locked, so the manifests say what is built):
- tauri 2.11.5 → 2.12.4 and tauri-build 2.7.3, with the plugins dialog 2.8.3, opener 2.7.2,
  clipboard-manager 2.5.0 and single-instance 2.5.4 — in lockstep with `@tauri-apps/*` 2.12, which
  Tauri's own version check requires.
- **rusqlite 0.37 → 0.40.2** (libsqlite3-sys 0.38.2, SQLite 3.53.2). ARCHITECTURE §10 held it
  because libsqlite3-sys used the then-unstable `cfg_select!`; that is stable since 1.95 and the
  toolchain is now 1.99.1. Nothing here used `u64`/`usize` `ToSql` (disabled by default since
  0.38) or `prepare_cached` (optional since 0.38), and 0.40.1 fixes a SAVEPOINT-name injection.
- reqwest 0.13.5, tokio 1.53.3, tokio-util 0.7.20, jiff 0.2.38, clap 4.6.7, schemars 1.2.3,
  sha2 0.11.1, thiserror 2.0.21, serde_json 1.0.154, async-trait 0.1.92, insta 1.49.0, and 211
  transitive updates (h2 0.4.20 among them).

npm: React 19.3.1, Vite 8.3.4, @vitejs/plugin-react 6.1.2, **Vitest 5.0.5** (all 18 `vi.mock`
calls were already top-level), ESLint 10.12.0, typescript-eslint 8.71.2, jsdom 30.1.3,
@tanstack/react-virtual 3.14.21, i18next 26.4.7, react-i18next 17.0.19, @types/* current.
**TypeScript stays 6.0.3**: typescript-eslint 8.71.2 still peers `>=4.8.4 <6.1.0`.

Code Health pin: ruff 0.16.3 → 0.17.1. Verified by running it, not by reading its changelog:
`health/sample/capture.py` reproduces all four committed `ruff/*.json` byte for byte, and exit
codes 0/1/2 still mean clean/findings/error.

Two things the upgrade surfaced in the frontend, both real:

- virtual-core 3.19 measures the scroll element with `clientWidth`/`clientHeight` (it used
  `getBoundingClientRect()`), and that first reading replaces `initialRect`. jsdom reports 0, so 13
  table tests and 5 App-level ones went back to rendering an empty grid; the setup now stubs the
  two properties beside the `offset*` ones.
- jsdom 30.1 implements "a closed `<dialog>`'s contents cannot take focus", which is the spec.
  React applies `autoFocus` by calling `focus()` during commit — *before* PdDialog's effect calls
  `showModal()` — and never writes the `autofocus` attribute, so neither path focused Cancel. It
  worked in WebView2 only because Cancel is the first focusable element. PdDialog and the palette
  now focus explicitly after `showModal()`, and return focus to whatever opened them on close
  (it fell to `<body>` before).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 00:55:27 +07:00
poli0981andClaude Opus 5.5 d9c62ec6c9 fix(deps): rustls 0.23.46, quinn-proto 0.11.19, and the npm highs — main is green again
`main` has failed `cargo audit` since 2026-09-23 and every PR with it, because both audit checks are
required:

- rustls 0.23.42 → 0.23.46 (RUSTSEC-2026-0285, TLS 1.3 handshake messages accepted across key
  changes). `cargo update -p rustls` alone stops at 0.23.43: the fix needs aws-lc-rs 1.18 and
  rustls-webpki 0.103.15, which a conservative update will not move, so it is pinned with
  `--precise`.
- quinn-proto 0.11.16 → 0.11.19 (RUSTSEC-2026-0338..0342). Lockfile-only — nothing compiles quinn
  — but `cargo audit` scans the whole lockfile.
- chacha20 0.10.1 → 0.10.2 (the old one is yanked).
- npm: undici 8.9.0 → 8.12.2 (via jsdom), source-map-js 1.2.1 → 1.2.2, brace-expansion → 5.0.12, all
  dev-only. `npm audit fix` without `--force`; `npm audit --audit-level=high` reports 0.

Dependabot could not have done this: there are no Dependabot alerts for rustls, and its grouped PRs
only move direct dependencies.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-17 00:55:27 +07:00
poli0981andClaude Opus 5 f770e9c85f fix(deps): h2 0.4.16 — RUSTSEC-2026-0258
Unrelated to this slice, and blocking its required `cargo audit` gate.
`main` is equally affected: the advisory was published 2026-08-17 and
reached the RustSec database at 10:23+02:00 on the 18th, while main's
last audit ran at 07:08 that morning and passed. The next push to main
would have failed on it regardless of this branch.

Low severity, denial-of-service: h2 accepted and queued empty DATA
frames without limit, so an undrained stream could grow memory without
bound or panic on length overflow. Reached transitively through
reqwest and hyper; PipDock's only network use is the package index and
metadata fetches, both to pypi.org, so nothing here is exposed to an
attacker-chosen peer. Fixed rather than ignored anyway, because
SECURITY.md is explicit that the vulnerability gate is never relaxed —
the `.cargo/audit.toml` ignore list is for *informational* advisories
on crates we cannot influence, and this one has a patch release.

`cargo update -p h2 --precise 0.4.16` and nothing else. The lockfile
diff looks alarming and is not: sixteen of its eighteen lines are
dependency *edges* re-pointing between `windows-sys` copies that
already coexist in the lock — five of them before this change and five
after. No package is added, removed or downgraded, and the only version
that moves is h2's own. `cargo check --workspace --all-targets` and the
full test suite pass on it.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-21 08:35:15 +07:00
poli0981andClaude Opus 5 02cc17d95d docs: the dependency view recorded, and 1.3.0
UI-SPEC §4 gains the screen and **loses the sentence it contradicted**.
It said the third row action folds all three into a `⋮` menu "with the
budget intact"; that makes uninstall four clicks where §5's table
records three, hand-counted. The correction is written as a correction
rather than an overwrite, because the reason it slipped through is the
useful part: four is under the ceiling of five, and a ceiling is not a
ratchet — a table of measured counts is. §5 gains the row, §6 the
component, ARCHITECTURE §4 the forward direction and the whole-graph
value.

**The dangling cross-reference is repaired by writing what it promised.**
`ROADMAP.md` has pointed at "the analysis above" for what blocks P1-6
and P1-7 since 1.2.0, and no such analysis was anywhere in the document
— the survey lived only outside the repository, and the sentence had
been copied into CLAUDE.md as well. P1-6's half is its slice record.
P1-7's is now written too, and counted against the tree rather than
recalled: no toast component, no notification/autostart/tray dependency,
one plan-scoped `tokio::spawn` and zero intervals in either head, and no
surface that can report a failure at 03:00 while `logs_tail` is still
`NOT_YET`. Drafting this commit I nearly shipped a CLAUDE.md line
claiming that survey existed before I had written it, which is the same
defect one layer up.

Version in five places, moved together: the workspace inherits it, so
`Cargo.toml`, `package.json` and `tauri.conf.json` are the only hand
edits and the two lockfiles are regenerated. Hand-editing `Cargo.lock`
would have been wrong twice over — `scopeguard` and `simd_cesu8` are
also at 1.2.0 and `fs_extra` was already at 1.3.0. `cargo metadata
--locked` passes, which is the one-command check.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-21 08:35:15 +07:00
poli0981andClaude Opus 5 bee85dcdc2 chore(release): 1.2.0, and the Security tab recorded
Version in all five places — `Cargo.toml`, `Cargo.lock`, `package.json`,
`package-lock.json`, `tauri.conf.json` — and `cargo metadata --locked` verified after,
which is the one-command check that would have caught the `thiserror` lockfile
breakage that had `main` red for a day in Phase 4.

The ROADMAP stage record, and three rules in CLAUDE.md that the diff does not show:

- **A spec can promise a field that has never existed.** SECURITY §6 and PRD P1-1 both
  asked for a severity pip-audit publishes under neither vulnerability service, and §6
  named a venv the code had refused since P2. Found by running the tool and reading its
  JSON, not by reading the specs against each other. When a spec describes an external
  tool, the tool is the authority.
- **A watchdog is a unit, not a number.** Borrowing Code Health's 120 s gave an audit a
  linter's budget for a network fetch, and it fired on the first real run. A borrowed
  constant carries its original units with it.
- **Adding a field to a struct that is summed is a bug the suite will not see.**
  `total_bytes` kept adding three entries after a fourth arrived, with every cache test
  green.

Post-1.0 is down to two items: the dependency-graph view and the scheduled check.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-18 10:55:11 +07:00
poli0981andClaude Opus 5 edb7544b93 chore(release): 1.1.0, and the P1 wave closed
Five places again — Cargo.toml, Cargo.lock, package.json, package-lock.json,
tauri.conf.json — and `cargo metadata --locked` earned its place in the checklist by
failing on the first attempt, exactly the way `main` was broken this morning. The
shipped CLI reports `pipdock 1.1.0`.

The stage record covers all four slices and the four things running them said that
reading could not: 94 suggestions on a real environment, a parser that turns prose
into a package name, a cache manager for a logs directory that does not exist, and a
palette that ranked an action above the screen it belongs to.

**One PRD row corrected rather than ticked.** P1-4 asked for the engine caches
(`pip cache`, `uv cache`) as well as PipDock's own. Those belong to the engine, live
outside `%LOCALAPPDATA%\PipDock\`, and purging them is a subprocess rather than a
file delete — a different feature wearing the same word. The row says "partly
shipped" and names what is missing, and the roadmap's open list carries it.

UI-SPEC §1's "signature moves" sentence stops saying the palette is P1; §8 gains
Ctrl+K; §4 gains the Disk usage section and why it lists three artefacts.

Two rules into CLAUDE.md, both paid for this afternoon: a parser correct for trusted
input is a hole for untrusted input, and check a thing exists before shipping a size
and a Clear button for it.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-14 21:16:52 +07:00
poli0981andClaude Opus 5 196f0408e4 chore(release): 1.0.0
Five places, and they have to move together — a stale lockfile is exactly how `main`
has been red since 3eeda05. `cargo metadata --locked` is the check that they did, and
it passes.

The 58 CLI goldens do not churn: `golden.rs` filters any x.y.z to [VERSION], which is
why that filter was added.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-14 17:32:20 +07:00
poli0981andClaude Opus 5 2f81b0c6ca fix(build): the lockfile edge that made every cargo job fail
`main` has been red since 3eeda05. `Cargo.lock` carried a dependency edge to
`thiserror 2.0.19` while its own package entry said `2.0.20` — a lockfile Cargo
wants to repair and `--locked` forbids repairing, so every cargo job in every
workflow died before compiling a crate:

    error: cannot update the lock file ... because --locked was passed to prevent this

The Dependabot bump (b4ab2d9) moved the package entry; 2abfef6 touched the file
afterwards and the stale edge survived. CI had gone green on a base predating
the bump, which is the same shape as the ruff-pin defect recorded in P4.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-14 17:32:20 +07:00
poli0981andClaude Opus 5 2abfef6a7c fix(ui): one window, one way back, and a sidebar that stops mid-plan
Four things from the first real click-through of the installed build.

**Two "Back to packages" buttons after a successful run.** `PdSummarySheet` renders `plan.done`
from its `onDone`, and the panel rendered a second one beneath it. The panel's is now shown
only when there is no sheet — a run that failed before producing an `ExecutionSummary` has an
error row and nothing else, and without a button that phase is a dead end.

Worth naming *why* no test caught it: `PdSummarySheet` has its own tests and `PdPlanPanel` had
none, so the two had never been rendered together. `PdPlanPanel.test.tsx` now does exactly
that, and it was checked against the bug — reverting just the panel change makes it fail with
"expected 2 to have length 1". Adding it exposed a second gap: `ipcMock` had no `reportBugUrl`,
which `PdErrorRow` asks for on mount, so any screen containing an error was untestable.

**No single instance.** Five launches gave five windows — which is five `AppState`s over one
machine: five `Sessions` slots, each certain it owned the mutation in flight, and five
`PD-RES-003` guards that cannot see each other. `tauri-plugin-single-instance` is registered
**first**, before any plugin that could take a lock, and the handler unminimizes before
focusing: focusing a minimized window leaves it minimized, and the user's second launch
appears to do nothing.

Added without the `deep-link` feature `cargo add` selects by default — PipDock registers no
deep links, and it pulls three crates into the audit surface for nothing.

**The sidebar is disabled while a plan owns the content area.** Navigating away left the plan
parked in Rust with nothing on screen driving it, and the next Update answered `PD-RES-003`
about a plan the user could no longer see. `App.tsx` already refuses `Ctrl+1..8` while the
guard dialog is open; this is that rule applied to the panel and to the mouse.

**The window is bounded and cannot be maximized.** `maxWidth`/`maxHeight` at 1600×1100 with
`maximizable: false` and `fullscreen: false`. The layout is a fixed sidebar plus one scrolling
column; stretched across a 4K panel it is a column of text with a metre of empty surface.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-13 22:08:38 +07:00
dependabot[bot] b4ab2d94ce build(deps): Bump the cargo-minor-patch group across 1 directory with 3 updates
Bumps the cargo-minor-patch group with 3 updates in the / directory: [async-trait](https://github.com/dtolnay/async-trait), [thiserror](https://github.com/dtolnay/thiserror) and [clap](https://github.com/clap-rs/clap).


Updates `async-trait` from 0.1.91 to 0.1.92
- [Release notes](https://github.com/dtolnay/async-trait/releases)
- [Commits](https://github.com/dtolnay/async-trait/compare/0.1.91...0.1.92)

Updates `thiserror` from 2.0.19 to 2.0.20
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/2.0.19...2.0.20)

Updates `clap` from 4.6.4 to 4.6.6
- [Release notes](https://github.com/clap-rs/clap/releases)
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/clap-rs/clap/compare/clap_complete-v4.6.4...clap_complete-v4.6.6)

---
updated-dependencies:
- dependency-name: async-trait
  dependency-version: 0.1.92
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: cargo-minor-patch
- dependency-name: thiserror
  dependency-version: 2.0.20
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: cargo-minor-patch
- dependency-name: clap
  dependency-version: 4.6.6
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: cargo-minor-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2026-08-13 22:04:59 +07:00
poli0981andClaude Opus 5 1bc103bc75 feat(app): the plan session, and the four commands that drive it
The architectural centre of S3. `UpdateFlow` is a **resumable state machine** and IPC is
stateless: `plan_resolve` builds the flow, the user reads the preview, and `plan_decide` or
`plan_execute` arrives as a separate message seconds later. Something has to hold the flow
in between, and that is `PlanSlot` in `AppState`.

**One plan at a time, and `PD-RES-003` when a second arrives.** Nothing structurally
prevents it — the calls are independent messages — and two concurrent plans would interleave
engine commands against one environment while DATA-FLOW §9.3's staleness check compared
against a set the other plan was busy changing. `claim()` takes the slot before any work,
and **every** exit path releases it: a claim that leaks would leave the session refusing
plans forever, which is the failure mode this design has to be careful about.

`Busy` moves the flow out rather than borrowing it, because `execute` awaits for as long as
the install takes and holding the slot's lock across that would block `plan_cancel` — the
one command that must work precisely then. For the same reason the cancellation token lives
in its own lock, held only long enough to read an `Option`.

**`UpdateFlow::start` now takes the pins, not the `Store`.** Not a tidy-up: `Store` wraps a
`rusqlite::Connection` and is `Send` but not `Sync`, so a future holding `&Store` across an
await is not `Send` and a Tauri command cannot return one. It did not compile. Reading the
pins first is one synchronous line at each call site, and the flow no longer reaches into a
database at all — it can now be driven in a test without one.

`plan_execute` returns the snapshot alongside the summary. The CLI prints the id *before*
execution because DATA-FLOW §3 draws them as distinct states; the summary sheet needs it
*after*, to offer the rollback. One envelope beats a second command to go and look it up.

`PD-RES-003` went through the whole catalog process rather than round it: the "no code
without a fixture" gate rejected it until it was listed as internally raised with the module
that owns it, and both locale catalogs carry its copy — otherwise `PdErrorRow` would show
`errors.unknown` for a condition PipDock raises itself. `Decision` joins SCHEMA_TYPES too,
since `PdConflictRow` needs the 3-way type.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-04 18:47:15 +07:00
poli0981andClaude Opus 5 346fbfad7a feat(core): cancellation now kills the whole process tree
Deferred from Stage 1 to the slice that could verify it. S3 is that slice: `python -m pip`
spawns build backends and compilers for any source distribution, and cancelling a build is
precisely when a user needs the stop to mean something.

`kill_on_drop` reaches the direct child only. A `TreeGuard` puts each spawned child into a
Windows Job Object with `JOB_OBJECT_LIMIT_KILL_ON_JOB_CLOSE`, so everything the child goes
on to spawn joins the same job and closing the handle terminates all of it. `run()` now
spawns rather than calling `.output()`, which owns the child and never lends out a handle.

`win32job` is a safe wrapper, so `unsafe_code = "forbid"` stays absolute and no unsafe
block enters the codebase. It locks exactly one new package — its `thiserror` and `windows`
dependencies are already in the tree via Tauri. Attaching is best-effort: if the job cannot
be created the guard is `None` and behaviour is exactly what it was, since `kill_on_drop`
still ends the direct child.

**The first version of this test was wrong, and the mutation check is what caught it.**
It measured wall-clock time for `run()` to return — but both stop paths return as soon as
their future resolves, so it passed in 200 ms while the orphan lived on, and passed *again*
with the guard disabled, taking 29 seconds to do it. Whether the grandchild is still alive
is the only observable that separates the two outcomes, so the test now asks the OS for a
process count by command-line marker. With the guard disabled it fails `left: 1, right: 0`;
with it, the whole exec suite runs in 3.4 s instead of 29.

Both stop paths are covered — cancellation and the watchdog — because they are two different
drops of the same guard and only one of them had ever been exercised on a tree.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-04 18:47:15 +07:00
poli0981andClaude Opus 5 a553bf7460 feat: the first working screens — legal gate, Environments, Settings
Stage 1's vertical slice. The bridge that has been names-only since Phase 0 now
carries real data end to end, and there is something to look at.

Environments is the right first screen because it exercises the whole bridge with
zero mutation risk: multi-process discovery with live progress, three error codes,
the PEP 668 MANAGED chip, the hidden_user_site partial-listing note, an empty
state, and a selection that feeds the status line. The legal gate ships with it
rather than last -- it is the first thing the app renders, so leaving it for later
would mean every manual test session for months starts on a screen that is not the
real one.

What had to exist first:

  - core::settings. Engine choice lived in pipdock-cli behind a private KEY_ENGINE,
    so the Settings screen would have had to guess the same key and encoding. A
    setting written by one head and unreadable by the other is worse than none.
  - scan-progress finally has a producer. ARCHITECTURE section 7 names the event
    and never says what it carries; ScanProgress is that payload. Discovery is the
    slowest thing PipDock does before it can show anything -- a registry walk,
    py -0p, uv python list and a venv scan, each spawning processes -- so a first
    screen that sits blank through all of it is the worst possible first
    impression.
  - docsHash, referenced twice in the docs and defined nowhere. Computed at build
    time in build.rs, because the documents are deliberately not shipped: the gate
    links to the GitHub copies, so a runtime hash would be a hash of files that are
    not on the user's disk. Verified to change when a document changes and to
    return to its old value when reverted -- it is a re-consent trigger, not an
    integrity check. The SHA-256 is written out rather than pulled in, so nothing
    new joins the supply chain of the thing that decides whether users see the
    gate.

Capabilities are split by concern and scoped, per the comment already in
default.json about never broadening preemptively. Verified in the generated ACL:
opener is allowed only `https://github.com/*`, and clipboard is write-text with
allow-read-text deliberately absent -- nothing here has a reason to read what the
user copied, and a tool that runs subprocesses should not be able to.

Smaller decisions worth naming:

  - A row whose probe failed renders in place with its code rather than vanishing.
    One broken interpreter must not hide the rest, which is the rule env list
    already follows.
  - A consent record that cannot be read fails *closed*. The gate is shown.
  - Tabs without a screen yet stay in place and stay focusable. Hiding them would
    renumber every Ctrl+N after them and make the user learn the map twice.
  - useUiStore is a sixth store beside ARCHITECTURE section 9's five: which tab is
    showing is shell state, not a domain.
  - The i18n parity test now compares plural *bases*. Vietnamese has a single
    plural form (I18N section 1), so a correct vi catalog carries only _other --
    the old test would have reported it as incomplete and pushed the next person
    into adding a bogus _one to silence it.

Verified by launching the real app, not only by tests: it starts, the capabilities
are accepted with the scopes above, and the frontend builds to 275 kB.

226 Rust tests, 19 frontend tests; fmt, clippy, typecheck, lint and npm audit
clean. No `invoke` outside ui/src/ipc.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-30 00:20:57 +07:00
poli0981andClaude Opus 5 3f61c63486 fix(core): kill the child on timeout, and add a cancellation token
The 600 s watchdog never killed anything. Both run paths used
`tokio::time::timeout`, which drops the future — and a tokio `Child` does not kill
on drop by default, so the future went away and pip kept running. That was a live
leak with nothing to do with the GUI; `plan_cancel` just made it visible.

`kill_on_drop(true)` is the whole fix for it, and it is also what makes
cancellation work: both stop paths now drop the future, and dropping ends the
process.

`Command::cancel(token)` adds the second reason to stop. `select!` needs a future
in every arm, so a command without a token gets `pending()` rather than a future
that resolves immediately — otherwise opting out of cancellation would abort the
command instantly.

The process-tree limit is real and worse than "the grandchild leaks". Measured
while writing these tests: `cmd.exe /C ping -n 30` cancelled after 200 ms took the
full 30 s to return. Killing the shell does not kill `ping`, and the surviving
grandchild holds the inherited stdout pipe open, so the read never reaches EOF —
cancellation does not merely leak there, it does not appear to happen. Killing a
tree on Windows needs a Job Object with JOB_OBJECT_LIMIT_KILL_ON_JOB_CLOSE, which
is tracked as follow-up. What this covers is the common case, a network-blocked
engine, which is the one users actually cancel.

That finding also shaped the tests: they spawn the sleeper directly rather than
through cmd.exe, because wrapping it would measure the limitation instead of the
behaviour. `cancelling_kills_the_child_rather_than_orphaning_it` asserts on wall
clock, which is the observable that separates the two outcomes — a killed child
returns in milliseconds, an orphaned one holds the pipe for 30 s.

217 tests, fmt and clippy clean.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-29 23:50:44 +07:00
poli0981andClaude Opus 5 88768c2a9e feat(core): generate the TypeScript bindings from schemars
ARCHITECTURE section 9 says the frontend types are "generated with
specta/tauri-specta to prevent drift". This generates them from schemars instead,
and the deviation is recorded in the module doc rather than left to be discovered.

Why not specta: it is still 2.0.0-rc, and a project that holds rusqlite at 0.37
because 0.38 needs nightly, and refuses eslint-plugin-react over a transitive
advisory chain, cannot coherently take a pre-1.0 dependency into the crate that IS
the product. It would also mean a second derive stack beside the working one --
specta::Type on ~40 types plus hand-written impls for the newtypes. Meanwhile
schemars is already a dependency, the types already derive JsonSchema, and
`pipdock schema <T>` is already a documented public contract (CLI-SPEC section 6),
so this is additive.

What is given up: tauri-specta makes drift a compile error and this makes it a test
failure. One notch weaker at roughly a tenth of the cost, and the generated file
and wrapper layer are identical either way, so adopting specta later is a generator
swap rather than a redesign.

The staleness check lives in `cargo test`, not a bespoke CI step, so it fires
locally too. Its failure names the fixing command and reports the first differing
line -- assert_eq! over 400 lines of generated TypeScript buries the one thing the
reader needs.

Two things the emitter had to get right, both found by looking at the output rather
than by reasoning about it:

  - An externally-tagged variant's payload arrives as an inline object with
    `properties`, which the first draft rendered as `Record<string, never>`.
    `Strategy` and `Trigger` both silently lost their contents -- generated code
    that typechecks and is wrong, which is worse than none. `Strategy` now reads
    `'compatible' | { 'force-latest': { overrides: PkgName[] } }`, and the kebab-case
    tag is quoted because unquoted it parses as a subtraction.
  - A union inside an array needs parentheses: `(string | null)[]`, not
    `string | null[]`.

One limitation, asserted rather than papered over: schemars marks every `Option<T>`
as not-required regardless of serde attributes, so the schema cannot distinguish
`skip_serializing_if` ("key absent") from `serde(default)` ("key present holding
null"). Both emit `?: T | null`, which is a superset of what the wire can carry and
forces the UI to handle either. Narrowing one would assert something the schema
does not say.

Codegen lives in a new `xtask` crate rather than behind a `pipdock` flag:
regenerating TypeScript is a contributor's job, not a user's, and CLI-SPEC section 3
is a contract about what users can run.

206 tests, fmt and clippy clean; npm typecheck, lint and test green over the
generated file.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-29 23:03:00 +07:00
poli0981andClaude Opus 5 d829c4f17c feat!: drop the application self-updater
Removes `tauri-plugin-updater` and everything that existed to serve it.

A self-updater is a permanent remote-code-execution path into a tool that already
runs subprocesses against the user's interpreters, and it has to be defended for
the life of the product: a signing key that must never leak, an endpoint that must
never be spoofable, verification logic that must never be bypassable. For something
people open occasionally to tidy an environment, that is a large standing liability
bought for a small convenience.

It was also never actually functional. `plugins.updater.pubkey` has been the literal
string REPLACE_AT_FIRST_RELEASE_WITH_TAURI_SIGNING_PUBLIC_KEY since Phase 0, so the
capability was granted to a plugin that could not verify anything.

What goes:

  - tauri-plugin-updater, its `plugins.updater` config block and endpoint, and the
    `updater:default` capability
  - the release workflow's signing step, `--bundles ...,updater`, and the *.sig /
    latest.json artifact globs
  - TAURI_SIGNING_PRIVATE_KEY and its password from the secrets bootstrap, and the
    keypair generation item from the RELEASE-CI section 5 checklist

Ten crates leave the dependency tree with it: zip, tar, xattr, filetime,
minisign-verify, osakit, objc2-osa-kit, arbitrary, derive_arbitrary and the plugin
itself -- archive extraction, signature verification and AppleScript execution, none
of which PipDock has any other reason to link.

SECURITY section 4 gets simpler as a result: pypi.org is now the *only* host PipDock
connects to. github.com was on that list solely for the updater; the legal gate and
the bug-report deep link hand a URL to the user's browser rather than fetching
anything.

Users move between versions from the GitHub Releases page and verify SHA256SUMS.txt,
which the README already tells them to do because SmartScreen warns on first run.
Recorded in CLAUDE.md as well: Tauri makes adding this back a three-line change, so
the reasoning needs to outlive the commit.

183 tests, fmt and clippy clean, both Tauri JSON files still valid.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-29 22:20:33 +07:00
poli0981andClaude Opus 5 1c728df64c test(cli): add the L4 golden-output suite
TESTING L4 has been owed since M1. `assert_cmd` and `insta` were already
dev-dependencies with zero references and no `tests/` directory in the crate.

TESTING section 2 asks for "golden-output tests per command against a mocked core",
and the CLI has no seam to mock at: run.rs builds its engine from the global
options and drives a real interpreter, and print_preview / print_summary are
private functions that println! rather than return. So the preview and summary
renderings stay with L2 against real environments, and what is goldened here is
everything deterministic without one -- the clap surface, the exit-code table
CLI-SPEC section 5 calls a public contract, the --json error envelope, and
`schema <T>` for all fifteen SCHEMA_TYPES.

That last group is the point. It pins two contract bugs the M2 bridge has to fix,
so the fix arrives as a reviewable diff rather than as an invisible change:

  - ExecutionSummary serializes plan_id and stderr_tail, where DATA-FLOW section 6
    documents planId and stderrTail
  - Code serializes as its Rust variant name ("EnvInterpreterMissing"), where
    ERROR-CATALOG documents the wire code (PD-ENV-001)

Both are visible in the committed snapshots today. The error envelope, which
main.rs hand-builds rather than deriving, already has the documented shape -- so
the same binary currently disagrees with itself across its two --json paths.

Snapshots are filtered for the executable name (pipdock.exe on Windows) and the
crate version, so they record the contract rather than the machine or the release.
insta gains its `filters` feature for that.

183 tests pass, fmt and clippy clean.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-29 20:26:01 +07:00
dependabot[bot] 5d1e6d21b3 build(deps): Bump schemars in the cargo-minor-patch group (#6)
Bumps the cargo-minor-patch group with 1 update: [schemars](https://github.com/GREsau/schemars).


Updates `schemars` from 1.2.1 to 1.2.2
- [Release notes](https://github.com/GREsau/schemars/releases)
- [Changelog](https://github.com/GREsau/schemars/blob/master/CHANGELOG.md)
- [Commits](https://github.com/GREsau/schemars/compare/v1.2.1...v1.2.2)

---
updated-dependencies:
- dependency-name: schemars
  dependency-version: 1.2.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: cargo-minor-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-07-29 19:56:06 +07:00
poli0981andClaude Opus 5 779c1e8560 feat: complete the M1 command surface and close the milestone
Adds the last commands: env use, pip-upgrade, snapshot rollback, schema,
self report-bug, and engine <pip|uv>. Every P0 CLI command now works
except health, which belongs to M3 with the tools venv.

Rollback follows DATA-FLOW section 8 including the part that is easy to
skip: it snapshots the current state before replacing it, because a
rollback is itself reversible. Verified end to end — installing httpx
0.23.0 and rolling back left the environment with pip alone, and the diff
afterwards reported "matches snapshot".

Two things the compiler and the smoke test caught:

- `pipdock engine pip` was never handled. Only the no-argument form was
  wired, so the documented setter silently did not exist; the
  non-exhaustive match surfaced it once the catch-all arm was removed.
  That catch-all had been hiding it.
- engine_for ignored any stored preference and always returned pip, so
  configuring an engine would have had no effect. It now reads the store,
  and setting an unavailable engine is refused rather than saved —
  storing a preference that cannot be honoured just moves the failure to
  the next command.

schema generates from the Rust types via schemars rather than being
hand-written, because a hand-written schema drifts the moment a field is
added and then lies to every script pinning against it. A test asserts
every advertised type actually resolves.

ci-integration.yml implements TESTING L2: real pip and uv against
throwaway venvs on Windows, across the 3.10 floor and 3.14 ceiling, with
an end-to-end pass that checks the claims the docs make — the SP-1
conflict is still reported and attributed, update/rollback round-trips
leave the environment matching the snapshot, the guard still refuses to
break requests, and the exit codes still match CLI-SPEC section 5. A
weekly job re-captures fixtures against the newest engines so an output
change surfaces as a failed job rather than as PD-ENG-003 on a user's
machine.

The ROADMAP entry is honest about what is not done: L2 has never actually
run, the L4 golden-output tests are not written, and the SP-5 exit
criterion named a real numpy/scipy/pandas environment that the
httpx/httpcore construction stood in for.

173 tests, clippy -D warnings clean, npm audit clean, all workflows parse.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-27 20:26:05 +07:00
poli0981andClaude Opus 5 da1a707e1b feat(core): snapshots and two-phase execution
Two of the DATA-FLOW section 9 invariants stop being rules that review has
to catch and become facts the compiler enforces.

AcceptedPlan has no constructor other than accepting a report, and
execute() takes one along with a Snapshot. A caller that skipped the
preview or skipped the snapshot cannot produce the arguments, so
"no mutating call without an accepted plan and a successful snapshot" is
now structural rather than aspirational.

AcceptedPlan also carries what section 9.3 needs: when it was confirmed
and a fingerprint of the installed set at that moment. Both a stale
preview and one made before the environment drifted are refused with
PD-RES-002, because executing a plan the user did not actually see is the
failure "preview before touch" exists to prevent. The fingerprint is
order-independent -- engines do not promise a stable listing order, and
treating a reorder as drift would refuse valid plans at random.

Execution is the two phases ARCHITECTURE section 8 specifies. Phase A is
one invocation for the whole set; on failure Phase B re-runs per package
and keeps going past failures. The test that matters asserts the owner's
requirement directly: fifteen packages with two bad ones applies thirteen,
visits all fifteen in Phase B, and every failed row carries a catalog
code. Aborting would cost the user thirteen good packages to punish two
bad ones. An engine that cannot even be spawned is recorded as that one
package's outcome rather than discarding the ones that already succeeded.

Snapshots keep two things honest. The sidecar records which engine wrote
the freeze, because pip freezes with --all and uv does not -- without it a
cross-engine diff reads as "pip was uninstalled". And entries that cannot
be restored from an index (editable installs, direct URLs, VCS
requirements) are skipped from the pin set but reported separately, so a
rollback never claims success while leaving the environment different from
the snapshot. The rollback planner touches only what differs; reinstalling
the untouched 198 packages of a 200-package environment would take minutes
and risk failures on packages that were fine.

`snapshot create|list|diff` are wired and verified against a real venv,
including a diff that correctly detects a package installed after the
snapshot was taken.

124 tests, clippy -D warnings clean.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-27 19:40:20 +07:00
poli0981andClaude Opus 5 7366c56366 feat: first working vertical slice — env discovery, adapters, CLI
`pipdock env list`, `list [--outdated]`, `doctor` and `engine` now run
against real environments. Exit codes verified against CLI-SPEC section 5:
0 on success, 3 for a missing environment, 10 for a command that is not
wired yet.

Discovery implements the SP-6 findings rather than the naive version.
Sources are merged by canonical identity, so the Chocolatey shim and the
direct install collapse into one entry instead of appearing twice, and
`<download available>` rows from `uv python list` are dropped rather than
offering to manage a Python that is not on the machine. env_hash
case-folds, so one environment cannot split its pins and snapshots in two.

plan_requirements is the SP-1 finding turned into code, and it is the
piece the product's core promise rests on: every resolve restates the
installed set as pinned requirements, minus whatever the user is moving.
Without it both engines upgrade straight past an installed package's
constraint and exit 0, so the preview would show a plan that breaks the
environment.

`list` reads from probe.py rather than `pip list`, because the probe
carries requires_dist and the engine listing does not, and prints the
user-site note when the listing is genuinely partial rather than as a
standing disclaimer.

I caused a real problem during this work and fixed it. The PEP 668
capture scenario planted an EXTERNALLY-MANAGED marker using the venv's
sysconfig stdlib path -- which for a venv resolves to the BASE
interpreter, not the venv. It landed in the user's actual Python 3.12
install and would have blocked pip there permanently. It surfaced because
`env list` showed a MANAGED chip on an environment that should not have
had one. The marker is removed, both interpreters verified clean, pip on
3.12 confirmed working, and the scenario that planted it is gone from the
harness. The lesson is in capture.py: a fixture script must not write
outside its temp directory, and sysconfig paths inside a venv are not
venv-local.

97 core tests, clippy -D warnings clean.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-27 19:26:40 +07:00
poli0981andClaude Opus 5 8f6b7ed24b feat: scaffold the Tauri shell, React UI and CI
Completes the Phase 0 scaffold. The app builds, links and renders; no
screens yet.

Frontend (ARCHITECTURE section 9, UI-SPEC section 2):
- React 19 + Vite 8 + Tailwind 4 with the UI-SPEC dark terminal-tech
  tokens, plus a contrast test asserting WCAG AA over every
  text/surface pair, which UI-SPEC section 8 requires be verified.
- EN and VI catalogs with a test that vi has every en key and no
  orphans, standing in for the CI parity script I18N section 1 asks for.
- A local eslint rule enforcing the no-hardcoded-JSX-strings policy.
  eslint-plugin-react was the obvious choice but caps at ESLint 9, which
  drags in six high-severity advisories that would fail npm audit in CI;
  a local rule also implements the documented allowlist (product name,
  package names, versions, catalog codes, glyphs) precisely, which
  react/jsx-no-literals cannot express. Verified it fires on real copy
  and stays quiet on all five allowed shapes.
- no-restricted-imports keeps invoke() out of components, so the
  "no component calls invoke directly" rule is enforced, not just stated.

Tauri (ARCHITECTURE section 7): commands and events only, identifier
com.skullmute.pipdock, NSIS and MSI targets, minimal capability set,
placeholder icon pending the Phase 3 branding pass.

CI (docs/RELEASE-CI.md section 1 as corrected):
- ci-rust.yml and release.yml are project-local, on Windows runners,
  because no reusable Rust or Tauri workflow exists in the ops repo.
  Windows matters here: env discovery reads the PEP 514 registry and the
  py launcher, so a Linux run would skip the code most likely to break.
- ci-node.yml calls the ops web-react reusable and adds the npm audit
  job that reusable lacks.
- codeql.yml is JS/TS only; CodeQL has no Rust analyzer.
- Discord notifiers replace the six-platform notify.yml that never
  existed. Every caller carries an explicit permissions block.
- Action versions checked against the registry rather than assumed:
  checkout v7, cache v6, gh-release v3, setup-node v6.

Two toolchain holds, both forced and both recorded:
- TypeScript 6.0.3, not 7: typescript-eslint peers on <6.1.0.
- ESLint 10 with eslint-plugin-react dropped, as above.

Verified: cargo fmt/clippy -D warnings/28 tests green, tsc clean,
18 vitest tests green, eslint clean, npm audit reports 0
vulnerabilities, vite build and both binaries link.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-27 17:44:39 +07:00
poli0981andClaude Opus 5 c4fe1c34e6 feat(core): scaffold the Cargo workspace, core crate and CLI surface
Phase 0 scaffold per ARCHITECTURE section 2. Everything compiles; nothing
resolves or mutates yet.

Implemented rather than stubbed, because the spikes need them and they are
the parts the invariants rest on:

- errors/catalog.rs: all 30 launch codes with their wire forms, plus tests
  that the wire codes are unique and match the PD-<AREA>-<NNN> grammar.
  Code::ALL drives the future "no code without fixture" gate.
- model.rs: PkgName::parse does PEP 508 validation and PEP 503
  normalization. This is the only way a name reaches an argv array, which
  makes SECURITY section 2 structural rather than aspirational; the test
  table rejects flags, separators and quoting attempts.
- probe.py: stdlib-only, Python 3.10 floor, per ARCHITECTURE section 4.
- The pip/uv argv builders, with tests asserting one token per argument.
- ExecutionSummary::tally, so the "13 successful, 2 failed" headline is
  derived from the rows rather than accumulated alongside them.

Stubbed with todo!() and a pointer to the milestone that fills them: the
Engine trait impls, discovery, index, graph, snapshot, pins, health.
UvEngine::parse_dry_run stays unimplemented on purpose — SP-1 must pin
uv's text plan format before anything parses it.

Two findings recorded in spikes/README.md:

- probe.py under -I hides user-site packages: 352 dists vs 376 without it
  and 375 from pip list, on a non-venv system Python. Venvs are unaffected.
  The fix trades a documented security control against list accuracy, so
  it is left as an open SP-6 decision rather than settled here.
- Python 3.14 deprecates subscripting absent metadata headers, which wrote
  DeprecationWarning to stderr on most distributions. probe.py now uses
  .get(); the probe must stay stderr-clean because noise reads as
  PD-ENV-003.

rusqlite is held at 0.37: 0.40 pulls libsqlite3-sys 0.38.1, whose build
script needs the unstable cfg_select! and will not build on stable 1.94.1.
Recorded in the ARCHITECTURE version manifest.

cargo fmt, clippy -D warnings and 23 tests are green.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-07-27 17:25:56 +07:00