Skip to content

Conversation

@leodido
Copy link
Contributor

@leodido leodido commented Nov 13, 2025

Summary

Fixes an accounting bug in the build summary where total would not match the sum of categorized packages.

Problem

In printBuildSummary, the total counter was incremented for all packages in allpkg, but packages not in cache were skipped with continue. This caused:

total != (builtLocally + downloaded + alreadyCached)

Fix

Move total++ to after the cache check, so we only count packages that are actually in the cache and being categorized.

Impact

Related

Follow-up to #273 which was just merged.

Move total++ after cache check to ensure count matches categorized packages.
Previously, total would include packages not in cache that were skipped,
causing total != (builtLocally + downloaded + alreadyCached).

Co-authored-by: Ona <no-reply@ona.com>
@leodido leodido requested a review from kylos101 November 13, 2025 19:26
@leodido leodido self-assigned this Nov 13, 2025
@leodido leodido force-pushed the fix/build-summary-total-count branch from 93a188a to 150b8b9 Compare November 13, 2025 19:26
The parameter name 'initialStatus' was misleading as it represents the
package status after downloads complete but before local builds start,
not the initial status before any operations.

Renamed to 'statusAfterDownload' for clarity.

Co-authored-by: Ona <no-reply@ona.com>
@leodido leodido merged commit 1c0aff9 into main Nov 13, 2025
11 of 12 checks passed
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