@usenaive-sdk/cli 0.15.1 → 1.0.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.
- package/README.md +43 -402
- package/dist/index.js +51775 -502
- package/package.json +22 -18
- package/dist/client.d.ts +0 -108
- package/dist/client.js +0 -458
- package/dist/client.js.map +0 -1
- package/dist/commands/account-kits.d.ts +0 -2
- package/dist/commands/account-kits.js +0 -71
- package/dist/commands/account-kits.js.map +0 -1
- package/dist/commands/aeo.d.ts +0 -2
- package/dist/commands/aeo.js +0 -451
- package/dist/commands/aeo.js.map +0 -1
- package/dist/commands/agent-profiles.d.ts +0 -11
- package/dist/commands/agent-profiles.js +0 -120
- package/dist/commands/agent-profiles.js.map +0 -1
- package/dist/commands/agents.d.ts +0 -2
- package/dist/commands/agents.js +0 -916
- package/dist/commands/agents.js.map +0 -1
- package/dist/commands/app-data.d.ts +0 -2
- package/dist/commands/app-data.js +0 -445
- package/dist/commands/app-data.js.map +0 -1
- package/dist/commands/approvals.d.ts +0 -2
- package/dist/commands/approvals.js +0 -242
- package/dist/commands/approvals.js.map +0 -1
- package/dist/commands/apps.d.ts +0 -9
- package/dist/commands/apps.js +0 -844
- package/dist/commands/apps.js.map +0 -1
- package/dist/commands/audio.d.ts +0 -9
- package/dist/commands/audio.js +0 -391
- package/dist/commands/audio.js.map +0 -1
- package/dist/commands/auth.d.ts +0 -31
- package/dist/commands/auth.js +0 -428
- package/dist/commands/auth.js.map +0 -1
- package/dist/commands/billing.d.ts +0 -2
- package/dist/commands/billing.js +0 -250
- package/dist/commands/billing.js.map +0 -1
- package/dist/commands/brain.d.ts +0 -2
- package/dist/commands/brain.js +0 -1300
- package/dist/commands/brain.js.map +0 -1
- package/dist/commands/browser.d.ts +0 -2
- package/dist/commands/browser.js +0 -378
- package/dist/commands/browser.js.map +0 -1
- package/dist/commands/business.d.ts +0 -2
- package/dist/commands/business.js +0 -566
- package/dist/commands/business.js.map +0 -1
- package/dist/commands/cards.d.ts +0 -2
- package/dist/commands/cards.js +0 -419
- package/dist/commands/cards.js.map +0 -1
- package/dist/commands/ceo.d.ts +0 -2
- package/dist/commands/ceo.js +0 -369
- package/dist/commands/ceo.js.map +0 -1
- package/dist/commands/clone.d.ts +0 -2
- package/dist/commands/clone.js +0 -203
- package/dist/commands/clone.js.map +0 -1
- package/dist/commands/companies.d.ts +0 -10
- package/dist/commands/companies.js +0 -283
- package/dist/commands/companies.js.map +0 -1
- package/dist/commands/company-data.d.ts +0 -2
- package/dist/commands/company-data.js +0 -168
- package/dist/commands/company-data.js.map +0 -1
- package/dist/commands/compute.d.ts +0 -2
- package/dist/commands/compute.js +0 -498
- package/dist/commands/compute.js.map +0 -1
- package/dist/commands/config.d.ts +0 -2
- package/dist/commands/config.js +0 -36
- package/dist/commands/config.js.map +0 -1
- package/dist/commands/connections.d.ts +0 -8
- package/dist/commands/connections.js +0 -137
- package/dist/commands/connections.js.map +0 -1
- package/dist/commands/cron-jobs.d.ts +0 -2
- package/dist/commands/cron-jobs.js +0 -245
- package/dist/commands/cron-jobs.js.map +0 -1
- package/dist/commands/domains.d.ts +0 -2
- package/dist/commands/domains.js +0 -474
- package/dist/commands/domains.js.map +0 -1
- package/dist/commands/ecommerce.d.ts +0 -2
- package/dist/commands/ecommerce.js +0 -277
- package/dist/commands/ecommerce.js.map +0 -1
- package/dist/commands/email.d.ts +0 -2
- package/dist/commands/email.js +0 -336
- package/dist/commands/email.js.map +0 -1
- package/dist/commands/employees.d.ts +0 -2
- package/dist/commands/employees.js +0 -190
- package/dist/commands/employees.js.map +0 -1
- package/dist/commands/env.d.ts +0 -7
- package/dist/commands/env.js +0 -112
- package/dist/commands/env.js.map +0 -1
- package/dist/commands/formation.d.ts +0 -2
- package/dist/commands/formation.js +0 -273
- package/dist/commands/formation.js.map +0 -1
- package/dist/commands/identity.d.ts +0 -2
- package/dist/commands/identity.js +0 -110
- package/dist/commands/identity.js.map +0 -1
- package/dist/commands/images.d.ts +0 -2
- package/dist/commands/images.js +0 -371
- package/dist/commands/images.js.map +0 -1
- package/dist/commands/init.d.ts +0 -5
- package/dist/commands/init.js +0 -43
- package/dist/commands/init.js.map +0 -1
- package/dist/commands/jobs.d.ts +0 -2
- package/dist/commands/jobs.js +0 -144
- package/dist/commands/jobs.js.map +0 -1
- package/dist/commands/keys.d.ts +0 -2
- package/dist/commands/keys.js +0 -156
- package/dist/commands/keys.js.map +0 -1
- package/dist/commands/legacy-auth.d.ts +0 -27
- package/dist/commands/legacy-auth.js +0 -64
- package/dist/commands/legacy-auth.js.map +0 -1
- package/dist/commands/llm.d.ts +0 -2
- package/dist/commands/llm.js +0 -125
- package/dist/commands/llm.js.map +0 -1
- package/dist/commands/login.d.ts +0 -2
- package/dist/commands/login.js +0 -65
- package/dist/commands/login.js.map +0 -1
- package/dist/commands/logout.d.ts +0 -7
- package/dist/commands/logout.js +0 -55
- package/dist/commands/logout.js.map +0 -1
- package/dist/commands/logs.d.ts +0 -2
- package/dist/commands/logs.js +0 -42
- package/dist/commands/logs.js.map +0 -1
- package/dist/commands/loops.d.ts +0 -2
- package/dist/commands/loops.js +0 -260
- package/dist/commands/loops.js.map +0 -1
- package/dist/commands/media.d.ts +0 -2
- package/dist/commands/media.js +0 -183
- package/dist/commands/media.js.map +0 -1
- package/dist/commands/memory.d.ts +0 -2
- package/dist/commands/memory.js +0 -151
- package/dist/commands/memory.js.map +0 -1
- package/dist/commands/mobile.d.ts +0 -4
- package/dist/commands/mobile.js +0 -382
- package/dist/commands/mobile.js.map +0 -1
- package/dist/commands/module.d.ts +0 -8
- package/dist/commands/module.js +0 -48
- package/dist/commands/module.js.map +0 -1
- package/dist/commands/objectives.d.ts +0 -2
- package/dist/commands/objectives.js +0 -243
- package/dist/commands/objectives.js.map +0 -1
- package/dist/commands/payments.d.ts +0 -2
- package/dist/commands/payments.js +0 -131
- package/dist/commands/payments.js.map +0 -1
- package/dist/commands/people.d.ts +0 -2
- package/dist/commands/people.js +0 -197
- package/dist/commands/people.js.map +0 -1
- package/dist/commands/phone.d.ts +0 -2
- package/dist/commands/phone.js +0 -289
- package/dist/commands/phone.js.map +0 -1
- package/dist/commands/projects.d.ts +0 -13
- package/dist/commands/projects.js +0 -220
- package/dist/commands/projects.js.map +0 -1
- package/dist/commands/queue.d.ts +0 -2
- package/dist/commands/queue.js +0 -121
- package/dist/commands/queue.js.map +0 -1
- package/dist/commands/register.d.ts +0 -2
- package/dist/commands/register.js +0 -88
- package/dist/commands/register.js.map +0 -1
- package/dist/commands/report.d.ts +0 -17
- package/dist/commands/report.js +0 -109
- package/dist/commands/report.js.map +0 -1
- package/dist/commands/sandbox.d.ts +0 -2
- package/dist/commands/sandbox.js +0 -558
- package/dist/commands/sandbox.js.map +0 -1
- package/dist/commands/search.d.ts +0 -2
- package/dist/commands/search.js +0 -223
- package/dist/commands/search.js.map +0 -1
- package/dist/commands/seo.d.ts +0 -2
- package/dist/commands/seo.js +0 -528
- package/dist/commands/seo.js.map +0 -1
- package/dist/commands/sessions.d.ts +0 -6
- package/dist/commands/sessions.js +0 -109
- package/dist/commands/sessions.js.map +0 -1
- package/dist/commands/social-data.d.ts +0 -2
- package/dist/commands/social-data.js +0 -245
- package/dist/commands/social-data.js.map +0 -1
- package/dist/commands/social.d.ts +0 -2
- package/dist/commands/social.js +0 -407
- package/dist/commands/social.js.map +0 -1
- package/dist/commands/status.d.ts +0 -2
- package/dist/commands/status.js +0 -79
- package/dist/commands/status.js.map +0 -1
- package/dist/commands/support.d.ts +0 -2
- package/dist/commands/support.js +0 -134
- package/dist/commands/support.js.map +0 -1
- package/dist/commands/tasks.d.ts +0 -2
- package/dist/commands/tasks.js +0 -409
- package/dist/commands/tasks.js.map +0 -1
- package/dist/commands/teams.d.ts +0 -69
- package/dist/commands/teams.js +0 -503
- package/dist/commands/teams.js.map +0 -1
- package/dist/commands/trading.d.ts +0 -2
- package/dist/commands/trading.js +0 -333
- package/dist/commands/trading.js.map +0 -1
- package/dist/commands/up.d.ts +0 -551
- package/dist/commands/up.js +0 -1149
- package/dist/commands/up.js.map +0 -1
- package/dist/commands/usage.d.ts +0 -2
- package/dist/commands/usage.js +0 -73
- package/dist/commands/usage.js.map +0 -1
- package/dist/commands/use.d.ts +0 -12
- package/dist/commands/use.js +0 -96
- package/dist/commands/use.js.map +0 -1
- package/dist/commands/users.d.ts +0 -10
- package/dist/commands/users.js +0 -82
- package/dist/commands/users.js.map +0 -1
- package/dist/commands/vault.d.ts +0 -2
- package/dist/commands/vault.js +0 -101
- package/dist/commands/vault.js.map +0 -1
- package/dist/commands/verification.d.ts +0 -2
- package/dist/commands/verification.js +0 -152
- package/dist/commands/verification.js.map +0 -1
- package/dist/commands/verify-email.d.ts +0 -19
- package/dist/commands/verify-email.js +0 -130
- package/dist/commands/verify-email.js.map +0 -1
- package/dist/commands/video.d.ts +0 -2
- package/dist/commands/video.js +0 -417
- package/dist/commands/video.js.map +0 -1
- package/dist/commands/voice.d.ts +0 -2
- package/dist/commands/voice.js +0 -516
- package/dist/commands/voice.js.map +0 -1
- package/dist/commands/wallet.d.ts +0 -2
- package/dist/commands/wallet.js +0 -244
- package/dist/commands/wallet.js.map +0 -1
- package/dist/commands/webhooks.d.ts +0 -13
- package/dist/commands/webhooks.js +0 -119
- package/dist/commands/webhooks.js.map +0 -1
- package/dist/commands/whoami.d.ts +0 -2
- package/dist/commands/whoami.js +0 -53
- package/dist/commands/whoami.js.map +0 -1
- package/dist/config.d.ts +0 -42
- package/dist/config.js +0 -83
- package/dist/config.js.map +0 -1
- package/dist/index.d.ts +0 -3
- package/dist/index.js.map +0 -1
- package/dist/lib/brain-select.d.ts +0 -193
- package/dist/lib/brain-select.js +0 -403
- package/dist/lib/brain-select.js.map +0 -1
- package/dist/lib/cli-validation.d.ts +0 -12
- package/dist/lib/cli-validation.js +0 -46
- package/dist/lib/cli-validation.js.map +0 -1
- package/dist/lib/config-errors.d.ts +0 -4
- package/dist/lib/config-errors.js +0 -13
- package/dist/lib/config-errors.js.map +0 -1
- package/dist/lib/deprecation.d.ts +0 -158
- package/dist/lib/deprecation.js +0 -140
- package/dist/lib/deprecation.js.map +0 -1
- package/dist/lib/duration.d.ts +0 -8
- package/dist/lib/duration.js +0 -11
- package/dist/lib/duration.js.map +0 -1
- package/dist/lib/http-response.d.ts +0 -11
- package/dist/lib/http-response.js +0 -96
- package/dist/lib/http-response.js.map +0 -1
- package/dist/lib/llm-paywall.d.ts +0 -82
- package/dist/lib/llm-paywall.js +0 -231
- package/dist/lib/llm-paywall.js.map +0 -1
- package/dist/lib/pricing.d.ts +0 -132
- package/dist/lib/pricing.js +0 -148
- package/dist/lib/pricing.js.map +0 -1
- package/dist/lib/starter-config.d.ts +0 -13
- package/dist/lib/starter-config.js +0 -71
- package/dist/lib/starter-config.js.map +0 -1
- package/dist/lib/stream-frames.d.ts +0 -114
- package/dist/lib/stream-frames.js +0 -169
- package/dist/lib/stream-frames.js.map +0 -1
- package/dist/lib/teams-catalog.d.ts +0 -141
- package/dist/lib/teams-catalog.js +0 -841
- package/dist/lib/teams-catalog.js.map +0 -1
- package/dist/lib/unknown-command.d.ts +0 -71
- package/dist/lib/unknown-command.js +0 -132
- package/dist/lib/unknown-command.js.map +0 -1
- package/dist/lib/version-check.d.ts +0 -26
- package/dist/lib/version-check.js +0 -21
- package/dist/lib/version-check.js.map +0 -1
- package/dist/output.d.ts +0 -246
- package/dist/output.js +0 -539
- package/dist/output.js.map +0 -1
- package/dist/prompt.d.ts +0 -17
- package/dist/prompt.js +0 -70
- package/dist/prompt.js.map +0 -1
- package/dist/version.d.ts +0 -2
- package/dist/version.js +0 -14
- package/dist/version.js.map +0 -1
package/dist/commands/teams.js
DELETED
|
@@ -1,503 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* `naive teams` — the durable-runtime surface.
|
|
3
|
-
*
|
|
4
|
-
* This file declares NO subcommand. It walks `lib/teams-catalog.ts` and builds
|
|
5
|
-
* one commander command per row, so the 29 subcommands, their flags, their REST
|
|
6
|
-
* paths and their ActionIds all come from a single array (06 §1.4). Adding a
|
|
7
|
-
* command means adding a row.
|
|
8
|
-
*
|
|
9
|
-
* ── WHAT IS AND IS NOT TRUE ABOUT THIS SURFACE TODAY ────────────────────────
|
|
10
|
-
*
|
|
11
|
-
* 🔴 THIS HEADER USED TO SAY THE OPPOSITE OF WHAT IS TRUE, and it said it three
|
|
12
|
-
* times — here, in `runtimeSurfaceMissing` below, and in the group's `--help`.
|
|
13
|
-
* The claim was: *"there is no `app.use("/v1/teams", …)` … every command below
|
|
14
|
-
* currently reaches the API's catch-all and gets a 404."*
|
|
15
|
-
*
|
|
16
|
-
* MEASURED against `packages/api/src/server.ts` in this tree:
|
|
17
|
-
*
|
|
18
|
-
* packages/api/src/server.ts:671
|
|
19
|
-
* app.use("/v1/teams", requireSessionOrAuth, idempotency, teamsRouter);
|
|
20
|
-
*
|
|
21
|
-
* and a booted route table counts **30 live `/v1/teams/*` routes**. The mount is
|
|
22
|
-
* real and has been for the whole life of this file. Every subcommand below
|
|
23
|
-
* reaches a handler.
|
|
24
|
-
*
|
|
25
|
-
* ⚠ AND THE EVIDENCE THAT LOOKS LIKE IT CONFIRMS THIS DOES NOT. `GET /v1/teams`
|
|
26
|
-
* against a deployed API answers `401`, and so does `GET /v1/nope`, because
|
|
27
|
-
* `server.ts:712` puts `requireAuth` on the whole `/v1` prefix ahead of the 404
|
|
28
|
-
* catch-all. A 401 says nothing about whether a route exists. The booted route
|
|
29
|
-
* table is the evidence; a status code from the outside is not.
|
|
30
|
-
*
|
|
31
|
-
* ── WHAT IS ACTUALLY TRUE: IT DEPENDS ON THE TENANT'S RUNTIME ───────────────
|
|
32
|
-
*
|
|
33
|
-
* A tenant is on the durable runtime or on the frozen legacy one, and which is a
|
|
34
|
-
* single column (`company_containers.sidecar_url`). Of these 29 subcommands,
|
|
35
|
-
* **22 return real rows for a durable tenant and 13 for a hermes tenant**; the
|
|
36
|
-
* rest answer `501 not_configured` naming what is missing FOR THAT RUNTIME.
|
|
37
|
-
* `naive teams plan` reports which runtime a given tenant is on.
|
|
38
|
-
*
|
|
39
|
-
* `runtimeSurfaceMissing` below is kept, and it is no longer about this surface:
|
|
40
|
-
* it detects the API's unmounted-path catch-all, which is what a CLI built
|
|
41
|
-
* against a NEWER API than the one it is pointed at will hit. That is a real
|
|
42
|
-
* failure mode with a real remedy, and it is distinguishable from a genuine
|
|
43
|
-
* not-found — the catch-all answers `resource_not_found` with the literal
|
|
44
|
-
* message `Cannot <METHOD> <path>` (server.ts:668), which no route handler
|
|
45
|
-
* produces.
|
|
46
|
-
*/
|
|
47
|
-
import { Command } from "commander";
|
|
48
|
-
import { readFileSync } from "node:fs";
|
|
49
|
-
import { activeUserId, apiRequest, handleApiError, handlePendingApproval } from "../client.js";
|
|
50
|
-
import { loadConfig, getApiKey } from "../config.js";
|
|
51
|
-
import { agentError, agentOutputExit, isInteractive } from "../output.js";
|
|
52
|
-
import { TEAM_OPS, TeamOpError, assertSelectors, buildBody, buildPath, buildQuery, } from "../lib/teams-catalog.js";
|
|
53
|
-
import { highestSeq, parseSse, redactFrame, unverifiedExitCode, watchExitCode } from "../lib/stream-frames.js";
|
|
54
|
-
/* -------------------------------------------------------------------------- */
|
|
55
|
-
/* the tuple */
|
|
56
|
-
/* -------------------------------------------------------------------------- */
|
|
57
|
-
/**
|
|
58
|
-
* `--tenant` is required on every subcommand except `list`, and there is NO
|
|
59
|
-
* default. The addressing tuple is `(company, tenant, team)`; a command that
|
|
60
|
-
* guesses the tenant is a command that acts on the wrong tenant exactly once.
|
|
61
|
-
*
|
|
62
|
-
* `@self` is the one shorthand, and it resolves to the operator's own selected
|
|
63
|
-
* subject rather than to a server-side default — if nothing is selected it is an
|
|
64
|
-
* error, not `"default"`.
|
|
65
|
-
*/
|
|
66
|
-
export function resolveTenant(raw) {
|
|
67
|
-
if (!raw) {
|
|
68
|
-
throw new TeamOpError("--tenant is required. Pass a tenant-user id, or `--tenant @self` for your own. There is no default.");
|
|
69
|
-
}
|
|
70
|
-
if (raw !== "@self")
|
|
71
|
-
return raw;
|
|
72
|
-
const self = activeUserId();
|
|
73
|
-
if (!self) {
|
|
74
|
-
throw new TeamOpError("--tenant @self needs a selected subject. Run `naive use <tenant-user-id>`, or pass the id explicitly.");
|
|
75
|
-
}
|
|
76
|
-
return self;
|
|
77
|
-
}
|
|
78
|
-
/** `--brief <file|->` and `--receipt <file|->`. Prose on argv is mangled by every
|
|
79
|
-
* shell, and `-` is what lets a coding agent pipe. */
|
|
80
|
-
function readFileOrStdin(value) {
|
|
81
|
-
return value === "-" ? readFileSync(0, "utf8") : readFileSync(value, "utf8");
|
|
82
|
-
}
|
|
83
|
-
const FILE_VALUED_FLAGS = new Set(["brief", "receipt"]);
|
|
84
|
-
/* -------------------------------------------------------------------------- */
|
|
85
|
-
/* the honest 404 */
|
|
86
|
-
/* -------------------------------------------------------------------------- */
|
|
87
|
-
/**
|
|
88
|
-
* True when the response is the API's UNMOUNTED-PATH catch-all rather than a
|
|
89
|
-
* route that looked for something and did not find it.
|
|
90
|
-
*/
|
|
91
|
-
export function runtimeSurfaceMissing(status, data) {
|
|
92
|
-
if (status !== 404)
|
|
93
|
-
return false;
|
|
94
|
-
const code = data?.error;
|
|
95
|
-
return code?.code === "resource_not_found" && typeof code.message === "string" && /^Cannot [A-Z]+ \//.test(code.message);
|
|
96
|
-
}
|
|
97
|
-
/**
|
|
98
|
-
* The API you are pointed at is OLDER than this CLI.
|
|
99
|
-
*
|
|
100
|
-
* This used to say "the durable-runtime REST surface is not mounted", full stop,
|
|
101
|
-
* which was false against any API built from this tree. It is true against an
|
|
102
|
-
* API that predates the mount — a stale staging deploy, a pinned image, a
|
|
103
|
-
* developer's older checkout — and that is a real thing to hit and a different
|
|
104
|
-
* thing to fix. The remedy is the API's version, not the team name, which is why
|
|
105
|
-
* this exists at all: the catch-all's own `resource_not_found` would send an
|
|
106
|
-
* operator to check a team that is fine.
|
|
107
|
-
*/
|
|
108
|
-
function refuseUnmounted(op, path) {
|
|
109
|
-
agentError({
|
|
110
|
-
action: `teams.${op.cli}`,
|
|
111
|
-
error: {
|
|
112
|
-
code: "resource_not_found",
|
|
113
|
-
message: `${op.method} ${path} is not mounted on the API this CLI is pointed at. ` +
|
|
114
|
-
"This is not a missing team — the route itself is absent, which means the API is older than this CLI.",
|
|
115
|
-
hint: `Expected ActionId \`${op.action}\`. \`/v1/teams\` is mounted by packages/api server.ts; an API that 404s the whole prefix predates it.`,
|
|
116
|
-
},
|
|
117
|
-
recovery_steps: [
|
|
118
|
-
{ command: "naive status", description: "Check which API you are pointed at, and its version" },
|
|
119
|
-
{ command: "naive teams list", description: "The same surface — every subcommand fails the same way against an API without the mount" },
|
|
120
|
-
{ command: "naive tasks list", description: "The legacy orchestration runtime, which is frozen and answers on every build" },
|
|
121
|
-
],
|
|
122
|
-
});
|
|
123
|
-
throw new Error("unreachable"); // agentError exits
|
|
124
|
-
}
|
|
125
|
-
/* -------------------------------------------------------------------------- */
|
|
126
|
-
/* the generic runner */
|
|
127
|
-
/* -------------------------------------------------------------------------- */
|
|
128
|
-
function nextSteps(op, team, tenant) {
|
|
129
|
-
const suffix = team && tenant ? ` ${team} --tenant ${tenant}` : "";
|
|
130
|
-
const steps = [
|
|
131
|
-
{ command: `naive teams board${suffix}`, description: "See the board for this team" },
|
|
132
|
-
{ command: `naive teams runs${suffix}`, description: "List runs" },
|
|
133
|
-
{ command: `naive teams approvals${suffix}`, description: "See what this team is waiting on" },
|
|
134
|
-
];
|
|
135
|
-
return steps.filter((s) => !s.command.startsWith(`naive teams ${op.cli} `));
|
|
136
|
-
}
|
|
137
|
-
async function runOp(op, positionals, opts) {
|
|
138
|
-
const args = {};
|
|
139
|
-
op.args.forEach((a, i) => {
|
|
140
|
-
args[a.name] = positionals[i];
|
|
141
|
-
});
|
|
142
|
-
const tenant = op.tenant ? resolveTenant(opts.tenant) : undefined;
|
|
143
|
-
// Path values: {team} and {tenant} plus any arg or flag declared `in: "path"`.
|
|
144
|
-
const pathValues = { tenant };
|
|
145
|
-
for (const a of op.args) {
|
|
146
|
-
if (a.in === "path")
|
|
147
|
-
pathValues[a.name] = args[a.name];
|
|
148
|
-
}
|
|
149
|
-
for (const f of op.flags) {
|
|
150
|
-
if (f.in === "path")
|
|
151
|
-
pathValues[f.key] = opts[f.key];
|
|
152
|
-
}
|
|
153
|
-
// `say` defaults its channel rather than demanding one — the default session is
|
|
154
|
-
// the one every team has.
|
|
155
|
-
if (op.path.includes("{channel}") && !pathValues.channel)
|
|
156
|
-
pathValues.channel = "main";
|
|
157
|
-
// File-valued flags are read before the body is built, so the body carries the
|
|
158
|
-
// prose and not the path to it.
|
|
159
|
-
const resolved = { ...opts };
|
|
160
|
-
for (const f of op.flags) {
|
|
161
|
-
if (f.in === "body" && FILE_VALUED_FLAGS.has(f.key) && typeof opts[f.key] === "string") {
|
|
162
|
-
resolved[f.key] = readFileOrStdin(opts[f.key]);
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
const path = buildPath(op, pathValues);
|
|
166
|
-
const query = buildQuery(op, resolved);
|
|
167
|
-
// Refuse an ambiguous or absent choice here, not at the server: `--allow --deny`
|
|
168
|
-
// would otherwise be decided by flag order in the catalog.
|
|
169
|
-
assertSelectors(op, resolved);
|
|
170
|
-
const body = buildBody(op, args, resolved);
|
|
171
|
-
const idempotencyKey = resolved.idempotencyKey;
|
|
172
|
-
const headers = typeof idempotencyKey === "string" ? { "Idempotency-Key": idempotencyKey } : undefined;
|
|
173
|
-
const resp = await apiRequest(op.method, `${path}${query}`, body, { ...(headers && { headers }) });
|
|
174
|
-
if (runtimeSurfaceMissing(resp.status, resp.data))
|
|
175
|
-
refuseUnmounted(op, path);
|
|
176
|
-
handleApiError(`teams.${op.cli}`, resp);
|
|
177
|
-
if (handlePendingApproval(`teams.${op.cli}`, resp))
|
|
178
|
-
return;
|
|
179
|
-
// Exit 3 — opt-in, and only for the two ops that declare the flag.
|
|
180
|
-
//
|
|
181
|
-
// 🔴 THE BANNER THAT USED TO BE HERE IS GONE, AND ITS DELETION IS THE FEATURE.
|
|
182
|
-
//
|
|
183
|
-
// It said: "--fail-on-unverified cannot fire on this tenant", because on the
|
|
184
|
-
// durable lane `unverified` was structurally unreachable — that board came
|
|
185
|
-
// straight from the runtime, whose six states (`todo ready doing review done
|
|
186
|
-
// blocked`) contain no such value, and `tasks_mirror` (the only thing that
|
|
187
|
-
// writes it) was never consulted. A gate that cannot fail is worse than no
|
|
188
|
-
// gate, so it announced itself rather than letting a CI job read exit 0 as
|
|
189
|
-
// "attested".
|
|
190
|
-
//
|
|
191
|
-
// The verification join fixed the cause rather than the symptom: `durableCard`
|
|
192
|
-
// now joins `tasks_mirror` and lets naive's verdict decide the terminal column,
|
|
193
|
-
// so a durable tenant's board reports `unverified` exactly when naive recorded
|
|
194
|
-
// one. The flag fires on both lanes, the announcement would now be false, and a
|
|
195
|
-
// FALSE warning teaches the same lesson a missing one does. It is deleted, and
|
|
196
|
-
// the test that asserted it is flipped to assert the exit code instead — so the
|
|
197
|
-
// deletion is proven rather than assumed.
|
|
198
|
-
const failOnUnverified = resolved.failOnUnverified === true;
|
|
199
|
-
const cards = extractCards(resp.data);
|
|
200
|
-
let exitCode = unverifiedExitCode(cards, failOnUnverified);
|
|
201
|
-
const hints = [];
|
|
202
|
-
if (op.fenced)
|
|
203
|
-
hints.push(`\`${op.cli}\` passes through the write fence (ActionId ${op.action}).`);
|
|
204
|
-
if (typeof idempotencyKey === "string") {
|
|
205
|
-
hints.push("idempotency: best-effort (single-replica) — see `naive teams plan`.");
|
|
206
|
-
}
|
|
207
|
-
if (exitCode === 3) {
|
|
208
|
-
// NAMED, because the three reasons need different actions from whoever reads
|
|
209
|
-
// the log. `unverified` is a card nothing adjudicated; the other two are
|
|
210
|
-
// cards the two boards actively disagree about, which is an operator's
|
|
211
|
-
// problem and not a retry's. A single sentence covering all three would send
|
|
212
|
-
// the reader to the wrong one twice out of three times.
|
|
213
|
-
const disputed = cards.filter((c) => c.verdict_delivery_failed != null || c.boards_disagree != null).length;
|
|
214
|
-
const unattested = cards.filter((c) => c.status === "unverified").length;
|
|
215
|
-
hints.push([
|
|
216
|
-
unattested > 0 && `${unattested} card(s) are \`unverified\` — a THIRD terminal state, not a success.`,
|
|
217
|
-
disputed > 0 &&
|
|
218
|
-
`${disputed} card(s) carry a two-board DISAGREEMENT (\`verdict_delivery_failed\` / \`boards_disagree\`): ` +
|
|
219
|
-
"naive and the runtime hold different terminals for them, so their verification did not conclude. " +
|
|
220
|
-
"Read those fields on the rows — nothing retries this.",
|
|
221
|
-
"Exiting 3.",
|
|
222
|
-
].filter(Boolean).join(" "));
|
|
223
|
-
}
|
|
224
|
-
// Exit 2 — `plan --detailed-exitcode`, and only there. Reusing exit 1 for
|
|
225
|
-
// "changes exist" is indistinguishable from a real error, which is exactly why
|
|
226
|
-
// terraform invented the flag.
|
|
227
|
-
if (resolved.detailedExitcode === true && planHasChanges(resp.data)) {
|
|
228
|
-
exitCode = 2;
|
|
229
|
-
hints.push("A diff exists. Exiting 2 (--detailed-exitcode).");
|
|
230
|
-
}
|
|
231
|
-
agentOutputExit({
|
|
232
|
-
action: `teams.${op.cli}`,
|
|
233
|
-
result: resp.data,
|
|
234
|
-
next_steps: nextSteps(op, positionals[0], tenant),
|
|
235
|
-
...(hints.length > 0 && { hints }),
|
|
236
|
-
...(exitCode !== 0 && { exitCode }),
|
|
237
|
-
});
|
|
238
|
-
}
|
|
239
|
-
/**
|
|
240
|
-
* True when a plan body reports a non-empty `changes`. Absent or unreadable is
|
|
241
|
-
* FALSE — `--detailed-exitcode` must not report a diff it could not see, because
|
|
242
|
-
* a caller uses exit 2 to decide whether to run an apply.
|
|
243
|
-
*/
|
|
244
|
-
export function planHasChanges(data) {
|
|
245
|
-
const changes = data?.changes
|
|
246
|
-
?? data?.result?.changes;
|
|
247
|
-
return Array.isArray(changes) && changes.length > 0;
|
|
248
|
-
}
|
|
249
|
-
/**
|
|
250
|
-
* Board rows, from the key this API puts them under. Returns [] when the shape is
|
|
251
|
-
* unrecognised — `--fail-on-unverified` must not invent a pass OR a failure from a
|
|
252
|
-
* body it could not read.
|
|
253
|
-
*
|
|
254
|
-
* 🔴 THE KEY IS `items`, AND READING ANY OTHER ONE IS HOW THIS GATE DIED.
|
|
255
|
-
*
|
|
256
|
-
* This function used to look for `cards` and `tasks` and not for `items`. Every
|
|
257
|
-
* `/v1/teams` response paginates under `items` — both board lanes
|
|
258
|
-
* (`routes/teams.ts` durable `res.json({ provider, items, … })` and hermes
|
|
259
|
-
* `res.json({ items: collected, … })`), and a grep of that router for `cards:` or
|
|
260
|
-
* `tasks:` as a response key finds nothing. So the extractor matched nothing on
|
|
261
|
-
* every real answer, `unverifiedExitCode([], true)` returned 0, and
|
|
262
|
-
* `naive teams tasks --fail-on-unverified` exited 0 on a board full of unverified
|
|
263
|
-
* cards. Measured by running this binary against a server answering each shape:
|
|
264
|
-
*
|
|
265
|
-
* {items:[{status:"unverified"}]} -> exit 0 (both lanes)
|
|
266
|
-
* {provider:"durable",items:[{status:"unverified"}]}-> exit 0
|
|
267
|
-
* {cards:[{status:"unverified"}]} -> exit 3
|
|
268
|
-
*
|
|
269
|
-
* The one shape that fired is the one the test suite invented. A CI gate that
|
|
270
|
-
* cannot fail is worse than no gate, so the two speculative keys are gone rather
|
|
271
|
-
* than kept as fallbacks: a tolerated second spelling is where the next reader
|
|
272
|
-
* hides. `items` is the wire, and a shape this cannot read stays an explicit [].
|
|
273
|
-
*/
|
|
274
|
-
function extractCards(data) {
|
|
275
|
-
if (Array.isArray(data))
|
|
276
|
-
return data;
|
|
277
|
-
const d = data;
|
|
278
|
-
if (Array.isArray(d?.items))
|
|
279
|
-
return d.items;
|
|
280
|
-
// `GET …/board/{card}` spreads ONE card at the top level, so `naive teams task`
|
|
281
|
-
// arrives here as an object with its own `status`. That branch was always live.
|
|
282
|
-
if (typeof d?.status === "string")
|
|
283
|
-
return [d];
|
|
284
|
-
return [];
|
|
285
|
-
}
|
|
286
|
-
/*
|
|
287
|
-
* `providerOf` lived here and is deleted with the banner it fed. It read
|
|
288
|
-
* `provider` off a board answer solely to decide whether to warn that
|
|
289
|
-
* `--fail-on-unverified` could not fire on the durable lane. It can, now — the
|
|
290
|
-
* board joins `tasks_mirror` and reports naive's verdict — so the only caller is
|
|
291
|
-
* gone and the helper goes with it rather than sitting as a reader nobody reads.
|
|
292
|
-
* `--fail-on-unverified` is DELIBERATELY LANE-BLIND: the gate asks one question
|
|
293
|
-
* ("is any card unverified?") of one field, and a CLI that branched on which
|
|
294
|
-
* runtime answered would be a second place the two lanes could diverge.
|
|
295
|
-
*/
|
|
296
|
-
/* -------------------------------------------------------------------------- */
|
|
297
|
-
/* watch — the one op that reads a stream */
|
|
298
|
-
/* -------------------------------------------------------------------------- */
|
|
299
|
-
async function runWatch(op, positionals, opts) {
|
|
300
|
-
const tenant = resolveTenant(opts.tenant);
|
|
301
|
-
const showArgs = opts.showArgs === true;
|
|
302
|
-
if (showArgs && !isInteractive()) {
|
|
303
|
-
agentError({
|
|
304
|
-
action: "teams.watch",
|
|
305
|
-
error: {
|
|
306
|
-
code: "invalid_input",
|
|
307
|
-
message: "--show-args prints raw tool arguments and requires an interactive terminal. " +
|
|
308
|
-
"Without it the transcript prints args_digest, which correlates frames without leaking a value nobody audited.",
|
|
309
|
-
},
|
|
310
|
-
recovery_steps: [
|
|
311
|
-
{ command: "naive teams watch <team> --tenant <tu> --run <id>", description: "Watch with arguments redacted" },
|
|
312
|
-
],
|
|
313
|
-
});
|
|
314
|
-
return;
|
|
315
|
-
}
|
|
316
|
-
const path = buildPath(op, { team: positionals[0], tenant, run: opts.run });
|
|
317
|
-
const config = loadConfig();
|
|
318
|
-
const headers = {
|
|
319
|
-
Authorization: `Bearer ${getApiKey()}`,
|
|
320
|
-
Accept: "text/event-stream",
|
|
321
|
-
"X-Naive-User-Id": tenant,
|
|
322
|
-
};
|
|
323
|
-
// `--cursor <seq>` is a POSITION, not a time. It becomes Last-Event-ID, which
|
|
324
|
-
// the server replays from strictly (`sequence >`), so a resume loses nothing
|
|
325
|
-
// and duplicates nothing.
|
|
326
|
-
if (opts.cursor !== undefined)
|
|
327
|
-
headers["Last-Event-ID"] = String(opts.cursor);
|
|
328
|
-
let response;
|
|
329
|
-
try {
|
|
330
|
-
response = await fetch(`${config.base_url}${path}`, { method: "GET", headers });
|
|
331
|
-
}
|
|
332
|
-
catch (error) {
|
|
333
|
-
agentError({
|
|
334
|
-
action: "teams.watch",
|
|
335
|
-
error: { code: "upstream_error", message: error instanceof Error ? error.message : String(error) },
|
|
336
|
-
recovery_steps: [{ command: "naive status", description: "Check API connectivity" }],
|
|
337
|
-
});
|
|
338
|
-
return;
|
|
339
|
-
}
|
|
340
|
-
if (!response.ok || !response.body) {
|
|
341
|
-
let data = {};
|
|
342
|
-
try {
|
|
343
|
-
data = JSON.parse(await response.text());
|
|
344
|
-
}
|
|
345
|
-
catch {
|
|
346
|
-
/* a non-JSON body is handled by the generic branch below */
|
|
347
|
-
}
|
|
348
|
-
if (runtimeSurfaceMissing(response.status, data))
|
|
349
|
-
refuseUnmounted(op, path);
|
|
350
|
-
handleApiError("teams.watch", { status: response.status, data });
|
|
351
|
-
return;
|
|
352
|
-
}
|
|
353
|
-
const decoder = new TextDecoder();
|
|
354
|
-
let buffer = "";
|
|
355
|
-
let cursor = opts.cursor === undefined ? undefined : Number(opts.cursor);
|
|
356
|
-
let finalStatus;
|
|
357
|
-
for await (const chunk of response.body) {
|
|
358
|
-
buffer += decoder.decode(chunk, { stream: true });
|
|
359
|
-
const { events, rest } = parseSse(buffer);
|
|
360
|
-
buffer = rest;
|
|
361
|
-
for (const ev of events) {
|
|
362
|
-
let frame;
|
|
363
|
-
try {
|
|
364
|
-
frame = JSON.parse(ev.data);
|
|
365
|
-
}
|
|
366
|
-
catch {
|
|
367
|
-
continue; // a keep-alive or a comment; not a frame
|
|
368
|
-
}
|
|
369
|
-
cursor = highestSeq(cursor, frame);
|
|
370
|
-
const f = frame;
|
|
371
|
-
if (typeof f.status === "string")
|
|
372
|
-
finalStatus = f.status;
|
|
373
|
-
// NDJSON: one object per line. Never an array, never `[DONE]`.
|
|
374
|
-
process.stdout.write(`${JSON.stringify(redactFrame(frame, { showArgs }))}\n`);
|
|
375
|
-
if (f.type === "stream.end") {
|
|
376
|
-
finalStatus = f.status ?? finalStatus;
|
|
377
|
-
// THE ONE THING `--follow` DECIDES. Default: this run is over, stop.
|
|
378
|
-
// With `--follow`: keep the connection open past the terminal frame, so
|
|
379
|
-
// a caller watching a card that opens another run keeps receiving.
|
|
380
|
-
//
|
|
381
|
-
// It used to decide something else entirely — whether to stop after the
|
|
382
|
-
// first NETWORK CHUNK — which is not a property of the run at all.
|
|
383
|
-
if (opts.follow !== true) {
|
|
384
|
-
process.exitCode = watchExitCode(finalStatus, opts.failOnTerminal === true);
|
|
385
|
-
return;
|
|
386
|
-
}
|
|
387
|
-
}
|
|
388
|
-
}
|
|
389
|
-
// NO `break` HERE. The loop body used to end with
|
|
390
|
-
// `if (opts.follow !== true) break;`, which stopped after exactly ONE
|
|
391
|
-
// network chunk — so how much of a run a caller saw was a function of how
|
|
392
|
-
// the server and the network happened to segment the stream, not of what
|
|
393
|
-
// the run produced. The buffered tail (`buffer = rest`) was discarded, and
|
|
394
|
-
// the command still exited 0, so nothing signalled the truncation.
|
|
395
|
-
//
|
|
396
|
-
// Both modes now drain the body to completion. The difference `--follow`
|
|
397
|
-
// makes is what happens at a TERMINAL frame, handled below: without it the
|
|
398
|
-
// command stops at the first `stream.end` (the `return` above); with it the
|
|
399
|
-
// caller has asked to keep watching, so the stream is consumed until the
|
|
400
|
-
// server closes it.
|
|
401
|
-
}
|
|
402
|
-
// The response body ended without a `stream.end` frame. Anything still in
|
|
403
|
-
// `buffer` is a partial frame — an SSE event that never got its blank line —
|
|
404
|
-
// and emitting half a JSON object is worse than dropping it, so it is dropped
|
|
405
|
-
// deliberately rather than by falling out of a loop.
|
|
406
|
-
process.exitCode = watchExitCode(finalStatus, opts.failOnTerminal === true);
|
|
407
|
-
}
|
|
408
|
-
/* -------------------------------------------------------------------------- */
|
|
409
|
-
/* the tree, built from the catalog */
|
|
410
|
-
/* -------------------------------------------------------------------------- */
|
|
411
|
-
export const teamsCmd = new Command("teams")
|
|
412
|
-
.description("The durable runtime — declare a team, send it work, watch it, and decide what it asks for")
|
|
413
|
-
.addHelpText("after", `
|
|
414
|
-
The addressing tuple is (company, tenant, team). --tenant is REQUIRED on every
|
|
415
|
-
subcommand except 'list'; there is no default. Use '--tenant @self' for your own.
|
|
416
|
-
|
|
417
|
-
$ naive teams list
|
|
418
|
-
$ naive teams show support --tenant tu_8f21
|
|
419
|
-
$ naive teams submit support "refund the duplicate charge" --tenant tu_8f21
|
|
420
|
-
$ naive teams board support --tenant tu_8f21
|
|
421
|
-
$ naive teams watch support --tenant tu_8f21 --run run_01J8 --follow
|
|
422
|
-
$ naive teams approvals support --tenant tu_8f21
|
|
423
|
-
$ naive teams decide support apr_01J --allow --because "verified with the customer"
|
|
424
|
-
|
|
425
|
-
Exit codes:
|
|
426
|
-
0 success
|
|
427
|
-
1 error
|
|
428
|
-
2 success, and a diff exists ('plan --detailed-exitcode')
|
|
429
|
-
3 success, and the terminal state is not success
|
|
430
|
-
('tasks|task --fail-on-unverified', 'watch --fail-on-terminal')
|
|
431
|
-
|
|
432
|
-
'unverified' is a THIRD terminal state. A CI script that reads exit 0 as "the
|
|
433
|
-
work is done" would otherwise count an unattested task as a pass.
|
|
434
|
-
|
|
435
|
-
WHAT WORKS DEPENDS ON THE TENANT'S RUNTIME, and every subcommand below is
|
|
436
|
-
mounted. A tenant is on the durable runtime or on the frozen legacy one:
|
|
437
|
-
|
|
438
|
-
22 of these 29 return real rows for a DURABLE tenant
|
|
439
|
-
13 of these 29 return real rows for a HERMES tenant
|
|
440
|
-
|
|
441
|
-
The rest answer 501 and name what is missing FOR THAT RUNTIME - including, for
|
|
442
|
-
a durable tenant, which verb the runtime already implements. Every response
|
|
443
|
-
carries 'provider'; every refusal carries 'error.details.runtime'.
|
|
444
|
-
|
|
445
|
-
$ naive teams plan support --tenant tu_8f21 # which runtime is this tenant on?
|
|
446
|
-
|
|
447
|
-
The frozen legacy commands ('naive tasks', 'naive ceo', ...) keep working on
|
|
448
|
-
both, unchanged.
|
|
449
|
-
`);
|
|
450
|
-
function attach(op) {
|
|
451
|
-
const nameAndArgs = [op.cli, ...op.args.map((a) => a.arg)].join(" ");
|
|
452
|
-
const sub = teamsCmd.command(nameAndArgs).description(op.describe);
|
|
453
|
-
if (op.tenant) {
|
|
454
|
-
sub.requiredOption("--tenant <tenantUserId>", "The tenant user this acts on, or @self. REQUIRED");
|
|
455
|
-
}
|
|
456
|
-
for (const f of op.flags)
|
|
457
|
-
addFlag(sub, f);
|
|
458
|
-
const marks = [];
|
|
459
|
-
if (op.fenced)
|
|
460
|
-
marks.push("fenced");
|
|
461
|
-
if (op.mcp === false)
|
|
462
|
-
marks.push(`never an MCP tool: ${op.because ?? ""}`);
|
|
463
|
-
sub.addHelpText("after", `\n ${op.method} ${op.path}\n ActionId: ${op.action}${marks.length ? `\n ${marks.join(" · ")}` : ""}\n`);
|
|
464
|
-
sub.action(async (...callArgs) => {
|
|
465
|
-
// commander hands (…positionals, options, command).
|
|
466
|
-
const positionals = callArgs.slice(0, op.args.length).map((v) => (v === undefined ? undefined : String(v)));
|
|
467
|
-
const opts = (callArgs[op.args.length] ?? {});
|
|
468
|
-
try {
|
|
469
|
-
if (op.streams)
|
|
470
|
-
await runWatch(op, positionals, opts);
|
|
471
|
-
else
|
|
472
|
-
await runOp(op, positionals, opts);
|
|
473
|
-
}
|
|
474
|
-
catch (error) {
|
|
475
|
-
if (error instanceof TeamOpError) {
|
|
476
|
-
agentError({
|
|
477
|
-
action: `teams.${op.cli}`,
|
|
478
|
-
error: { code: "invalid_input", message: error.message },
|
|
479
|
-
recovery_steps: [{ command: `naive teams ${op.cli} --help`, description: "See required arguments and options" }],
|
|
480
|
-
});
|
|
481
|
-
return;
|
|
482
|
-
}
|
|
483
|
-
throw error;
|
|
484
|
-
}
|
|
485
|
-
});
|
|
486
|
-
}
|
|
487
|
-
function addFlag(sub, f) {
|
|
488
|
-
const parse = f.int ? (v) => Number.parseInt(v, 10) : undefined;
|
|
489
|
-
if (f.required) {
|
|
490
|
-
if (parse)
|
|
491
|
-
sub.requiredOption(f.flag, f.describe, parse);
|
|
492
|
-
else
|
|
493
|
-
sub.requiredOption(f.flag, f.describe);
|
|
494
|
-
return;
|
|
495
|
-
}
|
|
496
|
-
if (parse)
|
|
497
|
-
sub.option(f.flag, f.describe, parse);
|
|
498
|
-
else
|
|
499
|
-
sub.option(f.flag, f.describe);
|
|
500
|
-
}
|
|
501
|
-
for (const op of TEAM_OPS)
|
|
502
|
-
attach(op);
|
|
503
|
-
//# sourceMappingURL=teams.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"teams.js","sourceRoot":"","sources":["../../src/commands/teams.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6CG;AACH,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,cAAc,EAAE,qBAAqB,EAAE,MAAM,cAAc,CAAC;AAC/F,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACrD,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAC1E,OAAO,EACL,QAAQ,EACR,WAAW,EACX,eAAe,EACf,SAAS,EACT,SAAS,EACT,UAAU,GAGX,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,WAAW,EAAE,kBAAkB,EAAE,aAAa,EAAiB,MAAM,yBAAyB,CAAC;AAE9H,gFAAgF;AAChF,iFAAiF;AACjF,gFAAgF;AAEhF;;;;;;;;GAQG;AACH,MA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