From 97d47dbd1c63cb9f3e830bc80b707030af3f6c9a Mon Sep 17 00:00:00 2001 From: Scott Pouliot Date: Sat, 25 Apr 2026 21:13:39 -0400 Subject: [PATCH] Fix progress bar timing for sequential batch processing MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Was still estimating based on 3 concurrent waves (old model). Sequential mode runs ~18s per batch, so 500 items ≈ 6 minutes. Co-Authored-By: Claude Sonnet 4.6 --- src/PowderCoating.Web/wwwroot/js/catalog-price-check.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/PowderCoating.Web/wwwroot/js/catalog-price-check.js b/src/PowderCoating.Web/wwwroot/js/catalog-price-check.js index 0962b64..89e8e25 100644 --- a/src/PowderCoating.Web/wwwroot/js/catalog-price-check.js +++ b/src/PowderCoating.Web/wwwroot/js/catalog-price-check.js @@ -10,12 +10,11 @@ if (!form || !btn || !overlay) return; - // Estimate total seconds based on item count (roughly 12s per batch of 25, min 15s). + // Estimate total seconds based on item count. + // Batches run sequentially (1 at a time) at roughly 18s each. function estimateDuration(itemCount) { - // 25 items/batch, up to 3 concurrent — wall time ≈ ceil(batches/3) × 12s var batches = Math.max(1, Math.ceil(itemCount / 25)); - var waves = Math.ceil(batches / 3); - return Math.max(15, waves * 12); + return Math.max(30, batches * 18); } // Messages keyed to approximate progress milestones (0–100).