Skip to content

Improve artifact classification and separate VM and installer storage - #76

Merged
tzarebczan merged 14 commits into
tzarebczan:mainfrom
huntharo:fix/artifact-classification-evidence
Oct 17, 2026
Merged

tzarebczan merged 14 commits into
tzarebczan:mainfrom
huntharo:fix/artifact-classification-evidence

Conversation

@huntharo

Copy link
Copy Markdown
Contributor

Scala/sbt output was mislabeled Rust in mixed monorepos. This PR requires tool-specific evidence, expands disposable-cache coverage, and separates VM storage from installers.

Area Before After
Rust / JVM target could imply Rust Cargo output requires specific subtrees; Scala/sbt, Java/Maven and Gradle share Gradle / JVM
Other languages Broad names and whole tool homes could include configuration or executables Narrow cache/output layouts across Python, Go, .NET, Ruby, PHP, Dart, Swift, Elixir, Haskell and Zig
Saved scans Stale classifications remained visible Revalidate roots; show incomplete totals and offer a full scan
VM storage Mixed with generic files/cleanup candidates Dedicated VM filter; exclude VM contents from Easy Mode; explain snapshot/shared-space limits
Installers ISO handling differed between views Standalone ISO/DMG under Installers; VM-owned media stays with VMs
Overview Filtered extension totals appeared complete Category totals explicitly labeled as sampled; All retains scan-wide totals

Same-machine attribution — replay of 9.27 million files; GiB of recorded allocation, not guaranteed reclaimable space.

Category Original Expanded rules
Unclassified 470.787 451.711
Rust output 8.044 5.812
Gradle / JVM 2.981 5.912
Package caches 6.916 17.195
Compiler caches 0.046 5.601
Python 3.278 5.033
.NET 0.000 3.684

Full reconciliation and intentional exclusions. Later language coverage adds another 16.754 MiB of Bundler downloads. Source, Git history, configuration and ambiguous custom layouts remain excluded from disposable-cache attribution.

Screenshots — actual app, synthetic test files (4 KiB each).

Virtual machines, including VM-owned ISO Standalone ISO / DMG installers
Virtual machines Installers
Validation Result
TypeScript suite + typecheck 1,232 passed, 4 skipped; typecheck passed
Classifier regression coverage 350 shared cases × 10 path variants; 2,000 seeded adversarial paths per implementation
Native scanner suite 119 passed
Electron Seven targeted tests passed: artifact inventory, Git/worktree actions, VM and installer filters
Scaling N / 8N operation-count checks with absolute caps

Accepted layouts and limitations · VM / installer behavior

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 16, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-16T22:39:21.551590Z a335519 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a335519089

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/shared/suggestions.ts
): CleanupAnalysis {
// VM contents are inventory, not generic cache/media cleanup candidates.
files = files.filter((f) => !isVirtualMachineFile(f.path, f.extension));
directories = directories.filter((d) => !isVirtualMachineFile(d.path));

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Exclude VM directory roots from cleanup analysis

When a DirectoryHotspot is the VM root itself for a path-owned layout (for example /VirtualBox VMs/node_modules or ~/.tart/vms/DiagOutputDir), this predicate returns false because the Tart/VirtualBox/Minikube/Docker checks require a child segment after the VM name. The later cache and diagnostic passes can then offer the whole VM as regenerable or even safe cleanup based solely on its name, so this call needs directory-aware root matching before those hotspots are analyzed.

Useful? React with 👍 / 👎.

Comment thread src/renderer/lib/fileQuickFilters.ts Outdated
bucket.size += file.size;
bucket.count++;
}
return [...buckets.values()];

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Sort sampled extension buckets by aggregate size

When a category contains multiple extensions and the largest individual file is not from the extension with the largest aggregate (for example one 100 MB ISO followed by two 60 MB DMGs), this returns Map insertion order. Overview renders the array directly, whereas scan-wide topExtensions is size-sorted, so the filtered sidebar can place the 120 MB bucket below the 100 MB bucket and change ordering based on file input order; sort the completed buckets by total size before returning them.

Useful? React with 👍 / 👎.

Tart, VirtualBox, Minikube and Docker VM directories count as VMs themselves, so a folder named like a cache is not offered as one. Sampled extension buckets are ordered by total size.

@tzarebczan tzarebczan left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

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

Codex's two notes are fixed on 830ce32. A Tart, VirtualBox, Minikube, or Docker VM directory counts as a VM itself, so a folder named like a cache is not offered as cleanup. Sampled extension buckets are ordered by total size.

The overlap with #75 in contracts.ts and index.css merges cleanly: both sides stay. CI is green, including Windows E2E.

@tzarebczan
tzarebczan merged commit 8463f18 into tzarebczan:main Oct 17, 2026
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