@pome-sh/cli 0.21.15 → 0.21.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/build-info.json +3 -3
- package/dist/{checks-OFV75GDL.js → checks-DH7XLBI3.js} +1 -1
- package/dist/{chunk-4MQULI7E.js → chunk-2Q3P45LK.js} +17 -3
- package/dist/{chunk-BA4N7AOZ.js → chunk-3JUWDIJ2.js} +11 -11
- package/dist/{chunk-GDZ6Z3B2.js → chunk-HZEOZGFN.js} +1 -1
- package/dist/{chunk-F4RV373I.js → chunk-IUXQAUYY.js} +2 -2
- package/dist/{chunk-IYDTDANH.js → chunk-IWTB3NN5.js} +1 -1
- package/dist/{chunk-OQWXMHRG.js → chunk-SRG5CJM7.js} +1 -1
- package/dist/{runDemo-ELZN7OT2.js → runDemo-CNAK5VH3.js} +4 -4
- package/dist/{runTrialGroup-WEBKLT7T.js → runTrialGroup-DGAWGKIA.js} +3 -3
- package/dist/src/cli/main.js +12 -12
- package/dist/{src-566DJYOC.js → src-C2SRMLET.js} +41 -40
- package/dist/{src-PUE6CMDF.js → src-RK3UVW3W.js} +62 -61
- package/dist/{src-GIKWIJM2.js → src-SZSXWHUI.js} +68 -67
- package/dist/{src-V5JLDT6T.js → src-T5I5JGEK.js} +5 -4
- package/dist/{src-ECRGORXR.js → src-WZSM2RYX.js} +151 -105
- package/dist/twinHarness-SBJDUUMK.js +5 -0
- package/dist/{twinStart-36ZSLZE7.js → twinStart-R4RLPJ3F.js} +2 -2
- package/package.json +2 -2
- package/dist/twinHarness-QGMYTU5N.js +0 -5
package/dist/build-info.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"package": "pome-sh",
|
|
3
|
-
"version": "0.21.
|
|
4
|
-
"git_sha": "
|
|
5
|
-
"build_time": "2026-08-
|
|
3
|
+
"version": "0.21.17",
|
|
4
|
+
"git_sha": "8b7c792f2aae4f9c2db1773c84b083bd2fa768d9",
|
|
5
|
+
"build_time": "2026-08-09T14:09:36.017Z"
|
|
6
6
|
}
|
|
@@ -183,7 +183,7 @@ async function checkTwinReachable(_configDir) {
|
|
|
183
183
|
});
|
|
184
184
|
let harness;
|
|
185
185
|
try {
|
|
186
|
-
const { bootTwin } = await import('./twinHarness-
|
|
186
|
+
const { bootTwin } = await import('./twinHarness-SBJDUUMK.js');
|
|
187
187
|
harness = await bootTwin({
|
|
188
188
|
twin: "github",
|
|
189
189
|
seedState: void 0,
|
|
@@ -56,6 +56,7 @@ function declareRouteInputs(spec) {
|
|
|
56
56
|
throw new Error(`route-inputs: path must start with '/' (got '${spec.path}')`);
|
|
57
57
|
}
|
|
58
58
|
const surface = `${spec.method} ${spec.path}`;
|
|
59
|
+
const undeclared = spec.undeclared ?? "refuse";
|
|
59
60
|
const pathShape = spec.pathParams ?? {};
|
|
60
61
|
const queryShape = spec.query ?? {};
|
|
61
62
|
const headerShape = spec.headers ?? {};
|
|
@@ -106,6 +107,7 @@ function declareRouteInputs(spec) {
|
|
|
106
107
|
path: spec.path,
|
|
107
108
|
surface,
|
|
108
109
|
bodyEncoding,
|
|
110
|
+
undeclared,
|
|
109
111
|
inputs,
|
|
110
112
|
// Deduplicated: pome-cloud's comparator diffs NAME sets, and a name that
|
|
111
113
|
// arrives in two locations is still one name to it.
|
|
@@ -113,16 +115,28 @@ function declareRouteInputs(spec) {
|
|
|
113
115
|
async parse(request) {
|
|
114
116
|
const path = pathSchema.parse(readPathParams(request, named, wildcard, spec.path));
|
|
115
117
|
const searchParams = new URL(request.url, "http://twin.invalid").searchParams;
|
|
116
|
-
|
|
118
|
+
if (undeclared === "refuse") {
|
|
119
|
+
refuseUndeclared("query", surface, [...searchParams.keys()], declaredQuery, bracketedQueryNames);
|
|
120
|
+
}
|
|
117
121
|
const query = querySchema.parse(readQuery(searchParams, declaredQuery, bracketedQueryNames, arrayQuery));
|
|
118
122
|
const header = headerSchema.parse(Object.fromEntries(Object.keys(headerShape).map((name) => [name, request.header(name)])));
|
|
119
123
|
const raw = await decodeBody(request, bodyEncoding, surface, spec.mediaField);
|
|
120
|
-
|
|
124
|
+
if (undeclared === "refuse") {
|
|
125
|
+
refuseUndeclared("body", surface, Object.keys(raw), declaredBody, /* @__PURE__ */ new Set());
|
|
126
|
+
}
|
|
121
127
|
const body = bodySchema.parse(raw);
|
|
122
128
|
return { path, query, header, body };
|
|
123
129
|
}
|
|
124
130
|
};
|
|
125
131
|
}
|
|
132
|
+
function routeInputDeclarer(undeclared) {
|
|
133
|
+
return (spec) => {
|
|
134
|
+
if (spec.undeclared !== void 0) {
|
|
135
|
+
throw new Error(`route-inputs: ${spec.method} ${spec.path} sets undeclared: '${spec.undeclared}' on its own spec, but its twin already rules '${undeclared}' for every route \u2014 the disposition is one ruling per twin (F-1372)`);
|
|
136
|
+
}
|
|
137
|
+
return declareRouteInputs({ ...spec, undeclared });
|
|
138
|
+
};
|
|
139
|
+
}
|
|
126
140
|
function mapShape(shape) {
|
|
127
141
|
return Object.fromEntries(Object.entries(shape).map(([name, schema]) => [name, unwrapBracketed(schema)]));
|
|
128
142
|
}
|
|
@@ -424,4 +438,4 @@ z.strictObject({
|
|
|
424
438
|
graphql_surfaces: z.array(graphqlArgumentSurfaceSchema).optional()
|
|
425
439
|
});
|
|
426
440
|
|
|
427
|
-
export { MalformedBodyError, UndeclaredInputError, booleanInput, bracketedQuery,
|
|
441
|
+
export { MalformedBodyError, UndeclaredInputError, booleanInput, bracketedQuery, integerInput, mountDeclaredRoute, repeatedInput, routeInputDeclarer };
|
|
@@ -16,7 +16,7 @@ var package_default4 = {
|
|
|
16
16
|
|
|
17
17
|
// ../packages/twin-linear/package.json
|
|
18
18
|
var package_default5 = {
|
|
19
|
-
version: "0.
|
|
19
|
+
version: "0.4.0"};
|
|
20
20
|
|
|
21
21
|
// src/twin/registry.ts
|
|
22
22
|
var TWIN_NAME_LIST = ["github", "slack", "stripe", "gmail", "linear"];
|
|
@@ -39,7 +39,7 @@ var TWIN_REGISTRY = {
|
|
|
39
39
|
defaultSeedState,
|
|
40
40
|
GitHubDomain,
|
|
41
41
|
openGitHubCloneDatabase
|
|
42
|
-
} = await import('./src-
|
|
42
|
+
} = await import('./src-SZSXWHUI.js');
|
|
43
43
|
const db = openGitHubCloneDatabase();
|
|
44
44
|
const domain = new GitHubDomain(db);
|
|
45
45
|
domain.seed(seedState === void 0 ? defaultSeedState() : seedState);
|
|
@@ -59,9 +59,9 @@ var TWIN_REGISTRY = {
|
|
|
59
59
|
envName: "SLACK",
|
|
60
60
|
defaultPort: 3333,
|
|
61
61
|
version: package_default2.version,
|
|
62
|
-
defaultSeed: async () => (await import('./src-
|
|
62
|
+
defaultSeed: async () => (await import('./src-T5I5JGEK.js')).defaultSeedState(),
|
|
63
63
|
async boot({ seedState, runId, recorder }) {
|
|
64
|
-
const { createSlackTwinApp, openSlackTwinDatabase, SlackDomain } = await import('./src-
|
|
64
|
+
const { createSlackTwinApp, openSlackTwinDatabase, SlackDomain } = await import('./src-T5I5JGEK.js');
|
|
65
65
|
const db = openSlackTwinDatabase(":memory:");
|
|
66
66
|
const domain = new SlackDomain(db);
|
|
67
67
|
domain.applySeed(seedState);
|
|
@@ -84,9 +84,9 @@ var TWIN_REGISTRY = {
|
|
|
84
84
|
envName: "STRIPE",
|
|
85
85
|
defaultPort: 3333,
|
|
86
86
|
version: package_default3.version,
|
|
87
|
-
defaultSeed: async () => (await import('./src-
|
|
87
|
+
defaultSeed: async () => (await import('./src-C2SRMLET.js')).defaultSeed(),
|
|
88
88
|
async boot({ seedState, runId, recorder, twinBaseUrl }) {
|
|
89
|
-
const stripeTwin = await import('./src-
|
|
89
|
+
const stripeTwin = await import('./src-C2SRMLET.js');
|
|
90
90
|
const { createApp } = await import('./server-DR56XIGP.js');
|
|
91
91
|
const {
|
|
92
92
|
applySeed: applyStripeSeed,
|
|
@@ -128,9 +128,9 @@ var TWIN_REGISTRY = {
|
|
|
128
128
|
portEnvName: "GMAIL_TWIN_PORT",
|
|
129
129
|
tokenEnvName: "POME_GMAIL_TOKEN",
|
|
130
130
|
version: package_default4.version,
|
|
131
|
-
defaultSeed: async () => (await import('./src-
|
|
131
|
+
defaultSeed: async () => (await import('./src-RK3UVW3W.js')).defaultSeedState(),
|
|
132
132
|
async boot({ seedState, runId, recorder }) {
|
|
133
|
-
const { createGmailTwinApp, GmailDomain, openGmailTwinDatabase, parseSeed } = await import('./src-
|
|
133
|
+
const { createGmailTwinApp, GmailDomain, openGmailTwinDatabase, parseSeed } = await import('./src-RK3UVW3W.js');
|
|
134
134
|
const db = openGmailTwinDatabase(":memory:");
|
|
135
135
|
const seed = parseSeed(seedState);
|
|
136
136
|
const domain = new GmailDomain(db);
|
|
@@ -149,7 +149,7 @@ var TWIN_REGISTRY = {
|
|
|
149
149
|
portEnvName: "LINEAR_TWIN_PORT",
|
|
150
150
|
tokenEnvName: "POME_LINEAR_TOKEN",
|
|
151
151
|
version: package_default5.version,
|
|
152
|
-
defaultSeed: async () => (await import('./src-
|
|
152
|
+
defaultSeed: async () => (await import('./src-WZSM2RYX.js')).defaultSeedState(),
|
|
153
153
|
async boot({ seedState, runId, recorder }) {
|
|
154
154
|
const {
|
|
155
155
|
createLinearTwinApp,
|
|
@@ -157,7 +157,7 @@ var TWIN_REGISTRY = {
|
|
|
157
157
|
LinearDomain,
|
|
158
158
|
openLinearTwinDatabase,
|
|
159
159
|
parseSeed
|
|
160
|
-
} = await import('./src-
|
|
160
|
+
} = await import('./src-WZSM2RYX.js');
|
|
161
161
|
const db = openLinearTwinDatabase(":memory:");
|
|
162
162
|
const seed = parseSeed(seedState);
|
|
163
163
|
const domain = new LinearDomain(db);
|
|
@@ -173,7 +173,7 @@ var TWIN_REGISTRY = {
|
|
|
173
173
|
}
|
|
174
174
|
};
|
|
175
175
|
async function createGitHubSmokeApp() {
|
|
176
|
-
const { createGitHubCloneApp } = await import('./src-
|
|
176
|
+
const { createGitHubCloneApp } = await import('./src-SZSXWHUI.js');
|
|
177
177
|
return createGitHubCloneApp();
|
|
178
178
|
}
|
|
179
179
|
function defaultPortFor(twin, env = process.env) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { readManifest, normalizeManifestTwins } from './chunk-KUVTL4NZ.js';
|
|
2
|
-
import { createHostedClient, perTwinReturnedByCloud, parseTaskFile, runAgentCommand, writeRunArtifactsCore, toTwinHttpEvent, redactJsonl, uploadRunBlobs, scoreFromFinalizeResponse, scoreStatus } from './chunk-
|
|
2
|
+
import { createHostedClient, perTwinReturnedByCloud, parseTaskFile, runAgentCommand, writeRunArtifactsCore, toTwinHttpEvent, redactJsonl, uploadRunBlobs, scoreFromFinalizeResponse, scoreStatus } from './chunk-SRG5CJM7.js';
|
|
3
3
|
import { MOUNTED_TWINS, HostedAuthError, HostedDiscardRefusedError, HostedQuotaError, HostedOrchError, HostedTrialError, agentResponseSchema } from './chunk-PQYIAA6K.js';
|
|
4
4
|
import { redactSecrets, redactEvent } from './chunk-SG6ZTIMT.js';
|
|
5
5
|
import { existsSync } from 'node:fs';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { getAvailablePort } from './chunk-XDU6TD4O.js';
|
|
2
2
|
import { buildEgressAllowlist, readBlockedEgress } from './chunk-CBFKZZBR.js';
|
|
3
|
-
import { parseTaskFile, seedStateForTwin, runAgentCommand, writeRunArtifactsCore } from './chunk-
|
|
4
|
-
import { createRecorder, bootTwin } from './chunk-
|
|
3
|
+
import { parseTaskFile, seedStateForTwin, runAgentCommand, writeRunArtifactsCore } from './chunk-SRG5CJM7.js';
|
|
4
|
+
import { createRecorder, bootTwin } from './chunk-IWTB3NN5.js';
|
|
5
5
|
import { eventSchema } from './chunk-VBATFCWR.js';
|
|
6
6
|
import { redactSecrets, redactEvent } from './chunk-SG6ZTIMT.js';
|
|
7
7
|
import { serve } from '@hono/node-server';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { TWIN_NAMES, isTwinName, TWIN_REGISTRY } from './chunk-
|
|
1
|
+
import { TWIN_NAMES, isTwinName, TWIN_REGISTRY } from './chunk-3JUWDIJ2.js';
|
|
2
2
|
import { createFileBackedRecorderStore, createRecorderStore } from './chunk-TV5S6WQV.js';
|
|
3
3
|
|
|
4
4
|
// src/recorder/recorder.ts
|
|
@@ -2,7 +2,7 @@ import { criterionSchema, finalizeResponseSchema, HostedDiscardRefusedError, Hos
|
|
|
2
2
|
import { seedSchema, parseSeed, defaultSeedState as defaultSeedState$2 } from './chunk-SGDUD7KK.js';
|
|
3
3
|
import { gmailSeedSchema, defaultSeedState } from './chunk-NJ246QPJ.js';
|
|
4
4
|
import { linearSeedSchema, defaultSeedState as defaultSeedState$1 } from './chunk-ZKID2HS3.js';
|
|
5
|
-
import { isTwinName, TWIN_REGISTRY } from './chunk-
|
|
5
|
+
import { isTwinName, TWIN_REGISTRY } from './chunk-3JUWDIJ2.js';
|
|
6
6
|
import { toTwinHttpEventRow } from './chunk-TV5S6WQV.js';
|
|
7
7
|
import { redactEvent, redactSecrets } from './chunk-SG6ZTIMT.js';
|
|
8
8
|
import { mkdir, appendFile, writeFile, readFile } from 'node:fs/promises';
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { newGroupId, reassuranceBox, twinReadyLine, trialsHeaderLine, trialLine, summaryLines, evaluatingLine, criterionPhrase } from './chunk-RGZBC7NF.js';
|
|
2
2
|
import { DemoCapacityError, capacityLabel, parseCapacityMarker, capacityKindFrom } from './chunk-ZX4WNSZ5.js';
|
|
3
|
-
import { runTask, demoTaskPath, DEMO_TASK_NAME, DEMO_REPO } from './chunk-
|
|
3
|
+
import { runTask, demoTaskPath, DEMO_TASK_NAME, DEMO_REPO } from './chunk-IUXQAUYY.js';
|
|
4
4
|
import { getAvailablePort } from './chunk-XDU6TD4O.js';
|
|
5
5
|
import './chunk-CBFKZZBR.js';
|
|
6
|
-
import { createHostedClient, parseTaskFile, uploadRunBlobs, scoreFromFinalizeResponse, scoreStatus, outcomeOf } from './chunk-
|
|
6
|
+
import { createHostedClient, parseTaskFile, uploadRunBlobs, scoreFromFinalizeResponse, scoreStatus, outcomeOf } from './chunk-SRG5CJM7.js';
|
|
7
7
|
import './chunk-NW7HGA2K.js';
|
|
8
8
|
import { HostedQuotaError, HostedOrchError } from './chunk-PQYIAA6K.js';
|
|
9
9
|
import './chunk-SGDUD7KK.js';
|
|
10
10
|
import './chunk-NJ246QPJ.js';
|
|
11
11
|
import './chunk-ZKID2HS3.js';
|
|
12
|
-
import { bootTwin } from './chunk-
|
|
13
|
-
import './chunk-
|
|
12
|
+
import { bootTwin } from './chunk-IWTB3NN5.js';
|
|
13
|
+
import './chunk-3JUWDIJ2.js';
|
|
14
14
|
import './chunk-TV5S6WQV.js';
|
|
15
15
|
import './chunk-VBATFCWR.js';
|
|
16
16
|
import './chunk-SG6ZTIMT.js';
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { newGroupId, criterionPhrase } from './chunk-RGZBC7NF.js';
|
|
2
|
-
import { runTaskHosted, resolveRunAgentIdentity } from './chunk-
|
|
2
|
+
import { runTaskHosted, resolveRunAgentIdentity } from './chunk-HZEOZGFN.js';
|
|
3
3
|
import './chunk-KUVTL4NZ.js';
|
|
4
|
-
import { createHostedClient, parseTaskFile, outcomeOf } from './chunk-
|
|
4
|
+
import { createHostedClient, parseTaskFile, outcomeOf } from './chunk-SRG5CJM7.js';
|
|
5
5
|
import './chunk-NW7HGA2K.js';
|
|
6
6
|
import { HostedQuotaError, HostedTrialError } from './chunk-PQYIAA6K.js';
|
|
7
7
|
import './chunk-SGDUD7KK.js';
|
|
8
8
|
import './chunk-NJ246QPJ.js';
|
|
9
9
|
import './chunk-ZKID2HS3.js';
|
|
10
|
-
import './chunk-
|
|
10
|
+
import './chunk-3JUWDIJ2.js';
|
|
11
11
|
import './chunk-TV5S6WQV.js';
|
|
12
12
|
import './chunk-VBATFCWR.js';
|
|
13
13
|
import './chunk-SG6ZTIMT.js';
|
package/dist/src/cli/main.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { DEFAULT_CONTROL_PLANE_URL, DEFAULT_DASHBOARD_URL, clearLocalCredentials, friendlyHostedError, runSessionCreate, runSessionList, runSessionStop, resolveCredentials, runTaskHosted, discoverRunSet, loadTrialEvents, persistCredentialsAfterLogin, DEFAULT_DOCS_SITE_ORIGIN, resolveSeams, resolveCachedAgentId, readLinkCache, postAgentResolver, writeLinkCache, ensurePomeGitignored } from '../../chunk-
|
|
2
|
+
import { DEFAULT_CONTROL_PLANE_URL, DEFAULT_DASHBOARD_URL, clearLocalCredentials, friendlyHostedError, runSessionCreate, runSessionList, runSessionStop, resolveCredentials, runTaskHosted, discoverRunSet, loadTrialEvents, persistCredentialsAfterLogin, DEFAULT_DOCS_SITE_ORIGIN, resolveSeams, resolveCachedAgentId, readLinkCache, postAgentResolver, writeLinkCache, ensurePomeGitignored } from '../../chunk-HZEOZGFN.js';
|
|
3
3
|
import { readManifest, writeManifest, MANIFEST_JSON, readRequiredManifest, normalizeManifestTwins } from '../../chunk-KUVTL4NZ.js';
|
|
4
|
-
import { assetPath, runTask, resolvePackageRoot, DEMO_TASK_NAME, demoTaskPath } from '../../chunk-
|
|
4
|
+
import { assetPath, runTask, resolvePackageRoot, DEMO_TASK_NAME, demoTaskPath } from '../../chunk-IUXQAUYY.js';
|
|
5
5
|
import '../../chunk-XDU6TD4O.js';
|
|
6
6
|
import '../../chunk-CBFKZZBR.js';
|
|
7
|
-
import { parseTaskFile, scoreStatus, runScoreLine, readLatestRun, readMetaSummary, readConfigTwins, scoreCountsSummary, markerFor, outcomeOf, criterionMarkerLabel, twinSkipSuffix, readCodeCriteria, createHostedClient, toTwinHttpEvent, redactJsonl, scoreFromFinalizeResponse, parseGitHubSeedState, uploadRunBlobs } from '../../chunk-
|
|
7
|
+
import { parseTaskFile, scoreStatus, runScoreLine, readLatestRun, readMetaSummary, readConfigTwins, scoreCountsSummary, markerFor, outcomeOf, criterionMarkerLabel, twinSkipSuffix, readCodeCriteria, createHostedClient, toTwinHttpEvent, redactJsonl, scoreFromFinalizeResponse, parseGitHubSeedState, uploadRunBlobs } from '../../chunk-SRG5CJM7.js';
|
|
8
8
|
import '../../chunk-NW7HGA2K.js';
|
|
9
9
|
import { MOUNTED_TWINS, deriveAgentSlug, exitCodeFor, HostedUsageError, HostedOrchError, HostedAuthError, HostedQuotaError } from '../../chunk-PQYIAA6K.js';
|
|
10
10
|
import { TAPE_ASSERTABLE_TOOLS } from '../../chunk-FKZZWWYC.js';
|
|
@@ -15,8 +15,8 @@ import '../../chunk-NJ246QPJ.js';
|
|
|
15
15
|
import { LINEAR_CHECKS } from '../../chunk-XBT6ZLBG.js';
|
|
16
16
|
import '../../chunk-ZKID2HS3.js';
|
|
17
17
|
import { oneOf, defineCheck, repoRef, VACUITY_SENTINEL_NUMBER, childStatePath, VACUITY_SENTINEL, statePath, templateSlots, renderCheck, checksDigest, checkPattern, checkNearMissPattern } from '../../chunk-JWJYNAWI.js';
|
|
18
|
-
import '../../chunk-
|
|
19
|
-
import { TWIN_NAME_LIST, isTwinName, createGitHubSmokeApp } from '../../chunk-
|
|
18
|
+
import '../../chunk-IWTB3NN5.js';
|
|
19
|
+
import { TWIN_NAME_LIST, isTwinName, createGitHubSmokeApp } from '../../chunk-3JUWDIJ2.js';
|
|
20
20
|
import '../../chunk-TV5S6WQV.js';
|
|
21
21
|
import { isLegacyEventRow, eventSchema } from '../../chunk-VBATFCWR.js';
|
|
22
22
|
import { redactEvent, redactSecrets } from '../../chunk-SG6ZTIMT.js';
|
|
@@ -850,7 +850,7 @@ async function throwForStatus(res) {
|
|
|
850
850
|
|
|
851
851
|
// src/task/seed-verifier.ts
|
|
852
852
|
async function verifySeedWithTwin(seed) {
|
|
853
|
-
const { GitHubDomain, openGitHubCloneDatabase } = await import('../../src-
|
|
853
|
+
const { GitHubDomain, openGitHubCloneDatabase } = await import('../../src-SZSXWHUI.js');
|
|
854
854
|
const db = openGitHubCloneDatabase(":memory:");
|
|
855
855
|
try {
|
|
856
856
|
new GitHubDomain(db).seed(seed);
|
|
@@ -4490,7 +4490,7 @@ var DEFAULT_AGENT_FILE = "examples/agents/scripted-triage-agent.ts";
|
|
|
4490
4490
|
var DEFAULT_AGENT_COMMAND = `node ${DEFAULT_AGENT_FILE}`;
|
|
4491
4491
|
var MANIFEST_SCHEMA_URL = "https://pome.sh/schemas/v1/pome.json";
|
|
4492
4492
|
function readPackageVersion() {
|
|
4493
|
-
if ("0.21.
|
|
4493
|
+
if ("0.21.17".length > 0) return "0.21.17";
|
|
4494
4494
|
try {
|
|
4495
4495
|
const here = dirname(fileURLToPath(import.meta.url));
|
|
4496
4496
|
const candidates = [
|
|
@@ -4945,7 +4945,7 @@ function createProgram() {
|
|
|
4945
4945
|
return;
|
|
4946
4946
|
}
|
|
4947
4947
|
{
|
|
4948
|
-
const { runDoctorChecks } = await import('../../checks-
|
|
4948
|
+
const { runDoctorChecks } = await import('../../checks-DH7XLBI3.js');
|
|
4949
4949
|
const { renderDoctorReport } = await import('../../render-ZQQ4UMNO.js');
|
|
4950
4950
|
const doctorReport = await runDoctorChecks({ mode: useLocal ? "full" : "hosted" });
|
|
4951
4951
|
if (!doctorReport.ok) {
|
|
@@ -4983,7 +4983,7 @@ function createProgram() {
|
|
|
4983
4983
|
taskForRuns.config.runs
|
|
4984
4984
|
);
|
|
4985
4985
|
if (k > 1) {
|
|
4986
|
-
const { runTrialGroup } = await import('../../runTrialGroup-
|
|
4986
|
+
const { runTrialGroup } = await import('../../runTrialGroup-DGAWGKIA.js');
|
|
4987
4987
|
const fileForRerun = relative(process.cwd(), file);
|
|
4988
4988
|
const rerunCommand = defaultTask ? options.trials !== void 0 ? `pome run -n ${k}` : "pome run" : `pome run ${fileForRerun && !fileForRerun.startsWith("..") ? fileForRerun : file} -n ${k}`;
|
|
4989
4989
|
const groupResult = await runTrialGroup({
|
|
@@ -5077,7 +5077,7 @@ function createProgram() {
|
|
|
5077
5077
|
process.exitCode = 5;
|
|
5078
5078
|
return;
|
|
5079
5079
|
}
|
|
5080
|
-
const { runDemo } = await import('../../runDemo-
|
|
5080
|
+
const { runDemo } = await import('../../runDemo-CNAK5VH3.js');
|
|
5081
5081
|
const result = await runDemo({
|
|
5082
5082
|
apiBase: opts.apiUrl.replace(/\/$/, ""),
|
|
5083
5083
|
dashboardBase: process.env.POME_DASHBOARD_URL ?? DEFAULT_DASHBOARD_URL,
|
|
@@ -5095,7 +5095,7 @@ function createProgram() {
|
|
|
5095
5095
|
program.command("doctor").description(
|
|
5096
5096
|
"Check the agent\u2194twin wiring: pome.json (or pome.yaml) present + valid, the local twin boots + serves, requests routed to the twin (not a hardcoded production host), egress floor active. On failure prints one named cause (file:line where knowable) + one concrete fix and exits non-zero."
|
|
5097
5097
|
).action(async () => {
|
|
5098
|
-
const { runDoctorChecks } = await import('../../checks-
|
|
5098
|
+
const { runDoctorChecks } = await import('../../checks-DH7XLBI3.js');
|
|
5099
5099
|
const { renderDoctorReport } = await import('../../render-ZQQ4UMNO.js');
|
|
5100
5100
|
const report = await runDoctorChecks();
|
|
5101
5101
|
for (const line of renderDoctorReport(report, { passNote: true })) console.error(line);
|
|
@@ -5227,7 +5227,7 @@ function createProgram() {
|
|
|
5227
5227
|
).description(
|
|
5228
5228
|
"Start a standalone twin as a long-lived foreground server (Ctrl-C to stop)"
|
|
5229
5229
|
).action(async (name, options) => {
|
|
5230
|
-
const { runTwinStartCommand } = await import('../../twinStart-
|
|
5230
|
+
const { runTwinStartCommand } = await import('../../twinStart-R4RLPJ3F.js');
|
|
5231
5231
|
await runTwinStartCommand(name, options);
|
|
5232
5232
|
});
|
|
5233
5233
|
twin.command("reset").argument("[name]", "Twin name (default: github)", "github").description("Reset standalone twin state").action(async (name) => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { bracketedQuery, integerInput, booleanInput,
|
|
1
|
+
import { routeInputDeclarer, bracketedQuery, integerInput, booleanInput, mountDeclaredRoute, UndeclaredInputError } from './chunk-2Q3P45LK.js';
|
|
2
2
|
import { failureInjectionRuleSchema, loadMcpToolFixture, openTwinDatabase, createFailureInjectionStore, defineTwin, twinBuildInfo, deriveMcpToolTable, failureInjectionMiddleware, createApp, FAILURE_INJECTION_OVERRIDE_KEY, recordedRequestHeaders, UnknownToolError } from './chunk-TV5S6WQV.js';
|
|
3
3
|
import './chunk-VBATFCWR.js';
|
|
4
4
|
import './chunk-SG6ZTIMT.js';
|
|
@@ -2782,6 +2782,7 @@ function flattenCreated(created2) {
|
|
|
2782
2782
|
}
|
|
2783
2783
|
return out;
|
|
2784
2784
|
}
|
|
2785
|
+
var declareInputs = routeInputDeclarer("refuse");
|
|
2785
2786
|
var ID_PATH = { id: z.string().min(1) };
|
|
2786
2787
|
var LIST_QUERY = {
|
|
2787
2788
|
limit: integerInput({ min: 1 }).optional(),
|
|
@@ -2864,30 +2865,30 @@ var UPDATE_SUBSCRIPTION_BODY = {
|
|
|
2864
2865
|
};
|
|
2865
2866
|
var STRIPE_ROUTES = {
|
|
2866
2867
|
// ---------- PaymentIntents ----------
|
|
2867
|
-
createPaymentIntent:
|
|
2868
|
+
createPaymentIntent: declareInputs({
|
|
2868
2869
|
method: "POST",
|
|
2869
2870
|
path: "/v1/payment_intents",
|
|
2870
2871
|
bodyEncoding: "form",
|
|
2871
2872
|
body: CREATE_PAYMENT_INTENT_BODY
|
|
2872
2873
|
}),
|
|
2873
|
-
retrievePaymentIntent:
|
|
2874
|
+
retrievePaymentIntent: declareInputs({
|
|
2874
2875
|
method: "GET",
|
|
2875
2876
|
path: "/v1/payment_intents/:id",
|
|
2876
2877
|
pathParams: ID_PATH
|
|
2877
2878
|
}),
|
|
2878
|
-
listPaymentIntents:
|
|
2879
|
+
listPaymentIntents: declareInputs({
|
|
2879
2880
|
method: "GET",
|
|
2880
2881
|
path: "/v1/payment_intents",
|
|
2881
2882
|
query: LIST_QUERY
|
|
2882
2883
|
}),
|
|
2883
|
-
confirmPaymentIntent:
|
|
2884
|
+
confirmPaymentIntent: declareInputs({
|
|
2884
2885
|
method: "POST",
|
|
2885
2886
|
path: "/v1/payment_intents/:id/confirm",
|
|
2886
2887
|
pathParams: ID_PATH,
|
|
2887
2888
|
bodyEncoding: "form",
|
|
2888
2889
|
body: CONFIRM_PAYMENT_INTENT_BODY
|
|
2889
2890
|
}),
|
|
2890
|
-
updatePaymentIntent:
|
|
2891
|
+
updatePaymentIntent: declareInputs({
|
|
2891
2892
|
method: "POST",
|
|
2892
2893
|
path: "/v1/payment_intents/:id",
|
|
2893
2894
|
pathParams: ID_PATH,
|
|
@@ -2896,29 +2897,29 @@ var STRIPE_ROUTES = {
|
|
|
2896
2897
|
}),
|
|
2897
2898
|
// Cancellation takes no body at all here. Real Stripe accepts
|
|
2898
2899
|
// `cancellation_reason`; this twin has never read it, so it is not declared.
|
|
2899
|
-
cancelPaymentIntent:
|
|
2900
|
+
cancelPaymentIntent: declareInputs({
|
|
2900
2901
|
method: "POST",
|
|
2901
2902
|
path: "/v1/payment_intents/:id/cancel",
|
|
2902
2903
|
pathParams: ID_PATH
|
|
2903
2904
|
}),
|
|
2904
|
-
simulateCryptoDeposit:
|
|
2905
|
+
simulateCryptoDeposit: declareInputs({
|
|
2905
2906
|
method: "POST",
|
|
2906
2907
|
path: "/v1/test_helpers/payment_intents/:id/simulate_crypto_deposit",
|
|
2907
2908
|
pathParams: ID_PATH
|
|
2908
2909
|
}),
|
|
2909
2910
|
// ---------- Charges ----------
|
|
2910
|
-
retrieveCharge:
|
|
2911
|
+
retrieveCharge: declareInputs({
|
|
2911
2912
|
method: "GET",
|
|
2912
2913
|
path: "/v1/charges/:id",
|
|
2913
2914
|
pathParams: ID_PATH
|
|
2914
2915
|
}),
|
|
2915
|
-
listCharges:
|
|
2916
|
+
listCharges: declareInputs({
|
|
2916
2917
|
method: "GET",
|
|
2917
2918
|
path: "/v1/charges",
|
|
2918
2919
|
query: { ...LIST_QUERY, payment_intent: z.string().optional(), customer: z.string().optional() }
|
|
2919
2920
|
}),
|
|
2920
2921
|
// ---------- Refunds ----------
|
|
2921
|
-
createRefund:
|
|
2922
|
+
createRefund: declareInputs({
|
|
2922
2923
|
method: "POST",
|
|
2923
2924
|
path: "/v1/refunds",
|
|
2924
2925
|
// A real declared input on this route: the handler reads it and the domain
|
|
@@ -2929,166 +2930,166 @@ var STRIPE_ROUTES = {
|
|
|
2929
2930
|
bodyEncoding: "form",
|
|
2930
2931
|
body: CREATE_REFUND_BODY
|
|
2931
2932
|
}),
|
|
2932
|
-
retrieveRefund:
|
|
2933
|
+
retrieveRefund: declareInputs({
|
|
2933
2934
|
method: "GET",
|
|
2934
2935
|
path: "/v1/refunds/:id",
|
|
2935
2936
|
pathParams: ID_PATH
|
|
2936
2937
|
}),
|
|
2937
|
-
listRefunds:
|
|
2938
|
+
listRefunds: declareInputs({
|
|
2938
2939
|
method: "GET",
|
|
2939
2940
|
path: "/v1/refunds",
|
|
2940
2941
|
query: { ...LIST_QUERY, charge: z.string().optional(), payment_intent: z.string().optional() }
|
|
2941
2942
|
}),
|
|
2942
2943
|
// ---------- Customers ----------
|
|
2943
|
-
createCustomer:
|
|
2944
|
+
createCustomer: declareInputs({
|
|
2944
2945
|
method: "POST",
|
|
2945
2946
|
path: "/v1/customers",
|
|
2946
2947
|
bodyEncoding: "form",
|
|
2947
2948
|
body: CUSTOMER_FIELDS_BODY
|
|
2948
2949
|
}),
|
|
2949
|
-
listCustomerPaymentMethods:
|
|
2950
|
+
listCustomerPaymentMethods: declareInputs({
|
|
2950
2951
|
method: "GET",
|
|
2951
2952
|
path: "/v1/customers/:id/payment_methods",
|
|
2952
2953
|
pathParams: ID_PATH,
|
|
2953
2954
|
query: { ...LIST_QUERY, type: z.string().optional() }
|
|
2954
2955
|
}),
|
|
2955
|
-
retrieveCustomer:
|
|
2956
|
+
retrieveCustomer: declareInputs({
|
|
2956
2957
|
method: "GET",
|
|
2957
2958
|
path: "/v1/customers/:id",
|
|
2958
2959
|
pathParams: ID_PATH
|
|
2959
2960
|
}),
|
|
2960
|
-
updateCustomer:
|
|
2961
|
+
updateCustomer: declareInputs({
|
|
2961
2962
|
method: "POST",
|
|
2962
2963
|
path: "/v1/customers/:id",
|
|
2963
2964
|
pathParams: ID_PATH,
|
|
2964
2965
|
bodyEncoding: "form",
|
|
2965
2966
|
body: CUSTOMER_FIELDS_BODY
|
|
2966
2967
|
}),
|
|
2967
|
-
deleteCustomer:
|
|
2968
|
+
deleteCustomer: declareInputs({
|
|
2968
2969
|
method: "DELETE",
|
|
2969
2970
|
path: "/v1/customers/:id",
|
|
2970
2971
|
pathParams: ID_PATH
|
|
2971
2972
|
}),
|
|
2972
|
-
listCustomers:
|
|
2973
|
+
listCustomers: declareInputs({
|
|
2973
2974
|
method: "GET",
|
|
2974
2975
|
path: "/v1/customers",
|
|
2975
2976
|
query: { ...LIST_QUERY, email: z.string().optional() }
|
|
2976
2977
|
}),
|
|
2977
2978
|
// ---------- Payment methods ----------
|
|
2978
|
-
createPaymentMethod:
|
|
2979
|
+
createPaymentMethod: declareInputs({
|
|
2979
2980
|
method: "POST",
|
|
2980
2981
|
path: "/v1/payment_methods",
|
|
2981
2982
|
bodyEncoding: "form",
|
|
2982
2983
|
body: CREATE_PAYMENT_METHOD_BODY
|
|
2983
2984
|
}),
|
|
2984
|
-
retrievePaymentMethod:
|
|
2985
|
+
retrievePaymentMethod: declareInputs({
|
|
2985
2986
|
method: "GET",
|
|
2986
2987
|
path: "/v1/payment_methods/:id",
|
|
2987
2988
|
pathParams: ID_PATH
|
|
2988
2989
|
}),
|
|
2989
|
-
attachPaymentMethod:
|
|
2990
|
+
attachPaymentMethod: declareInputs({
|
|
2990
2991
|
method: "POST",
|
|
2991
2992
|
path: "/v1/payment_methods/:id/attach",
|
|
2992
2993
|
pathParams: ID_PATH,
|
|
2993
2994
|
bodyEncoding: "form",
|
|
2994
2995
|
body: { customer: z.string().optional() }
|
|
2995
2996
|
}),
|
|
2996
|
-
detachPaymentMethod:
|
|
2997
|
+
detachPaymentMethod: declareInputs({
|
|
2997
2998
|
method: "POST",
|
|
2998
2999
|
path: "/v1/payment_methods/:id/detach",
|
|
2999
3000
|
pathParams: ID_PATH
|
|
3000
3001
|
}),
|
|
3001
3002
|
// ---------- Products ----------
|
|
3002
|
-
createProduct:
|
|
3003
|
+
createProduct: declareInputs({
|
|
3003
3004
|
method: "POST",
|
|
3004
3005
|
path: "/v1/products",
|
|
3005
3006
|
bodyEncoding: "form",
|
|
3006
3007
|
body: PRODUCT_FIELDS_BODY
|
|
3007
3008
|
}),
|
|
3008
|
-
retrieveProduct:
|
|
3009
|
+
retrieveProduct: declareInputs({
|
|
3009
3010
|
method: "GET",
|
|
3010
3011
|
path: "/v1/products/:id",
|
|
3011
3012
|
pathParams: ID_PATH
|
|
3012
3013
|
}),
|
|
3013
|
-
listProducts:
|
|
3014
|
+
listProducts: declareInputs({
|
|
3014
3015
|
method: "GET",
|
|
3015
3016
|
path: "/v1/products",
|
|
3016
3017
|
query: { ...LIST_QUERY, active: booleanInput.optional() }
|
|
3017
3018
|
}),
|
|
3018
3019
|
// ---------- Prices ----------
|
|
3019
|
-
createPrice:
|
|
3020
|
+
createPrice: declareInputs({
|
|
3020
3021
|
method: "POST",
|
|
3021
3022
|
path: "/v1/prices",
|
|
3022
3023
|
bodyEncoding: "form",
|
|
3023
3024
|
body: CREATE_PRICE_BODY
|
|
3024
3025
|
}),
|
|
3025
|
-
retrievePrice:
|
|
3026
|
+
retrievePrice: declareInputs({
|
|
3026
3027
|
method: "GET",
|
|
3027
3028
|
path: "/v1/prices/:id",
|
|
3028
3029
|
pathParams: ID_PATH
|
|
3029
3030
|
}),
|
|
3030
|
-
listPrices:
|
|
3031
|
+
listPrices: declareInputs({
|
|
3031
3032
|
method: "GET",
|
|
3032
3033
|
path: "/v1/prices",
|
|
3033
3034
|
query: { ...LIST_QUERY, product: z.string().optional(), active: booleanInput.optional() }
|
|
3034
3035
|
}),
|
|
3035
3036
|
// ---------- Subscriptions ----------
|
|
3036
|
-
createSubscription:
|
|
3037
|
+
createSubscription: declareInputs({
|
|
3037
3038
|
method: "POST",
|
|
3038
3039
|
path: "/v1/subscriptions",
|
|
3039
3040
|
bodyEncoding: "form",
|
|
3040
3041
|
body: CREATE_SUBSCRIPTION_BODY
|
|
3041
3042
|
}),
|
|
3042
|
-
retrieveSubscription:
|
|
3043
|
+
retrieveSubscription: declareInputs({
|
|
3043
3044
|
method: "GET",
|
|
3044
3045
|
path: "/v1/subscriptions/:id",
|
|
3045
3046
|
pathParams: ID_PATH
|
|
3046
3047
|
}),
|
|
3047
|
-
updateSubscription:
|
|
3048
|
+
updateSubscription: declareInputs({
|
|
3048
3049
|
method: "POST",
|
|
3049
3050
|
path: "/v1/subscriptions/:id",
|
|
3050
3051
|
pathParams: ID_PATH,
|
|
3051
3052
|
bodyEncoding: "form",
|
|
3052
3053
|
body: UPDATE_SUBSCRIPTION_BODY
|
|
3053
3054
|
}),
|
|
3054
|
-
cancelSubscription:
|
|
3055
|
+
cancelSubscription: declareInputs({
|
|
3055
3056
|
method: "DELETE",
|
|
3056
3057
|
path: "/v1/subscriptions/:id",
|
|
3057
3058
|
pathParams: ID_PATH
|
|
3058
3059
|
}),
|
|
3059
|
-
listSubscriptions:
|
|
3060
|
+
listSubscriptions: declareInputs({
|
|
3060
3061
|
method: "GET",
|
|
3061
3062
|
path: "/v1/subscriptions",
|
|
3062
3063
|
query: { ...LIST_QUERY, customer: z.string().optional(), status: z.string().optional() }
|
|
3063
3064
|
}),
|
|
3064
3065
|
// ---------- Invoices (reads only) ----------
|
|
3065
|
-
retrieveInvoice:
|
|
3066
|
+
retrieveInvoice: declareInputs({
|
|
3066
3067
|
method: "GET",
|
|
3067
3068
|
path: "/v1/invoices/:id",
|
|
3068
3069
|
pathParams: ID_PATH
|
|
3069
3070
|
}),
|
|
3070
|
-
listInvoices:
|
|
3071
|
+
listInvoices: declareInputs({
|
|
3071
3072
|
method: "GET",
|
|
3072
3073
|
path: "/v1/invoices",
|
|
3073
3074
|
query: LIST_QUERY
|
|
3074
3075
|
}),
|
|
3075
3076
|
// ---------- Balance ----------
|
|
3076
|
-
retrieveBalance:
|
|
3077
|
+
retrieveBalance: declareInputs({
|
|
3077
3078
|
method: "GET",
|
|
3078
3079
|
path: "/v1/balance"
|
|
3079
3080
|
}),
|
|
3080
|
-
listBalanceTransactions:
|
|
3081
|
+
listBalanceTransactions: declareInputs({
|
|
3081
3082
|
method: "GET",
|
|
3082
3083
|
path: "/v1/balance_transactions",
|
|
3083
3084
|
query: { ...LIST_QUERY, type: z.string().optional() }
|
|
3084
3085
|
}),
|
|
3085
3086
|
// ---------- Events ----------
|
|
3086
|
-
retrieveEvent:
|
|
3087
|
+
retrieveEvent: declareInputs({
|
|
3087
3088
|
method: "GET",
|
|
3088
3089
|
path: "/v1/events/:id",
|
|
3089
3090
|
pathParams: ID_PATH
|
|
3090
3091
|
}),
|
|
3091
|
-
listEvents:
|
|
3092
|
+
listEvents: declareInputs({
|
|
3092
3093
|
method: "GET",
|
|
3093
3094
|
path: "/v1/events",
|
|
3094
3095
|
query: { ...LIST_QUERY, type: z.string().optional() }
|