@descryy/mcp 0.11.3 → 0.11.5
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/package.json +20 -20
- package/dist/action-handshake.d.ts +0 -38
- package/dist/action-handshake.d.ts.map +0 -1
- package/dist/action-handshake.js +0 -127
- package/dist/action-handshake.js.map +0 -1
- package/dist/bin/descry-mcp.d.ts +0 -7
- package/dist/bin/descry-mcp.d.ts.map +0 -1
- package/dist/bin/descry-mcp.js +0 -72
- package/dist/bin/descry-mcp.js.map +0 -1
- package/dist/browser/auth.d.ts +0 -84
- package/dist/browser/auth.d.ts.map +0 -1
- package/dist/browser/auth.js +0 -233
- package/dist/browser/auth.js.map +0 -1
- package/dist/browser/capability-probe.d.ts +0 -109
- package/dist/browser/capability-probe.d.ts.map +0 -1
- package/dist/browser/capability-probe.js +0 -201
- package/dist/browser/capability-probe.js.map +0 -1
- package/dist/browser/driver.d.ts +0 -570
- package/dist/browser/driver.d.ts.map +0 -1
- package/dist/browser/driver.js +0 -116
- package/dist/browser/driver.js.map +0 -1
- package/dist/browser/evidence.d.ts +0 -28
- package/dist/browser/evidence.d.ts.map +0 -1
- package/dist/browser/evidence.js +0 -82
- package/dist/browser/evidence.js.map +0 -1
- package/dist/browser/fake-driver.d.ts +0 -116
- package/dist/browser/fake-driver.d.ts.map +0 -1
- package/dist/browser/fake-driver.js +0 -416
- package/dist/browser/fake-driver.js.map +0 -1
- package/dist/browser/fault-attribution.d.ts +0 -178
- package/dist/browser/fault-attribution.d.ts.map +0 -1
- package/dist/browser/fault-attribution.js +0 -266
- package/dist/browser/fault-attribution.js.map +0 -1
- package/dist/browser/graph-write.d.ts +0 -45
- package/dist/browser/graph-write.d.ts.map +0 -1
- package/dist/browser/graph-write.js +0 -103
- package/dist/browser/graph-write.js.map +0 -1
- package/dist/browser/identity-graph-write.d.ts +0 -55
- package/dist/browser/identity-graph-write.d.ts.map +0 -1
- package/dist/browser/identity-graph-write.js +0 -45
- package/dist/browser/identity-graph-write.js.map +0 -1
- package/dist/browser/page-probe.d.ts +0 -81
- package/dist/browser/page-probe.d.ts.map +0 -1
- package/dist/browser/page-probe.js +0 -202
- package/dist/browser/page-probe.js.map +0 -1
- package/dist/browser/playwright-driver.d.ts +0 -114
- package/dist/browser/playwright-driver.d.ts.map +0 -1
- package/dist/browser/playwright-driver.js +0 -1479
- package/dist/browser/playwright-driver.js.map +0 -1
- package/dist/browser/provider.d.ts +0 -26
- package/dist/browser/provider.d.ts.map +0 -1
- package/dist/browser/provider.js +0 -14
- package/dist/browser/provider.js.map +0 -1
- package/dist/browser/reach-recording-session.d.ts +0 -44
- package/dist/browser/reach-recording-session.d.ts.map +0 -1
- package/dist/browser/reach-recording-session.js +0 -143
- package/dist/browser/reach-recording-session.js.map +0 -1
- package/dist/browser/reachability.d.ts +0 -168
- package/dist/browser/reachability.d.ts.map +0 -1
- package/dist/browser/reachability.js +0 -294
- package/dist/browser/reachability.js.map +0 -1
- package/dist/browser/registry.d.ts +0 -126
- package/dist/browser/registry.d.ts.map +0 -1
- package/dist/browser/registry.js +0 -177
- package/dist/browser/registry.js.map +0 -1
- package/dist/browser/scenario-provenance.d.ts +0 -23
- package/dist/browser/scenario-provenance.d.ts.map +0 -1
- package/dist/browser/scenario-provenance.js +0 -73
- package/dist/browser/scenario-provenance.js.map +0 -1
- package/dist/browser/scenario-resolve.d.ts +0 -28
- package/dist/browser/scenario-resolve.d.ts.map +0 -1
- package/dist/browser/scenario-resolve.js +0 -96
- package/dist/browser/scenario-resolve.js.map +0 -1
- package/dist/browser/scenario-runner.d.ts +0 -72
- package/dist/browser/scenario-runner.d.ts.map +0 -1
- package/dist/browser/scenario-runner.js +0 -353
- package/dist/browser/scenario-runner.js.map +0 -1
- package/dist/browser/stack-parser.d.ts +0 -19
- package/dist/browser/stack-parser.d.ts.map +0 -1
- package/dist/browser/stack-parser.js +0 -85
- package/dist/browser/stack-parser.js.map +0 -1
- package/dist/browser/tool-support.d.ts +0 -71
- package/dist/browser/tool-support.d.ts.map +0 -1
- package/dist/browser/tool-support.js +0 -216
- package/dist/browser/tool-support.js.map +0 -1
- package/dist/browser/url-scheme.d.ts +0 -14
- package/dist/browser/url-scheme.d.ts.map +0 -1
- package/dist/browser/url-scheme.js +0 -38
- package/dist/browser/url-scheme.js.map +0 -1
- package/dist/browser/wait-target.d.ts +0 -37
- package/dist/browser/wait-target.d.ts.map +0 -1
- package/dist/browser/wait-target.js +0 -54
- package/dist/browser/wait-target.js.map +0 -1
- package/dist/cancellation.d.ts +0 -20
- package/dist/cancellation.d.ts.map +0 -1
- package/dist/cancellation.js +0 -41
- package/dist/cancellation.js.map +0 -1
- package/dist/capped.d.ts +0 -17
- package/dist/capped.d.ts.map +0 -1
- package/dist/capped.js +0 -15
- package/dist/capped.js.map +0 -1
- package/dist/credential-store.d.ts +0 -22
- package/dist/credential-store.d.ts.map +0 -1
- package/dist/credential-store.js +0 -33
- package/dist/credential-store.js.map +0 -1
- package/dist/disclosure-ledger.d.ts +0 -14
- package/dist/disclosure-ledger.d.ts.map +0 -1
- package/dist/disclosure-ledger.js +0 -18
- package/dist/disclosure-ledger.js.map +0 -1
- package/dist/evidence/observed-route-evidence.d.ts +0 -25
- package/dist/evidence/observed-route-evidence.d.ts.map +0 -1
- package/dist/evidence/observed-route-evidence.js +0 -76
- package/dist/evidence/observed-route-evidence.js.map +0 -1
- package/dist/heap.d.ts +0 -61
- package/dist/heap.d.ts.map +0 -1
- package/dist/heap.js +0 -82
- package/dist/heap.js.map +0 -1
- package/dist/heartbeat.d.ts +0 -46
- package/dist/heartbeat.d.ts.map +0 -1
- package/dist/heartbeat.js +0 -66
- package/dist/heartbeat.js.map +0 -1
- package/dist/index.d.ts +0 -32
- package/dist/index.d.ts.map +0 -1
- package/dist/index.js +0 -19
- package/dist/index.js.map +0 -1
- package/dist/module-trust.d.ts +0 -37
- package/dist/module-trust.d.ts.map +0 -1
- package/dist/module-trust.js +0 -77
- package/dist/module-trust.js.map +0 -1
- package/dist/path-confinement.d.ts +0 -31
- package/dist/path-confinement.d.ts.map +0 -1
- package/dist/path-confinement.js +0 -44
- package/dist/path-confinement.js.map +0 -1
- package/dist/planner/predict-then-propose.d.ts +0 -134
- package/dist/planner/predict-then-propose.d.ts.map +0 -1
- package/dist/planner/predict-then-propose.js +0 -138
- package/dist/planner/predict-then-propose.js.map +0 -1
- package/dist/planner/propose-journey.d.ts +0 -75
- package/dist/planner/propose-journey.d.ts.map +0 -1
- package/dist/planner/propose-journey.js +0 -96
- package/dist/planner/propose-journey.js.map +0 -1
- package/dist/protocol.d.ts +0 -57
- package/dist/protocol.d.ts.map +0 -1
- package/dist/protocol.js +0 -90
- package/dist/protocol.js.map +0 -1
- package/dist/registry.d.ts +0 -103
- package/dist/registry.d.ts.map +0 -1
- package/dist/registry.js +0 -319
- package/dist/registry.js.map +0 -1
- package/dist/render.d.ts +0 -580
- package/dist/render.d.ts.map +0 -1
- package/dist/render.js +0 -867
- package/dist/render.js.map +0 -1
- package/dist/runtime-registry.d.ts +0 -22
- package/dist/runtime-registry.d.ts.map +0 -1
- package/dist/runtime-registry.js +0 -142
- package/dist/runtime-registry.js.map +0 -1
- package/dist/sandbox-defaults.d.ts +0 -41
- package/dist/sandbox-defaults.d.ts.map +0 -1
- package/dist/sandbox-defaults.js +0 -14
- package/dist/sandbox-defaults.js.map +0 -1
- package/dist/scenarios/browser-run-plan-projection.d.ts +0 -161
- package/dist/scenarios/browser-run-plan-projection.d.ts.map +0 -1
- package/dist/scenarios/browser-run-plan-projection.js +0 -264
- package/dist/scenarios/browser-run-plan-projection.js.map +0 -1
- package/dist/scenarios/credential-ref.d.ts +0 -102
- package/dist/scenarios/credential-ref.d.ts.map +0 -1
- package/dist/scenarios/credential-ref.js +0 -148
- package/dist/scenarios/credential-ref.js.map +0 -1
- package/dist/scenarios/index.d.ts +0 -7
- package/dist/scenarios/index.d.ts.map +0 -1
- package/dist/scenarios/index.js +0 -7
- package/dist/scenarios/index.js.map +0 -1
- package/dist/scenarios/parse.d.ts +0 -18
- package/dist/scenarios/parse.d.ts.map +0 -1
- package/dist/scenarios/parse.js +0 -212
- package/dist/scenarios/parse.js.map +0 -1
- package/dist/scenarios/scenario.d.ts +0 -93
- package/dist/scenarios/scenario.d.ts.map +0 -1
- package/dist/scenarios/scenario.js +0 -27
- package/dist/scenarios/scenario.js.map +0 -1
- package/dist/scenarios/secret-ref.d.ts +0 -86
- package/dist/scenarios/secret-ref.d.ts.map +0 -1
- package/dist/scenarios/secret-ref.js +0 -125
- package/dist/scenarios/secret-ref.js.map +0 -1
- package/dist/scenarios/storage.d.ts +0 -21
- package/dist/scenarios/storage.d.ts.map +0 -1
- package/dist/scenarios/storage.js +0 -103
- package/dist/scenarios/storage.js.map +0 -1
- package/dist/server.d.ts +0 -61
- package/dist/server.d.ts.map +0 -1
- package/dist/server.js +0 -541
- package/dist/server.js.map +0 -1
- package/dist/session.d.ts +0 -243
- package/dist/session.d.ts.map +0 -1
- package/dist/session.js +0 -602
- package/dist/session.js.map +0 -1
- package/dist/tools/alias-kit.d.ts +0 -29
- package/dist/tools/alias-kit.d.ts.map +0 -1
- package/dist/tools/alias-kit.js +0 -21
- package/dist/tools/alias-kit.js.map +0 -1
- package/dist/tools/aliases.d.ts +0 -42
- package/dist/tools/aliases.d.ts.map +0 -1
- package/dist/tools/aliases.js +0 -52
- package/dist/tools/aliases.js.map +0 -1
- package/dist/tools/analyze-workspace.d.ts +0 -52
- package/dist/tools/analyze-workspace.d.ts.map +0 -1
- package/dist/tools/analyze-workspace.js +0 -207
- package/dist/tools/analyze-workspace.js.map +0 -1
- package/dist/tools/analyze.d.ts +0 -163
- package/dist/tools/analyze.d.ts.map +0 -1
- package/dist/tools/analyze.js +0 -724
- package/dist/tools/analyze.js.map +0 -1
- package/dist/tools/browser-click.d.ts +0 -18
- package/dist/tools/browser-click.d.ts.map +0 -1
- package/dist/tools/browser-click.js +0 -110
- package/dist/tools/browser-click.js.map +0 -1
- package/dist/tools/browser-close-session.d.ts +0 -39
- package/dist/tools/browser-close-session.d.ts.map +0 -1
- package/dist/tools/browser-close-session.js +0 -120
- package/dist/tools/browser-close-session.js.map +0 -1
- package/dist/tools/browser-fill.d.ts +0 -18
- package/dist/tools/browser-fill.d.ts.map +0 -1
- package/dist/tools/browser-fill.js +0 -117
- package/dist/tools/browser-fill.js.map +0 -1
- package/dist/tools/browser-navigate.d.ts +0 -15
- package/dist/tools/browser-navigate.d.ts.map +0 -1
- package/dist/tools/browser-navigate.js +0 -104
- package/dist/tools/browser-navigate.js.map +0 -1
- package/dist/tools/browser-read.d.ts +0 -33
- package/dist/tools/browser-read.d.ts.map +0 -1
- package/dist/tools/browser-read.js +0 -113
- package/dist/tools/browser-read.js.map +0 -1
- package/dist/tools/browser-run-scenario.d.ts +0 -28
- package/dist/tools/browser-run-scenario.d.ts.map +0 -1
- package/dist/tools/browser-run-scenario.js +0 -206
- package/dist/tools/browser-run-scenario.js.map +0 -1
- package/dist/tools/browser-save-scenario.d.ts +0 -19
- package/dist/tools/browser-save-scenario.d.ts.map +0 -1
- package/dist/tools/browser-save-scenario.js +0 -447
- package/dist/tools/browser-save-scenario.js.map +0 -1
- package/dist/tools/browser-select.d.ts +0 -20
- package/dist/tools/browser-select.d.ts.map +0 -1
- package/dist/tools/browser-select.js +0 -120
- package/dist/tools/browser-select.js.map +0 -1
- package/dist/tools/browser-snapshot.d.ts +0 -46
- package/dist/tools/browser-snapshot.d.ts.map +0 -1
- package/dist/tools/browser-snapshot.js +0 -127
- package/dist/tools/browser-snapshot.js.map +0 -1
- package/dist/tools/browser-start-session.d.ts +0 -24
- package/dist/tools/browser-start-session.d.ts.map +0 -1
- package/dist/tools/browser-start-session.js +0 -622
- package/dist/tools/browser-start-session.js.map +0 -1
- package/dist/tools/browser-submit.d.ts +0 -18
- package/dist/tools/browser-submit.d.ts.map +0 -1
- package/dist/tools/browser-submit.js +0 -106
- package/dist/tools/browser-submit.js.map +0 -1
- package/dist/tools/browser-type.d.ts +0 -18
- package/dist/tools/browser-type.d.ts.map +0 -1
- package/dist/tools/browser-type.js +0 -115
- package/dist/tools/browser-type.js.map +0 -1
- package/dist/tools/browser-wait-for.d.ts +0 -45
- package/dist/tools/browser-wait-for.d.ts.map +0 -1
- package/dist/tools/browser-wait-for.js +0 -150
- package/dist/tools/browser-wait-for.js.map +0 -1
- package/dist/tools/browser.d.ts +0 -69
- package/dist/tools/browser.d.ts.map +0 -1
- package/dist/tools/browser.js +0 -386
- package/dist/tools/browser.js.map +0 -1
- package/dist/tools/chain.d.ts +0 -41
- package/dist/tools/chain.d.ts.map +0 -1
- package/dist/tools/chain.js +0 -105
- package/dist/tools/chain.js.map +0 -1
- package/dist/tools/change-scope.d.ts +0 -25
- package/dist/tools/change-scope.d.ts.map +0 -1
- package/dist/tools/change-scope.js +0 -110
- package/dist/tools/change-scope.js.map +0 -1
- package/dist/tools/code-context.d.ts +0 -83
- package/dist/tools/code-context.d.ts.map +0 -1
- package/dist/tools/code-context.js +0 -416
- package/dist/tools/code-context.js.map +0 -1
- package/dist/tools/contracts.d.ts +0 -74
- package/dist/tools/contracts.d.ts.map +0 -1
- package/dist/tools/contracts.js +0 -196
- package/dist/tools/contracts.js.map +0 -1
- package/dist/tools/cross-pr.d.ts +0 -178
- package/dist/tools/cross-pr.d.ts.map +0 -1
- package/dist/tools/cross-pr.js +0 -321
- package/dist/tools/cross-pr.js.map +0 -1
- package/dist/tools/disclosure.d.ts +0 -75
- package/dist/tools/disclosure.d.ts.map +0 -1
- package/dist/tools/disclosure.js +0 -288
- package/dist/tools/disclosure.js.map +0 -1
- package/dist/tools/draw-conclusion.d.ts +0 -55
- package/dist/tools/draw-conclusion.d.ts.map +0 -1
- package/dist/tools/draw-conclusion.js +0 -259
- package/dist/tools/draw-conclusion.js.map +0 -1
- package/dist/tools/git-context.d.ts +0 -39
- package/dist/tools/git-context.d.ts.map +0 -1
- package/dist/tools/git-context.js +0 -364
- package/dist/tools/git-context.js.map +0 -1
- package/dist/tools/git-diff.d.ts +0 -45
- package/dist/tools/git-diff.d.ts.map +0 -1
- package/dist/tools/git-diff.js +0 -338
- package/dist/tools/git-diff.js.map +0 -1
- package/dist/tools/git-history.d.ts +0 -16
- package/dist/tools/git-history.d.ts.map +0 -1
- package/dist/tools/git-history.js +0 -86
- package/dist/tools/git-history.js.map +0 -1
- package/dist/tools/history.d.ts +0 -34
- package/dist/tools/history.d.ts.map +0 -1
- package/dist/tools/history.js +0 -121
- package/dist/tools/history.js.map +0 -1
- package/dist/tools/impact.d.ts +0 -46
- package/dist/tools/impact.d.ts.map +0 -1
- package/dist/tools/impact.js +0 -225
- package/dist/tools/impact.js.map +0 -1
- package/dist/tools/index.d.ts +0 -59
- package/dist/tools/index.d.ts.map +0 -1
- package/dist/tools/index.js +0 -70
- package/dist/tools/index.js.map +0 -1
- package/dist/tools/kit.d.ts +0 -165
- package/dist/tools/kit.d.ts.map +0 -1
- package/dist/tools/kit.js +0 -153
- package/dist/tools/kit.js.map +0 -1
- package/dist/tools/link-workspace.d.ts +0 -24
- package/dist/tools/link-workspace.d.ts.map +0 -1
- package/dist/tools/link-workspace.js +0 -131
- package/dist/tools/link-workspace.js.map +0 -1
- package/dist/tools/lookup.d.ts +0 -19
- package/dist/tools/lookup.d.ts.map +0 -1
- package/dist/tools/lookup.js +0 -63
- package/dist/tools/lookup.js.map +0 -1
- package/dist/tools/mark-incident.d.ts +0 -28
- package/dist/tools/mark-incident.d.ts.map +0 -1
- package/dist/tools/mark-incident.js +0 -188
- package/dist/tools/mark-incident.js.map +0 -1
- package/dist/tools/merged-browser.d.ts +0 -11
- package/dist/tools/merged-browser.d.ts.map +0 -1
- package/dist/tools/merged-browser.js +0 -20
- package/dist/tools/merged-browser.js.map +0 -1
- package/dist/tools/merged-context.d.ts +0 -11
- package/dist/tools/merged-context.d.ts.map +0 -1
- package/dist/tools/merged-context.js +0 -21
- package/dist/tools/merged-context.js.map +0 -1
- package/dist/tools/merged-observe.d.ts +0 -13
- package/dist/tools/merged-observe.d.ts.map +0 -1
- package/dist/tools/merged-observe.js +0 -21
- package/dist/tools/merged-observe.js.map +0 -1
- package/dist/tools/merged-workspace.d.ts +0 -14
- package/dist/tools/merged-workspace.d.ts.map +0 -1
- package/dist/tools/merged-workspace.js +0 -21
- package/dist/tools/merged-workspace.js.map +0 -1
- package/dist/tools/observe-runtime.d.ts +0 -250
- package/dist/tools/observe-runtime.d.ts.map +0 -1
- package/dist/tools/observe-runtime.js +0 -1753
- package/dist/tools/observe-runtime.js.map +0 -1
- package/dist/tools/observe-tests.d.ts +0 -57
- package/dist/tools/observe-tests.d.ts.map +0 -1
- package/dist/tools/observe-tests.js +0 -368
- package/dist/tools/observe-tests.js.map +0 -1
- package/dist/tools/observe.d.ts +0 -28
- package/dist/tools/observe.d.ts.map +0 -1
- package/dist/tools/observe.js +0 -330
- package/dist/tools/observe.js.map +0 -1
- package/dist/tools/pr-analysis.d.ts +0 -189
- package/dist/tools/pr-analysis.d.ts.map +0 -1
- package/dist/tools/pr-analysis.js +0 -299
- package/dist/tools/pr-analysis.js.map +0 -1
- package/dist/tools/pre-push.d.ts +0 -168
- package/dist/tools/pre-push.d.ts.map +0 -1
- package/dist/tools/pre-push.js +0 -416
- package/dist/tools/pre-push.js.map +0 -1
- package/dist/tools/predict-reach.d.ts +0 -57
- package/dist/tools/predict-reach.d.ts.map +0 -1
- package/dist/tools/predict-reach.js +0 -159
- package/dist/tools/predict-reach.js.map +0 -1
- package/dist/tools/propagation.d.ts +0 -37
- package/dist/tools/propagation.d.ts.map +0 -1
- package/dist/tools/propagation.js +0 -162
- package/dist/tools/propagation.js.map +0 -1
- package/dist/tools/propose-journey.d.ts +0 -16
- package/dist/tools/propose-journey.d.ts.map +0 -1
- package/dist/tools/propose-journey.js +0 -121
- package/dist/tools/propose-journey.js.map +0 -1
- package/dist/tools/prove-reach.d.ts +0 -74
- package/dist/tools/prove-reach.d.ts.map +0 -1
- package/dist/tools/prove-reach.js +0 -286
- package/dist/tools/prove-reach.js.map +0 -1
- package/dist/tools/questions.d.ts +0 -30
- package/dist/tools/questions.d.ts.map +0 -1
- package/dist/tools/questions.js +0 -232
- package/dist/tools/questions.js.map +0 -1
- package/dist/tools/refusal-fetch.d.ts +0 -35
- package/dist/tools/refusal-fetch.d.ts.map +0 -1
- package/dist/tools/refusal-fetch.js +0 -103
- package/dist/tools/refusal-fetch.js.map +0 -1
- package/dist/tools/runtime-incident.d.ts +0 -33
- package/dist/tools/runtime-incident.d.ts.map +0 -1
- package/dist/tools/runtime-incident.js +0 -67
- package/dist/tools/runtime-incident.js.map +0 -1
- package/dist/tools/runtime-journey-drive.d.ts +0 -102
- package/dist/tools/runtime-journey-drive.d.ts.map +0 -1
- package/dist/tools/runtime-journey-drive.js +0 -247
- package/dist/tools/runtime-journey-drive.js.map +0 -1
- package/dist/tools/scope.d.ts +0 -45
- package/dist/tools/scope.d.ts.map +0 -1
- package/dist/tools/scope.js +0 -186
- package/dist/tools/scope.js.map +0 -1
- package/dist/tools/similar-incidents.d.ts +0 -43
- package/dist/tools/similar-incidents.d.ts.map +0 -1
- package/dist/tools/similar-incidents.js +0 -179
- package/dist/tools/similar-incidents.js.map +0 -1
- package/dist/tools/validate.d.ts +0 -133
- package/dist/tools/validate.d.ts.map +0 -1
- package/dist/tools/validate.js +0 -442
- package/dist/tools/validate.js.map +0 -1
- package/dist/tools/verb.d.ts +0 -46
- package/dist/tools/verb.d.ts.map +0 -1
- package/dist/tools/verb.js +0 -78
- package/dist/tools/verb.js.map +0 -1
- package/dist/tools/verification-status.d.ts +0 -38
- package/dist/tools/verification-status.d.ts.map +0 -1
- package/dist/tools/verification-status.js +0 -203
- package/dist/tools/verification-status.js.map +0 -1
- package/dist/tools/verify-claim.d.ts +0 -29
- package/dist/tools/verify-claim.d.ts.map +0 -1
- package/dist/tools/verify-claim.js +0 -220
- package/dist/tools/verify-claim.js.map +0 -1
- package/dist/tools/workspace.d.ts +0 -28
- package/dist/tools/workspace.d.ts.map +0 -1
- package/dist/tools/workspace.js +0 -101
- package/dist/tools/workspace.js.map +0 -1
- package/dist/transport.d.ts +0 -32
- package/dist/transport.d.ts.map +0 -1
- package/dist/transport.js +0 -85
- package/dist/transport.js.map +0 -1
- package/dist/workspace-index.d.ts +0 -164
- package/dist/workspace-index.d.ts.map +0 -1
- package/dist/workspace-index.js +0 -381
- package/dist/workspace-index.js.map +0 -1
package/dist/tools/validate.js
DELETED
|
@@ -1,442 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* `validate` — §15 static validation: env/config checks.
|
|
3
|
-
* Omits a var unless its read fails-on-absence AND declaration surface is complete
|
|
4
|
-
* (18/107 wrong findings measured otherwise); refuses rather than `ok` when no reads
|
|
5
|
-
* exist. Pass `files` for NEW_READ_UNDECLARED — catches accessor-shape-independent reads.
|
|
6
|
-
* Add `changedLines` (from get_git_diff's patch) to verify against an added line rather
|
|
7
|
-
* than a file scope, and get `defect` instead of `lead` back for it — see C2, UAT phase 4. */
|
|
8
|
-
import { existsSync } from "node:fs";
|
|
9
|
-
import { join } from "node:path";
|
|
10
|
-
import { buildConfigGraph, checkAttributeExistence, checkEnvironment, checkMigrationIntegrity, checkObservedRoutes, checkOrmModelRegistration, checkRollbackReadiness, declaredRoutesFrom, scanConfigSurfaces, scanMigrations, } from "@descryy/core";
|
|
11
|
-
import { EvidenceStore } from "@descryy/runtime-evidence-store";
|
|
12
|
-
import { extractObservedRouteEvidence } from "../evidence/observed-route-evidence.js";
|
|
13
|
-
import { optionalInteger, optionalStringArray, ToolInputError, } from "./kit.js";
|
|
14
|
-
import { DEFAULT_EVIDENCE_RELATIVE_PATH } from "./observe-runtime.js";
|
|
15
|
-
/**
|
|
16
|
-
* Flattens every one of `validate`'s finding sources into one array: the
|
|
17
|
-
* top-level env array plus the nested reports (`rollback`, `attributeExistence`,
|
|
18
|
-
* `migrationIntegrity`, `ormRegistration`, `observedRoutes`).
|
|
19
|
-
*
|
|
20
|
-
* `validate` publishes findings across several separate sub-objects because
|
|
21
|
-
* each check examines a different kind of evidence and discloses its own
|
|
22
|
-
* `ran`/`examined`/`withheld` detail alongside its findings. A composer that
|
|
23
|
-
* reads only one of them silently drops the rest — the exact failure UAT
|
|
24
|
-
* phase 5 §4 found in `pre_push`, which read `data.findings` and nothing
|
|
25
|
-
* else. This function is the one place that knows the full list, so a new
|
|
26
|
-
* sub-check added here is inherited by every composer automatically instead
|
|
27
|
-
* of requiring a second, easily-forgotten edit at each call site.
|
|
28
|
-
*/
|
|
29
|
-
export function collectValidateFindings(data) {
|
|
30
|
-
return [
|
|
31
|
-
...data.findings,
|
|
32
|
-
...data.rollback.findings,
|
|
33
|
-
...data.attributeExistence.findings,
|
|
34
|
-
...data.migrationIntegrity.findings,
|
|
35
|
-
...data.ormRegistration.findings,
|
|
36
|
-
...data.observedRoutes.findings,
|
|
37
|
-
];
|
|
38
|
-
}
|
|
39
|
-
const SCHEMA = {
|
|
40
|
-
type: "object",
|
|
41
|
-
properties: {
|
|
42
|
-
files: {
|
|
43
|
-
type: "array",
|
|
44
|
-
items: { type: "string" },
|
|
45
|
-
description: "Restrict the code side to these repo-relative files — the scoped-subgraph run. " +
|
|
46
|
-
"Configuration files are always read in full, because a declaration is repository-wide. " +
|
|
47
|
-
"Also enables a second, stronger env-var rule (NEW_READ_UNDECLARED): a variable read in " +
|
|
48
|
-
"one of these files and declared nowhere is reported regardless of whether the accessor " +
|
|
49
|
-
"fails on absence, catching a case the default rule structurally cannot.",
|
|
50
|
-
},
|
|
51
|
-
coverageFloor: {
|
|
52
|
-
type: "number",
|
|
53
|
-
minimum: 0,
|
|
54
|
-
maximum: 1,
|
|
55
|
-
description: "Fraction of required variables the repository must declare somewhere before any " +
|
|
56
|
-
"missing-variable finding is emitted. Default 0.6. Lowering it trades precision for " +
|
|
57
|
-
"recall on a repository whose configuration lives outside the code.",
|
|
58
|
-
},
|
|
59
|
-
maxFindings: {
|
|
60
|
-
type: "integer",
|
|
61
|
-
minimum: 1,
|
|
62
|
-
description: "Cap on findings returned. Default 25; overflow is disclosed, not dropped.",
|
|
63
|
-
},
|
|
64
|
-
changedLines: {
|
|
65
|
-
type: "array",
|
|
66
|
-
items: {
|
|
67
|
-
type: "object",
|
|
68
|
-
properties: {
|
|
69
|
-
file: {
|
|
70
|
-
type: "string",
|
|
71
|
-
description: "A repo-relative path, matching one entry of \"files\".",
|
|
72
|
-
},
|
|
73
|
-
ranges: {
|
|
74
|
-
type: "array",
|
|
75
|
-
items: {
|
|
76
|
-
type: "object",
|
|
77
|
-
properties: {
|
|
78
|
-
start: { type: "integer", minimum: 1 },
|
|
79
|
-
end: { type: "integer", minimum: 1 },
|
|
80
|
-
},
|
|
81
|
-
required: ["start", "end"],
|
|
82
|
-
additionalProperties: false,
|
|
83
|
-
},
|
|
84
|
-
description: "1-based, inclusive line ranges this file's diff actually added.",
|
|
85
|
-
},
|
|
86
|
-
},
|
|
87
|
-
required: ["file", "ranges"],
|
|
88
|
-
additionalProperties: false,
|
|
89
|
-
},
|
|
90
|
-
description: "Which lines the diff actually added, per file — e.g. from get_git_diff's patch text run " +
|
|
91
|
-
"through addedLineRanges. Sharpens NEW_READ_UNDECLARED (which \"files\" alone already " +
|
|
92
|
-
"enables) from \"in a file this call scoped to\" to \"on a line this diff actually added\": " +
|
|
93
|
-
"without it, a pre-existing undeclared read in a file you touched for an unrelated reason is " +
|
|
94
|
-
"reported as a lead rather than a defect, because this call cannot tell it apart from a read " +
|
|
95
|
-
"the change just introduced. A file named in \"files\" but absent here is treated the same as " +
|
|
96
|
-
"when this argument is omitted entirely, for that file only.",
|
|
97
|
-
},
|
|
98
|
-
},
|
|
99
|
-
additionalProperties: false,
|
|
100
|
-
};
|
|
101
|
-
/** `changedLines`' wire shape ({ file, ranges }[], JSON-schema-friendly) into the
|
|
102
|
-
* `Map` `checkEnvironment` takes. Malformed input is refused, not silently dropped —
|
|
103
|
-
* a caller that thinks it narrowed the check and did not is worse off than one who
|
|
104
|
-
* never tried. */
|
|
105
|
-
function parseChangedLines(args) {
|
|
106
|
-
const raw = args["changedLines"];
|
|
107
|
-
if (raw === undefined)
|
|
108
|
-
return undefined;
|
|
109
|
-
if (!Array.isArray(raw)) {
|
|
110
|
-
throw new ToolInputError('"changedLines" must be an array of { file, ranges }.');
|
|
111
|
-
}
|
|
112
|
-
const map = new Map();
|
|
113
|
-
for (const entry of raw) {
|
|
114
|
-
if (typeof entry !== "object" || entry === null) {
|
|
115
|
-
throw new ToolInputError('Each "changedLines" entry must be an object with "file" and "ranges".');
|
|
116
|
-
}
|
|
117
|
-
const row = entry;
|
|
118
|
-
const file = row["file"];
|
|
119
|
-
const ranges = row["ranges"];
|
|
120
|
-
if (typeof file !== "string" || file === "" || !Array.isArray(ranges)) {
|
|
121
|
-
throw new ToolInputError('Each "changedLines" entry needs a non-empty "file" and a "ranges" array.');
|
|
122
|
-
}
|
|
123
|
-
const parsedRanges = [];
|
|
124
|
-
for (const range of ranges) {
|
|
125
|
-
const r = typeof range === "object" && range !== null ? range : null;
|
|
126
|
-
const start = r?.["start"];
|
|
127
|
-
const end = r?.["end"];
|
|
128
|
-
if (typeof start !== "number" || typeof end !== "number") {
|
|
129
|
-
throw new ToolInputError(`"changedLines" entry for "${file}" has a range that is not { start, end }.`);
|
|
130
|
-
}
|
|
131
|
-
parsedRanges.push({ start, end });
|
|
132
|
-
}
|
|
133
|
-
map.set(file, parsedRanges);
|
|
134
|
-
}
|
|
135
|
-
return map;
|
|
136
|
-
}
|
|
137
|
-
/**
|
|
138
|
-
* UAT phase 5 §5 (D2): reads `observe_runtime`'s own evidence database, if one
|
|
139
|
-
* already exists, and checks its `NETWORK_RESPONSE`/`HTTP_ERROR` evidence
|
|
140
|
-
* against the graph's declared routes.
|
|
141
|
-
*
|
|
142
|
-
* Never creates the database — this is a read tool, and `observe_runtime` (an
|
|
143
|
-
* action tool) is the only thing with a legitimate reason to write one.
|
|
144
|
-
*/
|
|
145
|
-
function readObservedRoutes(repoPath, provider) {
|
|
146
|
-
const evidencePath = join(repoPath, DEFAULT_EVIDENCE_RELATIVE_PATH);
|
|
147
|
-
if (!existsSync(evidencePath)) {
|
|
148
|
-
return {
|
|
149
|
-
findings: [],
|
|
150
|
-
examined: 0,
|
|
151
|
-
ran: false,
|
|
152
|
-
note: `No evidence database exists yet at ${evidencePath} — observe_runtime has not run against ` +
|
|
153
|
-
"this repository. observedRoutes did not run.",
|
|
154
|
-
};
|
|
155
|
-
}
|
|
156
|
-
const store = new EvidenceStore({ path: evidencePath });
|
|
157
|
-
try {
|
|
158
|
-
const events = [
|
|
159
|
-
...store.query({ executionId: null, eventType: "NETWORK_REQUEST" }),
|
|
160
|
-
...store.query({ executionId: null, eventType: "NETWORK_RESPONSE" }),
|
|
161
|
-
...store.query({ executionId: null, eventType: "HTTP_ERROR" }),
|
|
162
|
-
];
|
|
163
|
-
const observed = extractObservedRouteEvidence(events);
|
|
164
|
-
if (observed.length === 0) {
|
|
165
|
-
return {
|
|
166
|
-
findings: [],
|
|
167
|
-
examined: 0,
|
|
168
|
-
ran: false,
|
|
169
|
-
note: "The evidence database exists but holds no NETWORK_RESPONSE/HTTP_ERROR evidence with a " +
|
|
170
|
-
"usable method, URL and status. observedRoutes did not run.",
|
|
171
|
-
};
|
|
172
|
-
}
|
|
173
|
-
const result = checkObservedRoutes(observed, declaredRoutesFrom(provider));
|
|
174
|
-
return { findings: result.findings, examined: result.examined, ran: true, note: null };
|
|
175
|
-
}
|
|
176
|
-
finally {
|
|
177
|
-
store.close();
|
|
178
|
-
}
|
|
179
|
-
}
|
|
180
|
-
async function run(args, ctx) {
|
|
181
|
-
const files = optionalStringArray(args, "files");
|
|
182
|
-
const maxFindings = optionalInteger(args, "maxFindings", 1);
|
|
183
|
-
const rawFloor = args["coverageFloor"];
|
|
184
|
-
const coverageFloor = typeof rawFloor === "number" && rawFloor >= 0 && rawFloor <= 1 ? rawFloor : undefined;
|
|
185
|
-
const changedLines = parseChangedLines(args);
|
|
186
|
-
ctx.progress("Reading configuration files");
|
|
187
|
-
const scan = scanConfigSurfaces(ctx.session.repoPath);
|
|
188
|
-
ctx.progress("Cross-checking against environment reads in the graph");
|
|
189
|
-
const provider = ctx.session.provider();
|
|
190
|
-
const checked = checkEnvironment(provider, scan, {
|
|
191
|
-
...(files === undefined ? {} : { files }),
|
|
192
|
-
...(maxFindings === undefined ? {} : { maxFindings }),
|
|
193
|
-
...(coverageFloor === undefined ? {} : { coverageFloor }),
|
|
194
|
-
...(changedLines === undefined ? {} : { changedLines }),
|
|
195
|
-
});
|
|
196
|
-
ctx.progress("Tracing what depends on each configuration variable");
|
|
197
|
-
const configGraph = buildConfigGraph(provider, scan);
|
|
198
|
-
ctx.progress("Reading migrations for destructive operations");
|
|
199
|
-
const rollback = checkRollbackReadiness(provider, scanMigrations(ctx.session.repoPath), {
|
|
200
|
-
...(files === undefined ? {} : { files }),
|
|
201
|
-
...(maxFindings === undefined ? {} : { maxFindings }),
|
|
202
|
-
});
|
|
203
|
-
ctx.progress("Checking attribute reads against declared types");
|
|
204
|
-
const attributeExistence = checkAttributeExistence(provider, {
|
|
205
|
-
...(files === undefined ? {} : { files }),
|
|
206
|
-
...(maxFindings === undefined ? {} : { maxFindings }),
|
|
207
|
-
});
|
|
208
|
-
ctx.progress("Checking migration location and revision chain");
|
|
209
|
-
const migrationIntegrity = checkMigrationIntegrity(provider, {
|
|
210
|
-
...(files === undefined ? {} : { files }),
|
|
211
|
-
...(maxFindings === undefined ? {} : { maxFindings }),
|
|
212
|
-
});
|
|
213
|
-
ctx.progress("Checking ORM models are reached by their package's __init__");
|
|
214
|
-
const ormRegistration = checkOrmModelRegistration(provider, {
|
|
215
|
-
...(files === undefined ? {} : { files }),
|
|
216
|
-
...(maxFindings === undefined ? {} : { maxFindings }),
|
|
217
|
-
});
|
|
218
|
-
ctx.progress("Checking observed HTTP responses against declared routes");
|
|
219
|
-
const observedRoutes = readObservedRoutes(ctx.session.repoPath, provider);
|
|
220
|
-
const report = checked.data;
|
|
221
|
-
const defects = report.findings.filter((f) => f.claim === "defect").length +
|
|
222
|
-
attributeExistence.data.findings.length +
|
|
223
|
-
migrationIntegrity.data.findings.length;
|
|
224
|
-
const leads = report.findings.length - report.findings.filter((f) => f.claim === "defect").length;
|
|
225
|
-
// Nothing compared at all: no config files, reads, migrations, attribute reads,
|
|
226
|
-
// or migration revisions — any one alone is a real answer, none of them is not.
|
|
227
|
-
const nothingToCheck = report.surfaces.length === 0 &&
|
|
228
|
-
!report.readsAvailable &&
|
|
229
|
-
!rollback.data.ran &&
|
|
230
|
-
!attributeExistence.data.ran &&
|
|
231
|
-
!migrationIntegrity.data.ran &&
|
|
232
|
-
!ormRegistration.data.ran &&
|
|
233
|
-
!observedRoutes.ran;
|
|
234
|
-
// A `files` scope matching zero FILE nodes means those files were never read into
|
|
235
|
-
// the graph (bad path, or unparsed) — not "read and clean". Same collapse as
|
|
236
|
-
// `contracts(paths)`, one level down.
|
|
237
|
-
const filesMatchedNothing = files !== undefined && report.reads.filesWithReads + report.reads.filesWithoutReads === 0;
|
|
238
|
-
// Leads and rollback findings are worth a look; defects are what this tool exists
|
|
239
|
-
// to catch. Never blur the two into one count (see EnvFindingReport.claim).
|
|
240
|
-
const otherFindings = leads + rollback.data.findings.length + ormRegistration.data.findings.length + observedRoutes.findings.length;
|
|
241
|
-
// A "Clean" verdict from a files scope matching nothing would misreport "checked,
|
|
242
|
-
// fine" when nothing was read. Only pure-Clean is downgraded — real findings from
|
|
243
|
-
// unscoped checks still surface.
|
|
244
|
-
const falseClean = filesMatchedNothing && defects === 0 && otherFindings === 0;
|
|
245
|
-
const verdict = falseClean
|
|
246
|
-
? "not checked"
|
|
247
|
-
: defects > 0
|
|
248
|
-
? `${defects} defect(s) found`
|
|
249
|
-
: otherFindings > 0
|
|
250
|
-
? `No defects; ${otherFindings} lead(s)/rollback finding(s) to review`
|
|
251
|
-
: "Clean";
|
|
252
|
-
const scopeNotes = filesMatchedNothing
|
|
253
|
-
? [
|
|
254
|
-
`0 of the ${(files ?? []).length} named file(s) matched a FILE node this graph's read side ` +
|
|
255
|
-
"considered — either the path is wrong, or the file was never read into the graph. The " +
|
|
256
|
-
"environment-read half of this report has nothing to say about them; it is not evidence " +
|
|
257
|
-
"they are clean.",
|
|
258
|
-
]
|
|
259
|
-
: [];
|
|
260
|
-
// render.ts requires truncatedDetail whenever truncated=true. `truncated` folds 5
|
|
261
|
-
// independently-truncatable sources; shown/total cover the finding lists a
|
|
262
|
-
// maxFindings cap acts on — configGraph's own truncation stays prose-only.
|
|
263
|
-
// `observedRoutes` has no cap of its own (bounded by evidence volume, not by
|
|
264
|
-
// this tool), so it contributes the same count to both.
|
|
265
|
-
const shown = report.findings.length +
|
|
266
|
-
rollback.data.findings.length +
|
|
267
|
-
attributeExistence.data.findings.length +
|
|
268
|
-
migrationIntegrity.data.findings.length +
|
|
269
|
-
ormRegistration.data.findings.length +
|
|
270
|
-
observedRoutes.findings.length;
|
|
271
|
-
const total = report.findingsTotal +
|
|
272
|
-
rollback.data.findingsTotal +
|
|
273
|
-
attributeExistence.data.findingsTotal +
|
|
274
|
-
migrationIntegrity.data.findingsTotal +
|
|
275
|
-
ormRegistration.data.findingsTotal +
|
|
276
|
-
observedRoutes.findings.length;
|
|
277
|
-
const truncated = checked.truncated ||
|
|
278
|
-
rollback.truncated ||
|
|
279
|
-
attributeExistence.truncated ||
|
|
280
|
-
migrationIntegrity.truncated ||
|
|
281
|
-
ormRegistration.truncated ||
|
|
282
|
-
configGraph.truncated;
|
|
283
|
-
const truncatedDetail = truncated
|
|
284
|
-
? { shown, total: Math.max(total, shown), more: null }
|
|
285
|
-
: undefined;
|
|
286
|
-
return {
|
|
287
|
-
result: {
|
|
288
|
-
...checked,
|
|
289
|
-
data: {
|
|
290
|
-
findings: report.findings.map((f) => ({
|
|
291
|
-
kind: f.kind,
|
|
292
|
-
name: f.name,
|
|
293
|
-
claim: f.claim,
|
|
294
|
-
detail: f.detail,
|
|
295
|
-
evidence: f.evidence,
|
|
296
|
-
resolution: f.resolution,
|
|
297
|
-
})),
|
|
298
|
-
findingsTotal: report.findingsTotal,
|
|
299
|
-
surfaces: report.surfaces,
|
|
300
|
-
reads: report.reads,
|
|
301
|
-
coverage: report.coverage,
|
|
302
|
-
declaredNeverRead: report.declaredNeverRead,
|
|
303
|
-
readsAvailable: report.readsAvailable,
|
|
304
|
-
// §15.3's third check feeds the first. Only variables with a computable
|
|
305
|
-
// dependent set are carried — unknown count is not a zero, not worth a row.
|
|
306
|
-
configGraph: {
|
|
307
|
-
counts: configGraph.data.counts,
|
|
308
|
-
importsAvailable: configGraph.data.importsAvailable,
|
|
309
|
-
mostDependedOn: configGraph.data.variables
|
|
310
|
-
.filter((v) => v.dependents !== null && v.dependents > 0)
|
|
311
|
-
.slice(0, 10)
|
|
312
|
-
.map((v) => ({
|
|
313
|
-
name: v.name,
|
|
314
|
-
dependents: v.dependents,
|
|
315
|
-
truncated: v.dependentsTruncated,
|
|
316
|
-
readAt: v.readAt.slice(0, 3),
|
|
317
|
-
sample: v.dependentSample,
|
|
318
|
-
})),
|
|
319
|
-
},
|
|
320
|
-
rollback: {
|
|
321
|
-
findings: rollback.data.findings,
|
|
322
|
-
findingsTotal: rollback.data.findingsTotal,
|
|
323
|
-
examined: rollback.data.examined,
|
|
324
|
-
withheld: rollback.data.withheld,
|
|
325
|
-
ran: rollback.data.ran,
|
|
326
|
-
blockers: rollback.data.blockers,
|
|
327
|
-
},
|
|
328
|
-
attributeExistence: {
|
|
329
|
-
findings: attributeExistence.data.findings,
|
|
330
|
-
findingsTotal: attributeExistence.data.findingsTotal,
|
|
331
|
-
examined: attributeExistence.data.examined,
|
|
332
|
-
ran: attributeExistence.data.ran,
|
|
333
|
-
},
|
|
334
|
-
migrationIntegrity: {
|
|
335
|
-
findings: migrationIntegrity.data.findings,
|
|
336
|
-
findingsTotal: migrationIntegrity.data.findingsTotal,
|
|
337
|
-
examined: migrationIntegrity.data.examined,
|
|
338
|
-
migrationsDirectory: migrationIntegrity.data.migrationsDirectory,
|
|
339
|
-
ran: migrationIntegrity.data.ran,
|
|
340
|
-
withheld: migrationIntegrity.data.withheld,
|
|
341
|
-
},
|
|
342
|
-
ormRegistration: {
|
|
343
|
-
findings: ormRegistration.data.findings,
|
|
344
|
-
findingsTotal: ormRegistration.data.findingsTotal,
|
|
345
|
-
examined: ormRegistration.data.examined,
|
|
346
|
-
ran: ormRegistration.data.ran,
|
|
347
|
-
withheld: ormRegistration.data.withheld,
|
|
348
|
-
},
|
|
349
|
-
observedRoutes: {
|
|
350
|
-
findings: observedRoutes.findings,
|
|
351
|
-
findingsTotal: observedRoutes.findings.length,
|
|
352
|
-
examined: observedRoutes.examined,
|
|
353
|
-
ran: observedRoutes.ran,
|
|
354
|
-
},
|
|
355
|
-
},
|
|
356
|
-
// Every check's disclosures reach the reader — dropping one half silently
|
|
357
|
-
// is the degradation rule 7 exists to prevent.
|
|
358
|
-
notes: [
|
|
359
|
-
...scopeNotes,
|
|
360
|
-
...(observedRoutes.note === null ? [] : [observedRoutes.note]),
|
|
361
|
-
...checked.notes,
|
|
362
|
-
...rollback.notes,
|
|
363
|
-
...attributeExistence.notes,
|
|
364
|
-
...migrationIntegrity.notes,
|
|
365
|
-
...ormRegistration.notes,
|
|
366
|
-
...configGraph.notes,
|
|
367
|
-
],
|
|
368
|
-
truncated,
|
|
369
|
-
stamp: {
|
|
370
|
-
...checked.stamp,
|
|
371
|
-
resolutionFloor: Math.min(checked.stamp.resolutionFloor, rollback.stamp.resolutionFloor, attributeExistence.stamp.resolutionFloor, migrationIntegrity.stamp.resolutionFloor, ormRegistration.stamp.resolutionFloor, configGraph.stamp.resolutionFloor),
|
|
372
|
-
},
|
|
373
|
-
},
|
|
374
|
-
// §11A.5's canonical name-level fact (exists or not) — the one claim R2 supports
|
|
375
|
-
// at class A. Value shape is never asserted here.
|
|
376
|
-
nameLevel: true,
|
|
377
|
-
...(truncatedDetail === undefined ? {} : { truncatedDetail }),
|
|
378
|
-
...(nothingToCheck
|
|
379
|
-
? { state: "refused" }
|
|
380
|
-
: falseClean
|
|
381
|
-
? { state: "empty" }
|
|
382
|
-
: {}),
|
|
383
|
-
headline: nothingToCheck
|
|
384
|
-
? "No configuration files, environment reads, migrations or attribute reads were found, so " +
|
|
385
|
-
"there was nothing to check."
|
|
386
|
-
: falseClean
|
|
387
|
-
? `0 of the ${(files ?? []).length} named file(s) matched anything on the read side. Not ` +
|
|
388
|
-
"checked, not clean."
|
|
389
|
-
: `${verdict}. ${report.surfaces.length} configuration file(s) declare ` +
|
|
390
|
-
`${countDeclared(report.surfaces)} variable(s); ` +
|
|
391
|
-
`${report.reads.required} variable(s) are read through an accessor that fails when unset; ` +
|
|
392
|
-
`${rollback.data.examined.operations} destructive migration operation(s) examined; ` +
|
|
393
|
-
`${attributeExistence.data.examined.readEdgesExamined} attribute read(s) checked against ` +
|
|
394
|
-
`a declared type; ${migrationIntegrity.data.examined.modulesWithRevision} migration(s) ` +
|
|
395
|
-
"checked for location and revision-chain integrity; " +
|
|
396
|
-
`${ormRegistration.data.examined.candidates} ORM model(s) inheriting a declarative base ` +
|
|
397
|
-
"checked for package-import reachability; " +
|
|
398
|
-
`${observedRoutes.examined} observed HTTP response(s) checked against declared routes.`,
|
|
399
|
-
};
|
|
400
|
-
}
|
|
401
|
-
function countDeclared(surfaces) {
|
|
402
|
-
return surfaces.reduce((total, s) => total + s.declared, 0);
|
|
403
|
-
}
|
|
404
|
-
export const validateTool = {
|
|
405
|
-
name: "validate",
|
|
406
|
-
class: "read",
|
|
407
|
-
tier: "conclusion",
|
|
408
|
-
// 1.1.0 (C2, UAT phase 4): without "changedLines", NEW_READ_UNDECLARED for a
|
|
409
|
-
// pre-existing read in a "files"-scoped file is now a `lead`, worded without
|
|
410
|
-
// an authorship claim, where it used to be a `defect` calling it "a new read
|
|
411
|
-
// this change introduces" — a claim `files` alone never supported. A caller
|
|
412
|
-
// that passes "changedLines" gets the stronger `defect` back, now genuinely
|
|
413
|
-
// verified against an added line rather than assumed from file scope.
|
|
414
|
-
version: "1.1.0",
|
|
415
|
-
title: "Environment and configuration checks",
|
|
416
|
-
description: "Cross-check the environment variables the code requires against the ones this repository " +
|
|
417
|
-
"declares. Reports a variable only when the code reads it with no fallback and no " +
|
|
418
|
-
"configuration file declares it, and only when the repository's declaration surface is " +
|
|
419
|
-
"complete enough for that absence to mean something — a variable supplied by a secrets " +
|
|
420
|
-
"manager or a platform is disclosed with a count, never reported as missing. Pass \"files\" " +
|
|
421
|
-
"(the diff you are about to push) to also catch a variable your change reads that no " +
|
|
422
|
-
"declaration surface declares, regardless of whether the accessor fails on absence — the " +
|
|
423
|
-
"usual shape on a codebase where almost no read is required; without \"changedLines\" this is " +
|
|
424
|
-
"reported as a lead, because a file-scoped read cannot yet be told apart from one the diff never " +
|
|
425
|
-
"touched. Pass \"changedLines\" (from get_git_diff's patch text) to sharpen it to a defect, " +
|
|
426
|
-
"verified against a line the diff actually added. Also reports variables set in " +
|
|
427
|
-
"one configuration file and documented in no example file, stated as a lead rather than a " +
|
|
428
|
-
"defect. Two further checks, both always defects because both are provable from the graph " +
|
|
429
|
-
"alone: an attribute read on a value whose declared type does not name it (from a READS " +
|
|
430
|
-
"edge's attrs.unresolvedFields), and a migration whose location or declared parent revision " +
|
|
431
|
-
"disagrees with the rest of the project's migrations (from attrs.migrationRevision, " +
|
|
432
|
-
"migrationDownRevision and migrationDir). Both are silent wherever the producer supplied no " +
|
|
433
|
-
"signal — absence of the attrs key is never read as a clean result. A fifth check reports a " +
|
|
434
|
-
"class inheriting an ORM declarative base (a MODEL node with an INHERITS edge) whose own " +
|
|
435
|
-
"module no __init__.py in its package reaches, directly or transitively — the shape behind a " +
|
|
436
|
-
"model silently missing from Base.metadata and having its table dropped by the next " +
|
|
437
|
-
"autogenerate. Always a lead, never a defect: an explicit scan/glob registration or a " +
|
|
438
|
-
"deliberately excluded model triggers it without being a bug.",
|
|
439
|
-
inputSchema: SCHEMA,
|
|
440
|
-
run,
|
|
441
|
-
};
|
|
442
|
-
//# sourceMappingURL=validate.js.map
|
|
@@ -1 +0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FAAqF;QACrF,6FAA6F;QAC7F,6FAA6F;QAC7F,0FAA0F;QAC1F,8FAA8F;QAC9F,qFAAqF;QACrF,uFAAuF;QACvF,8DAA8D;IAChE,WAAW,EAAE,MAA4C;IACzD,GAAG;CACJ,CAAC"}
|
package/dist/tools/verb.d.ts
DELETED
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Per-verb argument validation for a merged tool.
|
|
3
|
-
*
|
|
4
|
-
* ## Why a merged tool needs this at all
|
|
5
|
-
*
|
|
6
|
-
* The dispatch loop refuses any argument no schema declares
|
|
7
|
-
* (`server.ts`'s `unknownArgumentKeys`, built for UAT phase 5's F12 after
|
|
8
|
-
* `browser_start_session({ profile })` silently read `environment` and issued
|
|
9
|
-
* the wrong consent sentence). That check reads one flat `inputSchema`.
|
|
10
|
-
*
|
|
11
|
-
* A merged tool has one schema for many verbs, so its schema must declare the
|
|
12
|
-
* *union* of every verb's properties. `text` is then a declared property of the
|
|
13
|
-
* `browser` tool as a whole, and `browser({ verb: "snapshot", text: "hi" })`
|
|
14
|
-
* sails through the dispatch gate — the same silent-acceptance defect, one
|
|
15
|
-
* level further down, and invisible to the test that caught it the first time.
|
|
16
|
-
*
|
|
17
|
-
* So the strength the flat schema loses is re-established here, per verb. This
|
|
18
|
-
* is the price of merging, paid explicitly rather than absorbed.
|
|
19
|
-
*
|
|
20
|
-
* ## Why it names the other verb
|
|
21
|
-
*
|
|
22
|
-
* "unknown argument" is true but useless when the argument is real and the verb
|
|
23
|
-
* is wrong — the caller who sent `text` to `snapshot` did not misspell
|
|
24
|
-
* anything, they picked the wrong verb. Saying *`"text"` belongs to `type`*
|
|
25
|
-
* turns a refusal the caller must debug into one they can act on, which is the
|
|
26
|
-
* same reason `ToolInputError` exists separately from a thrown `Error`.
|
|
27
|
-
*/
|
|
28
|
-
export interface VerbSpec<V extends string = string> {
|
|
29
|
-
readonly verb: V;
|
|
30
|
-
/** Properties this verb accepts, beyond the shared ones. */
|
|
31
|
-
readonly accepts: readonly string[];
|
|
32
|
-
}
|
|
33
|
-
/**
|
|
34
|
-
* Resolve and validate the verb of a merged tool call.
|
|
35
|
-
*
|
|
36
|
-
* Refuses, rather than defaulting or ignoring, on: a missing verb, an unknown
|
|
37
|
-
* verb, and any property that belongs to a different verb. Returns the verb so
|
|
38
|
-
* the caller can switch on a value already known to be valid.
|
|
39
|
-
*
|
|
40
|
-
* `shared` are properties every verb accepts — a session id, a budget. A
|
|
41
|
-
* property in neither `shared` nor any verb's `accepts` is not this function's
|
|
42
|
-
* to judge: the dispatch gate already refused it against the declared schema,
|
|
43
|
-
* and re-refusing it here would put the tool's property list in two places.
|
|
44
|
-
*/
|
|
45
|
-
export declare function selectVerb<V extends string>(args: Record<string, unknown>, key: string, specs: readonly VerbSpec<V>[], shared?: readonly string[]): V;
|
|
46
|
-
//# sourceMappingURL=verb.d.ts.map
|
package/dist/tools/verb.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"verb.d.ts","sourceRoot":"","sources":["../../src/tools/verb.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAIH,MAAM,WAAW,QAAQ,CAAC,CAAC,SAAS,MAAM,GAAG,MAAM;IACjD,QAAQ,CAAC,IAAI,EAAE,CAAC,CAAC;IACjB,4DAA4D;IAC5D,QAAQ,CAAC,OAAO,EAAE,SAAS,MAAM,EAAE,CAAC;CACrC;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,UAAU,CAAC,CAAC,SAAS,MAAM,EACzC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC7B,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,SAAS,QAAQ,CAAC,CAAC,CAAC,EAAE,EAC7B,MAAM,GAAE,SAAS,MAAM,EAAO,GAC7B,CAAC,CAwCH"}
|
package/dist/tools/verb.js
DELETED
|
@@ -1,78 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Per-verb argument validation for a merged tool.
|
|
3
|
-
*
|
|
4
|
-
* ## Why a merged tool needs this at all
|
|
5
|
-
*
|
|
6
|
-
* The dispatch loop refuses any argument no schema declares
|
|
7
|
-
* (`server.ts`'s `unknownArgumentKeys`, built for UAT phase 5's F12 after
|
|
8
|
-
* `browser_start_session({ profile })` silently read `environment` and issued
|
|
9
|
-
* the wrong consent sentence). That check reads one flat `inputSchema`.
|
|
10
|
-
*
|
|
11
|
-
* A merged tool has one schema for many verbs, so its schema must declare the
|
|
12
|
-
* *union* of every verb's properties. `text` is then a declared property of the
|
|
13
|
-
* `browser` tool as a whole, and `browser({ verb: "snapshot", text: "hi" })`
|
|
14
|
-
* sails through the dispatch gate — the same silent-acceptance defect, one
|
|
15
|
-
* level further down, and invisible to the test that caught it the first time.
|
|
16
|
-
*
|
|
17
|
-
* So the strength the flat schema loses is re-established here, per verb. This
|
|
18
|
-
* is the price of merging, paid explicitly rather than absorbed.
|
|
19
|
-
*
|
|
20
|
-
* ## Why it names the other verb
|
|
21
|
-
*
|
|
22
|
-
* "unknown argument" is true but useless when the argument is real and the verb
|
|
23
|
-
* is wrong — the caller who sent `text` to `snapshot` did not misspell
|
|
24
|
-
* anything, they picked the wrong verb. Saying *`"text"` belongs to `type`*
|
|
25
|
-
* turns a refusal the caller must debug into one they can act on, which is the
|
|
26
|
-
* same reason `ToolInputError` exists separately from a thrown `Error`.
|
|
27
|
-
*/
|
|
28
|
-
import { ToolInputError } from "./kit.js";
|
|
29
|
-
/**
|
|
30
|
-
* Resolve and validate the verb of a merged tool call.
|
|
31
|
-
*
|
|
32
|
-
* Refuses, rather than defaulting or ignoring, on: a missing verb, an unknown
|
|
33
|
-
* verb, and any property that belongs to a different verb. Returns the verb so
|
|
34
|
-
* the caller can switch on a value already known to be valid.
|
|
35
|
-
*
|
|
36
|
-
* `shared` are properties every verb accepts — a session id, a budget. A
|
|
37
|
-
* property in neither `shared` nor any verb's `accepts` is not this function's
|
|
38
|
-
* to judge: the dispatch gate already refused it against the declared schema,
|
|
39
|
-
* and re-refusing it here would put the tool's property list in two places.
|
|
40
|
-
*/
|
|
41
|
-
export function selectVerb(args, key, specs, shared = []) {
|
|
42
|
-
const raw = args[key];
|
|
43
|
-
if (raw === undefined || raw === null || raw === "") {
|
|
44
|
-
throw new ToolInputError(`"${key}" is required — one of: ${specs.map((s) => s.verb).join(", ")}`);
|
|
45
|
-
}
|
|
46
|
-
if (typeof raw !== "string")
|
|
47
|
-
throw new ToolInputError(`"${key}" must be a string`);
|
|
48
|
-
const spec = specs.find((s) => s.verb === raw);
|
|
49
|
-
if (spec === undefined) {
|
|
50
|
-
throw new ToolInputError(`"${key}" must be one of: ${specs.map((s) => s.verb).join(", ")}`);
|
|
51
|
-
}
|
|
52
|
-
// Where each property that is not this verb's does belong. Built per call
|
|
53
|
-
// rather than hoisted: the specs are a handful of entries, and a module-level
|
|
54
|
-
// cache keyed on a caller-supplied array is a lifetime question this does not
|
|
55
|
-
// need to have.
|
|
56
|
-
const ownerOf = new Map();
|
|
57
|
-
for (const other of specs) {
|
|
58
|
-
if (other.verb === spec.verb)
|
|
59
|
-
continue;
|
|
60
|
-
for (const property of other.accepts) {
|
|
61
|
-
if (spec.accepts.includes(property))
|
|
62
|
-
continue;
|
|
63
|
-
// First owner wins only for the message; the refusal is the same either
|
|
64
|
-
// way, and listing every owner of a property shared by two other verbs
|
|
65
|
-
// would bury the one fact the caller needs.
|
|
66
|
-
if (!ownerOf.has(property))
|
|
67
|
-
ownerOf.set(property, other.verb);
|
|
68
|
-
}
|
|
69
|
-
}
|
|
70
|
-
const strays = Object.keys(args).filter((property) => property !== key && !shared.includes(property) && ownerOf.has(property));
|
|
71
|
-
if (strays.length > 0) {
|
|
72
|
-
const detail = strays.map((property) => `"${property}" belongs to ${ownerOf.get(property)}`).join("; ");
|
|
73
|
-
throw new ToolInputError(`${spec.verb} does not accept ${strays.map((p) => `"${p}"`).join(", ")} — ${detail}. ` +
|
|
74
|
-
`${spec.verb} accepts: ${[...shared, ...spec.accepts].join(", ") || "no arguments beyond the verb"}.`);
|
|
75
|
-
}
|
|
76
|
-
return spec.verb;
|
|
77
|
-
}
|
|
78
|
-
//# sourceMappingURL=verb.js.map
|
package/dist/tools/verb.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"verb.js","sourceRoot":"","sources":["../../src/tools/verb.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC;AAQ1C;;;;;;;;;;;GAWG;AACH,MAAM,UAAU,UAAU,CACxB,IAA6B,EAC7B,GAAW,EACX,KAA6B,EAC7B,SAA4B,EAAE;IAE9B,MAAM,GAAG,GAAG,IAAI,CAAC,GAAG,CAAC,CAAC;IACtB,IAAI,GAAG,KAAK,SAAS,IAAI,GAAG,KAAK,IAAI,IAAI,GAAG,KAAK,EAAE,EAAE,CAAC;QACpD,MAAM,IAAI,cAAc,CAAC,IAAI,GAAG,2BAA2B,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IACpG,CAAC;IACD,IAAI,OAAO,GAAG,KAAK,QAAQ;QAAE,MAAM,IAAI,cAAc,CAAC,IAAI,GAAG,oBAAoB,CAAC,CAAC;IAEnF,MAAM,IAAI,GAAG,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,GAAG,CAAC,CAAC;IAC/C,IAAI,IAAI,KAAK,SAAS,EAAE,CAAC;QACvB,MAAM,IAAI,cAAc,CAAC,IAAI,GAAG,qBAAqB,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAA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,MAAM,IAAI;YACpF,GAAG,IAAI,CAAC,IAAI,aAAa,CAAC,GAAG,MAAM,EAAE,GAAG,IAAI,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,8BAA8B,GAAG,CACxG,CAAC;IACJ,CAAC;IAED,OAAO,IAAI,CAAC,IAAI,CAAC;AACnB,CAAC"}
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
/** `verification_status`, §4 technique 6: coverage is a separate axis and call, paid once, only
|
|
2
|
-
* when asked. Wraps `computeVerificationStatus` (the static half). Never names a language (rule
|
|
3
|
-
* 1) — an earlier extension-guessing design tripped the boundary lint, so it now asks each
|
|
4
|
-
* loaded adapter's `ownsPath` instead. Resolves a ref by node id first, then file (the file's own
|
|
5
|
-
* informative `FILE` node when one carries real resolution, else the weakest-resolution member
|
|
6
|
-
* among whatever real (non-stub) evidence exists for that file — a `git-history`-produced FILE
|
|
7
|
-
* node at resolution 0 is a per-touched-file identity marker, not analysis, and must never win by
|
|
8
|
-
* merely being present; see `representativeForFile`) — neither way found means `notExercised`. */
|
|
9
|
-
import type { ResolutionLevel } from "@descryy/ir";
|
|
10
|
-
import { type ToolDefinition } from "./kit.ts";
|
|
11
|
-
export interface VerificationStatusExercisedItem {
|
|
12
|
-
readonly ref: string;
|
|
13
|
-
readonly resolution: ResolutionLevel;
|
|
14
|
-
}
|
|
15
|
-
export interface VerificationStatusData {
|
|
16
|
-
readonly checked: readonly string[];
|
|
17
|
-
readonly exercised: readonly VerificationStatusExercisedItem[];
|
|
18
|
-
readonly notExercised: readonly {
|
|
19
|
-
readonly scope: string;
|
|
20
|
-
readonly reason: string;
|
|
21
|
-
}[];
|
|
22
|
-
/** The runtime half: refs a real test run bore on and how those tests finished. Empty means
|
|
23
|
-
* either "nothing covers this" or "no suite run yet" — the notes disambiguate. */
|
|
24
|
-
readonly verifiedByTests: readonly VerificationStatusTestedItem[];
|
|
25
|
-
}
|
|
26
|
-
export interface VerificationStatusTestedItem {
|
|
27
|
-
readonly ref: string;
|
|
28
|
-
/** `false` when reached via a static `TESTS` edge, not observed directly — the run witnessed the
|
|
29
|
-
* test execute, not that it touched this ref. Carried per item, not just in a disclosure. */
|
|
30
|
-
readonly direct: boolean;
|
|
31
|
-
readonly tests: readonly {
|
|
32
|
-
readonly qualifiedName: string;
|
|
33
|
-
readonly outcome: string;
|
|
34
|
-
readonly runId: string;
|
|
35
|
-
}[];
|
|
36
|
-
}
|
|
37
|
-
export declare const verificationStatusTool: ToolDefinition;
|
|
38
|
-
//# sourceMappingURL=verification-status.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"verification-status.d.ts","sourceRoot":"","sources":["../../src/tools/verification-status.ts"],"names":[],"mappings":"AAAA;;;;;;;mGAOmG;AAUnG,OAAO,KAAK,EAA4B,eAAe,EAAE,MAAM,aAAa,CAAC;AAE7E,OAAO,EAKL,KAAK,cAAc,EACpB,MAAM,UAAU,CAAC;AAqBlB,MAAM,WAAW,+BAA+B;IAC9C,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,UAAU,EAAE,eAAe,CAAC;CACtC;AAED,MAAM,WAAW,sBAAsB;IACrC,QAAQ,CAAC,OAAO,EAAE,SAAS,MAAM,EAAE,CAAC;IACpC,QAAQ,CAAC,SAAS,EAAE,SAAS,+BAA+B,EAAE,CAAC;IAC/D,QAAQ,CAAC,YAAY,EAAE,SAAS;QAAE,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;QAAC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;IACtF;uFACmF;IACnF,QAAQ,CAAC,eAAe,EAAE,SAAS,4BAA4B,EAAE,CAAC;CACnE;AAED,MAAM,WAAW,4BAA4B;IAC3C,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB;kGAC8F;IAC9F,QAAQ,CAAC,MAAM,EAAE,OAAO,CAAC;IACzB,QAAQ,CAAC,KAAK,EAAE,SAAS;QACvB,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;QAC/B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;QACzB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;KACxB,EAAE,CAAC;CACL;AAyLD,eAAO,MAAM,sBAAsB,EAAE,cAkBpC,CAAC"}
|