@waitcher/cli 0.2.34 → 0.2.35
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/cli.mjs +933 -433
- package/dist/model-client.mjs +73 -3
- package/package.json +1 -1
package/dist/model-client.mjs
CHANGED
|
@@ -53190,15 +53190,17 @@ var visualThresholdSchema = external_exports.object({
|
|
|
53190
53190
|
maxDiffRatio: external_exports.number().min(0).max(0.1).default(1e-3),
|
|
53191
53191
|
includeAntialiasing: external_exports.boolean().default(false)
|
|
53192
53192
|
}).strict().prefault({});
|
|
53193
|
+
var VISUAL_CHECKPOINT_ID = /^[a-z][a-z0-9-]{0,39}$/;
|
|
53194
|
+
var VISUAL_CHECKPOINT_RULE = "Use up to 40 lower-case letters, digits or hyphens, starting with a letter";
|
|
53193
53195
|
var visualConfigSchema = external_exports.object({
|
|
53194
53196
|
schemaVersion: external_exports.literal(1).default(1),
|
|
53195
53197
|
checkpoint: external_exports.discriminatedUnion("kind", [
|
|
53196
53198
|
external_exports.object({
|
|
53197
|
-
id: external_exports.string().regex(
|
|
53199
|
+
id: external_exports.string().regex(VISUAL_CHECKPOINT_ID, VISUAL_CHECKPOINT_RULE).default("main"),
|
|
53198
53200
|
kind: external_exports.literal("page")
|
|
53199
53201
|
}).strict(),
|
|
53200
53202
|
external_exports.object({
|
|
53201
|
-
id: external_exports.string().regex(
|
|
53203
|
+
id: external_exports.string().regex(VISUAL_CHECKPOINT_ID, VISUAL_CHECKPOINT_RULE).default("main"),
|
|
53202
53204
|
kind: external_exports.literal("element"),
|
|
53203
53205
|
selector
|
|
53204
53206
|
}).strict()
|
|
@@ -55103,9 +55105,77 @@ var entries = {
|
|
|
55103
55105
|
RUNTIME_INSTALL_FAILED: {
|
|
55104
55106
|
title: "Runtime install failed",
|
|
55105
55107
|
meaning: "npm install or the Chromium download of waitcher runtime install exited with an error.",
|
|
55106
|
-
fix: "Read the npm or e2e-web output on stderr (network, registry or permissions), fix it and rerun waitcher runtime install --yes; it is safe to repeat.",
|
|
55108
|
+
fix: "Read the npm or e2e-web output on stderr (network, registry or permissions), fix it and rerun waitcher runtime install --yes; it is safe to repeat. npm 11 EALLOWSCRIPTS (--allow-scripts is not allowed in project-scoped installs): npm got allow-scripts from the command line or an npm_config_allow_scripts variable; unset it and approve with npm install-scripts approve esbuild or allow-scripts=esbuild in .npmrc.",
|
|
55107
55109
|
exitCode: 1
|
|
55108
55110
|
},
|
|
55111
|
+
FILE_EXISTS: {
|
|
55112
|
+
title: "File already exists",
|
|
55113
|
+
meaning: "init, export and other writers never overwrite a file.",
|
|
55114
|
+
fix: "Choose another --file path, or edit the existing file.",
|
|
55115
|
+
exitCode: 2
|
|
55116
|
+
},
|
|
55117
|
+
CONFIG_DIR_PERMISSIONS: {
|
|
55118
|
+
title: "Config directory is not private",
|
|
55119
|
+
meaning: "The folder that keeps sessions (~/.config/waitcher or WAITCHER_CONFIG_DIR), or a session file in it, is readable by other users or is a link, so the CLI neither reads nor saves a session there.",
|
|
55120
|
+
fix: "macOS and Linux: chmod 700 the folder (chmod 600 a session file), or point WAITCHER_CONFIG_DIR at a new private folder. Windows checks no mode bits; point WAITCHER_CONFIG_DIR at a regular folder that is not a link.",
|
|
55121
|
+
exitCode: 2
|
|
55122
|
+
},
|
|
55123
|
+
// Causes the test framework names when a script run stops (run local,
|
|
55124
|
+
// config validate --verify, hosted runs). The run exits 4.
|
|
55125
|
+
SECRET_UNAVAILABLE: {
|
|
55126
|
+
title: "A CHECK_* value is missing or too short",
|
|
55127
|
+
meaning: "The script reads a secret with secrets.get(NAME) that this run has no value for, or whose value is shorter than 6 characters (masking a shorter value would rewrite unrelated text, so it is not registered as a secret).",
|
|
55128
|
+
fix: "List the name in settings.envNames. run local: the user exports it in the shell. Hosted: waitcher secret set --env ENV --name NAME --value-stdin, or the Monitors page. For a value under 6 characters, read process.env.NAME in the script instead (unmasked in evidence).",
|
|
55129
|
+
exitCode: 4
|
|
55130
|
+
},
|
|
55131
|
+
APP_UNREACHABLE: {
|
|
55132
|
+
title: "Nothing answered at the target",
|
|
55133
|
+
meaning: "The browser could not reach the monitor's target (connection refused, DNS or TLS failure).",
|
|
55134
|
+
fix: "run local: start the app at the monitor's target, or change target to where it runs. Hosted: the target must answer from the public internet.",
|
|
55135
|
+
exitCode: 4
|
|
55136
|
+
},
|
|
55137
|
+
BROWSER_INSTALL_FAILED: {
|
|
55138
|
+
title: "Chromium could not be installed",
|
|
55139
|
+
meaning: "The run found no Chromium for its runtime and the download failed.",
|
|
55140
|
+
fix: "Run waitcher runtime install --browser --yes after the user agrees (on Linux add system libraries with npx e2e-web install chromium --with-deps), then rerun.",
|
|
55141
|
+
exitCode: 4
|
|
55142
|
+
},
|
|
55143
|
+
ENGINE_NOT_INSTALLED: {
|
|
55144
|
+
title: "Test runtime incomplete",
|
|
55145
|
+
meaning: "A package the script needs (@e2e-dev/web for browser checks) is not installed in the runtime folder.",
|
|
55146
|
+
fix: "Run waitcher runtime install (with --browser for browser checks) in the folder with package.json, then rerun.",
|
|
55147
|
+
exitCode: 4
|
|
55148
|
+
},
|
|
55149
|
+
COLLECTION_ERROR: {
|
|
55150
|
+
title: "Test file did not load",
|
|
55151
|
+
meaning: "The script failed to import or compile, so no test ran.",
|
|
55152
|
+
fix: "Fix the error in the message; scripts import test from @e2e-dev/web (browser) or e2e (API) and declare at least one test.",
|
|
55153
|
+
exitCode: 4
|
|
55154
|
+
},
|
|
55155
|
+
NO_TESTS: {
|
|
55156
|
+
title: "No test in the script",
|
|
55157
|
+
meaning: "The script declares no test(...), so the run has nothing to check.",
|
|
55158
|
+
fix: "Declare one test(...) in the script, then rerun.",
|
|
55159
|
+
exitCode: 4
|
|
55160
|
+
},
|
|
55161
|
+
TEST_SETUP_FAILED: {
|
|
55162
|
+
title: "Test setup failed",
|
|
55163
|
+
meaning: "A fixture or beforeAll/beforeEach step failed before the test body ran.",
|
|
55164
|
+
fix: "Read the message and the trace (run diagnose), fix the setup step, then rerun.",
|
|
55165
|
+
exitCode: 4
|
|
55166
|
+
},
|
|
55167
|
+
LAUNCH_TIMEOUT: {
|
|
55168
|
+
title: "Browser did not start in time",
|
|
55169
|
+
meaning: "Chromium did not launch within the framework's limit, usually on an overloaded machine or with missing system libraries.",
|
|
55170
|
+
fix: "Rerun; on Linux install system libraries with npx e2e-web install chromium --with-deps.",
|
|
55171
|
+
exitCode: 4
|
|
55172
|
+
},
|
|
55173
|
+
MODEL_UNAVAILABLE: {
|
|
55174
|
+
title: "AI step without a model",
|
|
55175
|
+
meaning: "The script uses an AI step but the run has no model connection.",
|
|
55176
|
+
fix: "run local: pass --connections-file with the monitor's AI connection. Hosted: bind an AI connection, or remove the AI step.",
|
|
55177
|
+
exitCode: 4
|
|
55178
|
+
},
|
|
55109
55179
|
FILE_NOT_FOUND: {
|
|
55110
55180
|
title: "File not found",
|
|
55111
55181
|
meaning: "A referenced local file does not exist.",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@waitcher/cli",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.35",
|
|
4
4
|
"description": "Synthetic monitoring from your repository: deploy HTTP, certificate, TCP, DNS, heartbeat, API, browser, visual, MCP server and coding agent checks from waitcher.json, with AI checks and status pages.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
6
6
|
"author": "Sławomir Radzymiński",
|