@a11ign/screenreader-fleet 0.5.2 → 0.6.0

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 (49) hide show
  1. package/README.md +37 -0
  2. package/dist/{capture-client.d.mts → capture-client.d.ts} +2 -2
  3. package/dist/{check-worker-code.d.mts → check-worker-code.d.ts} +2 -3
  4. package/dist/check-worker-code.mjs +1 -1
  5. package/dist/{cli-flags.d.mts → cli-flags.d.ts} +5 -5
  6. package/dist/{code-drift.d.mts → code-drift.d.ts} +7 -7
  7. package/dist/{command-line-census.d.mts → command-line-census.d.ts} +3 -3
  8. package/dist/{compare-workers.d.mts → compare-workers.d.ts} +1 -1
  9. package/dist/{control-plane-isolation.d.mts → control-plane-isolation.d.ts} +1 -1
  10. package/dist/{doctor.d.mts → doctor.d.ts} +57 -31
  11. package/dist/doctor.mjs +4 -4
  12. package/dist/{fleet-consistency.d.mts → fleet-consistency.d.ts} +50 -85
  13. package/dist/fleet-consistency.mjs +4 -0
  14. package/dist/{fleet-env.d.mts → fleet-env.d.ts} +45 -45
  15. package/dist/{fleet-scripts.d.mts → fleet-scripts.d.ts} +1 -1
  16. package/dist/{git-safe-env.d.mts → git-safe-env.d.ts} +3 -3
  17. package/dist/{guest-run.d.mts → guest-run.d.ts} +5 -5
  18. package/dist/{host-address.d.mts → host-address.d.ts} +4 -4
  19. package/dist/{host-capacity.d.mts → host-capacity.d.ts} +5 -5
  20. package/dist/{host-metrics.d.mts → host-metrics.d.ts} +23 -15
  21. package/dist/index.mjs +1 -1
  22. package/dist/{measure-guard.d.mts → measure-guard.d.ts} +14 -14
  23. package/dist/{npm-cli-executable.d.mts → npm-cli-executable.d.ts} +4 -4
  24. package/dist/{probe-outcome.d.mts → probe-outcome.d.ts} +43 -44
  25. package/dist/{protocol-guard.d.mts → protocol-guard.d.ts} +3 -3
  26. package/dist/source-walk.d.ts +11 -0
  27. package/dist/{transient-fault.d.mts → transient-fault.d.ts} +1 -1
  28. package/dist/tsx-import.d.ts +6 -0
  29. package/dist/{utm-deprecated.d.mts → utm-deprecated.d.ts} +1 -1
  30. package/dist/worker-code-check.d.ts +95 -0
  31. package/dist/worker-code-check.mjs +1 -1
  32. package/dist/{worker-health.d.mts → worker-health.d.ts} +2 -2
  33. package/dist/{worker-http.d.mts → worker-http.d.ts} +51 -51
  34. package/dist/{worker-stats.d.mts → worker-stats.d.ts} +40 -20
  35. package/package.json +30 -19
  36. package/src/local-worker/build-vm.sh +2 -2
  37. package/src/local-worker/clone-worker.sh +1 -1
  38. package/src/local-worker/create-utm-vm.sh +1 -1
  39. package/src/local-worker/fetch-windows-iso.sh +5 -5
  40. package/src/local-worker/worker-ctl.sh +12 -12
  41. package/src/provisioning/apply-foreground-lock-timeout.ps1 +1 -1
  42. package/src/provisioning/bootstrap-windows-worker.ps1 +1 -1
  43. package/src/provisioning/diagnose-nvda-worker.ps1 +1 -1
  44. package/src/provisioning/stamp-provision-revision.ps1 +3 -3
  45. package/dist/source-walk.d.mts +0 -11
  46. package/dist/worker-code-check.d.mts +0 -54
  47. /package/dist/{normalise-fleet.d.mts → normalise-fleet.d.ts} +0 -0
  48. /package/dist/{src_fleet-scripts_mjs.mjs → src_fleet-scripts_ts.mjs} +0 -0
  49. /package/dist/{src_git-safe-env_mjs.mjs → src_git-safe-env_ts.mjs} +0 -0
@@ -1,54 +0,0 @@
1
- /**
2
- * The hash every worker is expected to be serving, and WHERE IT CAME FROM. ONE function, asked by `a11ign-worker-code` and by
3
- * `assertFleetRunsThisCheckout` alike, so the two cannot be given different hashers again (a11ign/a11ign#3781).
4
- *
5
- * With a layer clone present it is the CLONE's: the clone's own `code-version.mjs` over the clone's `src/`, which is what
6
- * `layerCodeVersion("nvda-worker")` computes for the deploy and the lab, and what a guest is told to be on (`--layer-ref`). Asking the
7
- * installed package instead made every worker read stale the first time a guest was deployed at a sha whose `.mjs` differed from the
8
- * release, with a remedy ("redeploy") that could not clear it.
9
- *
10
- * With none it is the installed package's (a11ign/a11ign#3740: the one the package was RELEASED with, `codeVersion()` and no
11
- * directory, because the built package's `workerSourceDir()` is `dist/` and holds none of the files a guest runs), and `source` and
12
- * `note` say so, so a reading is never silent about which it was.
13
- *
14
- * ASYNC because the clone's hasher can only be imported dynamically, as `layerCodeVersion` does.
15
- *
16
- * @param {{ checkoutRoot?: string }} [options]
17
- * @returns {Promise<{ code: string, source: "clone" | "installed", sourceDir: string, note: string }>}
18
- */
19
- export function resolveExpectedWorkerCode({ checkoutRoot }?: {
20
- checkoutRoot?: string;
21
- }): Promise<{
22
- code: string;
23
- source: "clone" | "installed";
24
- sourceDir: string;
25
- note: string;
26
- }>;
27
- /**
28
- * Refuse to capture with a fleet that is not running this checkout.
29
- *
30
- * Called at the boundary of every capture entry point, for the reason `assertWorkerUrl` is: the
31
- * alternative is discovering it in the evidence weeks later, where a stale worker looks like a page that
32
- * changed. **Both entry points, not one** — a remedy that reaches one of several paths is the shape this
33
- * repo has paid for three times over (`anchorToTop`, `ensureSpeechChannel`, `waitForAnnouncement`), and
34
- * `capture-preflight.test.ts` pins that both call it.
35
- *
36
- * A thin wrapper over `assertWorkersServe`, supplying the one thing only this file can compute: the hash.
37
- *
38
- * @param {string[]} workers
39
- * @param {{when?: string, allow?: boolean, read?: (url: string) => Promise<string|null>, bareMetalUrls?: string[], checkoutRoot?: string}} options
40
- */
41
- export function assertFleetRunsThisCheckout(workers: string[], options?: {
42
- when?: string;
43
- allow?: boolean;
44
- read?: (url: string) => Promise<string | null>;
45
- bareMetalUrls?: string[];
46
- checkoutRoot?: string;
47
- }): Promise<void>;
48
- import { codeDrift } from "./code-drift.mjs";
49
- import { describeCodeDrift } from "./code-drift.mjs";
50
- import { describeEmptyPool } from "./code-drift.mjs";
51
- import { readWorkerCode } from "./code-drift.mjs";
52
- import { remedyLines } from "./code-drift.mjs";
53
- import { workerSourceDirty } from "./code-drift.mjs";
54
- export { codeDrift, describeCodeDrift, describeEmptyPool, readWorkerCode, remedyLines, workerSourceDirty };