ccqa 1.42.0 → 1.42.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/bin/ccqa.mjs CHANGED
@@ -15704,7 +15704,7 @@ const CONFIG_NAMES = [
15704
15704
  "playwright.config.cjs"
15705
15705
  ];
15706
15706
  async function acquirePlaywrightBrowser(ctx) {
15707
- await sweepStaleWrappers(ctx.cwd);
15707
+ await sweepStaleWrappersOnce(ctx.cwd);
15708
15708
  const chromium = await resolveChromium(ctx.cwd);
15709
15709
  const port = await freePort();
15710
15710
  const server = await chromium.launchServer({ args: [`--remote-debugging-port=${port}`] });
@@ -15735,9 +15735,26 @@ async function acquirePlaywrightBrowser(ctx) {
15735
15735
  };
15736
15736
  }
15737
15737
  /**
15738
- * Wrappers a killed earlier run left behind. Deleted on the next acquire, not
15739
- * only guarded against: a stray one is git-status dirt in somebody's repo.
15738
+ * Wrappers a killed earlier run left behind. Deleted before this process
15739
+ * writes its first one, not only guarded against: a stray one is git-status
15740
+ * dirt in somebody's repo.
15741
+ *
15742
+ * Once per cwd per process, never per acquire: every live wrapper matches
15743
+ * the stale pattern, so under `--concurrency` a per-acquire sweep deletes
15744
+ * the wrapper a parallel spec just wrote and is about to hand to
15745
+ * `playwright test`, killing that spec before it starts. The memo makes
15746
+ * concurrent first acquires share one sweep that finished before either of
15747
+ * them wrote anything.
15740
15748
  */
15749
+ const sweptCwds = /* @__PURE__ */ new Map();
15750
+ function sweepStaleWrappersOnce(cwd) {
15751
+ let sweep = sweptCwds.get(cwd);
15752
+ if (!sweep) {
15753
+ sweep = sweepStaleWrappers(cwd);
15754
+ sweptCwds.set(cwd, sweep);
15755
+ }
15756
+ return sweep;
15757
+ }
15741
15758
  async function sweepStaleWrappers(cwd) {
15742
15759
  const entries = await readdir(cwd).catch(() => []);
15743
15760
  for (const name of entries) if (name.startsWith("ccqa-coverage.") && name.endsWith(".playwright.config.ts")) await unlink(join(cwd, name)).catch(() => void 0);
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ccqa",
3
- "version": "1.42.0",
3
+ "version": "1.42.1",
4
4
  "type": "module",
5
5
  "description": "Browser test recorder powered by Claude Code and agent-browser",
6
6
  "repository": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ccqa",
3
- "version": "1.42.0",
3
+ "version": "1.42.1",
4
4
  "type": "module",
5
5
  "description": "Browser test recorder powered by Claude Code and agent-browser",
6
6
  "repository": {