@testver/testver 0.2.2 → 0.2.3

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.
Files changed (2) hide show
  1. package/dist/index.js +35 -3
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -45085,7 +45085,27 @@ async function createFileWatcher(projectPath2, wss, scanner) {
45085
45085
  ".turbo",
45086
45086
  ".cache",
45087
45087
  ".vscode",
45088
- ".idea"
45088
+ ".idea",
45089
+ // Test-ARTIFACT output dirs. A real automation project accumulates
45090
+ // thousands of generated screenshots/videos/reports here; watching them is
45091
+ // pointless (they're outputs, not source) and opens a file handle each,
45092
+ // which exhausts the OS open-file limit (EMFILE) — exactly the macOS crash
45093
+ // users hit on large projects. These are still served via the artifact API;
45094
+ // only the live-reload watcher skips them.
45095
+ "screenshots",
45096
+ "reports",
45097
+ "test-results",
45098
+ "playwright-report",
45099
+ "allure-results",
45100
+ "allure-report",
45101
+ "videos",
45102
+ "video",
45103
+ "traces",
45104
+ "har",
45105
+ "logs",
45106
+ "test-output",
45107
+ "reports-html",
45108
+ "monocart-report"
45089
45109
  ]);
45090
45110
  const ignored = (p) => {
45091
45111
  const rel = relative6(projectPath2, p);
@@ -45098,9 +45118,21 @@ async function createFileWatcher(projectPath2, wss, scanner) {
45098
45118
  ignoreInitial: true,
45099
45119
  awaitWriteFinish: { stabilityThreshold: 300, pollInterval: 100 }
45100
45120
  });
45121
+ let watchLimitHit = false;
45101
45122
  watcher.on("error", (err4) => {
45102
- const msg = err4?.message || String(err4);
45103
- console.warn(`[testver] file watcher error (non-fatal, continuing): ${msg}`);
45123
+ const e = err4;
45124
+ if ((e?.code === "EMFILE" || e?.code === "ENFILE" || e?.code === "ENOSPC") && !watchLimitHit) {
45125
+ watchLimitHit = true;
45126
+ console.warn(
45127
+ `[testver] Live file-watching disabled \u2014 the OS open-file limit was reached (${e.code}). The dashboard works normally; only auto-refresh-on-file-change is off. To re-enable it, raise the limit before launching (e.g. "ulimit -n 10240" then "testver serve") or run from a directory with fewer generated files.`
45128
+ );
45129
+ watcher.close().catch(() => {
45130
+ });
45131
+ return;
45132
+ }
45133
+ if (!watchLimitHit) {
45134
+ console.warn(`[testver] file watcher error (non-fatal, continuing): ${e?.message || err4}`);
45135
+ }
45104
45136
  });
45105
45137
  let rescanTimer = null;
45106
45138
  const scheduleRescan = () => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@testver/testver",
3
- "version": "0.2.2",
3
+ "version": "0.2.3",
4
4
  "description": "AI-powered interactive CLI for test automation",
5
5
  "type": "module",
6
6
  "publishConfig": {