Skip to content

fix: add upm to package-count and process-count collectors - #180

Merged
darcyclarke merged 1 commit into
mainfrom
fix/upm-package-count
Sep 29, 2026
Merged

darcyclarke merged 1 commit into
mainfrom
fix/upm-package-count

Conversation

@vltbaudbot

@vltbaudbot vltbaudbot commented Sep 29, 2026 •

Copy link
Copy Markdown
Contributor

Problem

The upm package manager was added to benchmarks in #177 but its count file entries were missing from the collector scripts. This caused upm to appear inconsistently on benchmarks.vlt.sh:

  • ✅ Shows in the Total Install Time histogram (uses raw chartData)
  • ✅ Shows in the Tools dropdown
  • ❌ Missing from Leaderboard cards (uses perPackageCountChartData)
  • ❌ Missing from Per-Fixture horizontal bar charts (uses per-package data)

Root Cause

The data pipeline for per-package metrics works as follows:

  1. package-count.sh runs after each benchmark → correctly detects upm.lock and writes upm-count.txt ✅
  2. collect-package-count.js reads *-count.txt files into package-count.json → missing upm-count.txt entry ❌
  3. generate-chart.js uses package counts to compute per-package times → no count for upm → no per-package data
  4. App leaderboard and per-fixture views use per-package data → upm excluded

Same issue exists in collect-process-count.js for spawned process counts.

Fix

Add the missing entries:

  • { filename: 'upm-count.txt', pmName: 'upm' } to collect-package-count.js
  • { filename: 'upm-process-count.txt', pmName: 'upm' } to collect-process-count.js

The next benchmark run on main will produce correct per-package data for upm, and it will appear in all views.

Summary by CodeRabbit

  • New Features
    • Package and process count reporting now includes UPM data.

The upm package manager was added to benchmarks but its count file
entries were missing from collect-package-count.js and
collect-process-count.js. This caused:

- package-count.sh correctly writes upm-count.txt
- collect-package-count.js didn't read it → no package count data
- generate-chart.js couldn't compute per-package times for upm
- Leaderboard cards and per-fixture charts (which use per-package data)
  excluded upm, while the total-time histogram (which uses raw data)
  showed it correctly

Add the missing { filename: 'upm-count.txt', pmName: 'upm' } entry to
both collector scripts.
@coderabbitai

coderabbitai Bot commented Sep 29, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Advanced

Run ID: 59c89546-6ea6-4b64-ae9d-8d28aaeabeec

📥 Commits

Reviewing files that changed from the base of the PR and between b1a509a and b58bbc3.

📒 Files selected for processing (2)
  • scripts/collect-package-count.js
  • scripts/collect-process-count.js

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.


📝 Walkthrough

Walkthrough

The package-count and process-count collectors now include UPM count files in their existing collection flows. Both files map to the upm package-manager name.

Changes

UPM Count Collection

Layer / File(s) Summary
Add UPM count inputs
scripts/collect-package-count.js, scripts/collect-process-count.js
The collectors recognize upm-count.txt and upm-process-count.txt, respectively, and associate each with upm.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~5 minutes

Change: Bug fix

Merge Risk: ⚪ Minimal · up to b58bb

The change connects UPM count files to the existing collection flows, enabling their counts to appear in package and process results. No actionable merge risk remains from the reviewed changes.

Architecture Summary

Architecture risk: 🔵 Low · up to b58bb

The change affects 1 system.

Changed systems: scripts

Architecture concerns
No architecture-level concerns identified.

Review details

Systems and components

  • observed — scripts (service) was modified; 2 changed files map to changed impact.

Before / after behavior

  • observed — Modified behavior in scripts/collect-package-count.js: Added upm-count.txt as a count-file input associated with the upm package-manager name.
  • observed — Modified behavior in scripts/collect-process-count.js: Adds upm-process-count.txt as a process-count input associated with the upm package manager.
🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: adding upm support to both package-count and process-count collectors.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 2…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@darcyclarke
darcyclarke merged commit 017db9f into main Sep 29, 2026
57 checks passed
@darcyclarke
darcyclarke deleted the fix/upm-package-count branch September 29, 2026 03:09

This branch was previously deployed

1 inactive deployment
Benchmark — b58bbc33 Deployed Sep 29, 2026 by vltbaudbot via Run Benchmarks (svelte, registry-clean) #1312
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.

3 participants