deepline 0.3.485 → 0.3.486

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (123) hide show
  1. package/dist/bundling-sources/sdk/src/release.ts +1 -1
  2. package/dist/bundling-sources/shared_libs/play-runtime/ledger-safe-payload.ts +8 -4
  3. package/dist/bundling-sources/shared_libs/play-runtime/runner-app/index.ts +37 -44
  4. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/absurd-runtime-worker.ts +2 -1
  5. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres-progress.ts +2 -9
  6. package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres.ts +7 -26
  7. package/dist/cli/auth-ARKH3OAU.js +43 -0
  8. package/dist/cli/{auth-OWMUENCU.mjs → auth-B4DJO4FB.mjs} +5 -5
  9. package/dist/cli/{billing-2FMNQGOX.js → billing-GDWAMARK.js} +79 -79
  10. package/dist/cli/{billing-JX4H3VFF.mjs → billing-IIQ3VNXU.mjs} +6 -6
  11. package/dist/cli/{chunk-3Z24NKW7.mjs → chunk-2DVFQYPG.mjs} +10 -10
  12. package/dist/cli/{chunk-T4G2T5DS.js → chunk-5DUP4ZUE.js} +21 -21
  13. package/dist/cli/{chunk-KZTNNLIL.mjs → chunk-5QYZ4MEW.mjs} +2 -2
  14. package/dist/cli/{chunk-TSCUWWTM.mjs → chunk-5RLVCOKH.mjs} +1 -1
  15. package/dist/cli/{chunk-JD6HKNKD.mjs → chunk-5Y7LLRWO.mjs} +1 -1
  16. package/dist/cli/{chunk-ECIXZNSW.js → chunk-5YILTBF7.js} +53 -53
  17. package/dist/cli/{chunk-JQXUWYWX.js → chunk-7FTQKEZ6.js} +10 -10
  18. package/dist/cli/{chunk-TMCC7ORQ.mjs → chunk-A456YVDE.mjs} +1 -1
  19. package/dist/cli/{chunk-S3WQJ5VG.js → chunk-BJL7RYQN.js} +3 -3
  20. package/dist/cli/{chunk-IHMYIHF4.js → chunk-BNB2RK4L.js} +5 -5
  21. package/dist/cli/{chunk-BSKPQB2P.js → chunk-BYEDI5PM.js} +7 -7
  22. package/dist/cli/{chunk-5DCQWQCP.js → chunk-C4GFBB52.js} +26 -26
  23. package/dist/cli/{chunk-DMNVM34J.js → chunk-DFHS5XVZ.js} +4 -4
  24. package/dist/cli/{chunk-E73JXJA3.mjs → chunk-F3G2HAUQ.mjs} +1 -1
  25. package/dist/cli/{chunk-UQ3LQ6IF.js → chunk-FCAKAW6S.js} +5 -5
  26. package/dist/cli/{chunk-W33OL4F2.mjs → chunk-FGPJXQEJ.mjs} +2 -2
  27. package/dist/cli/{chunk-C6QWRSMQ.js → chunk-FSCOYTRV.js} +6 -6
  28. package/dist/cli/{chunk-NKPTM7SK.js → chunk-GCEUOHJW.js} +7 -7
  29. package/dist/cli/{chunk-3OF7NSGR.js → chunk-KPIVQFXZ.js} +94 -94
  30. package/dist/cli/{chunk-GHHJWCMD.mjs → chunk-MJ56FCYU.mjs} +1 -1
  31. package/dist/cli/{chunk-TVW6USSG.js → chunk-NSPMJLYA.js} +3 -3
  32. package/dist/cli/{chunk-3DBW6C7M.mjs → chunk-P6KGYOCM.mjs} +2 -2
  33. package/dist/cli/{chunk-NLRTFJGH.js → chunk-PCYZDTDC.js} +9 -9
  34. package/dist/cli/{chunk-U6WEGDD3.js → chunk-PHWFY26F.js} +2 -2
  35. package/dist/cli/{chunk-FJY6K3BG.mjs → chunk-PKOFEHZL.mjs} +1 -1
  36. package/dist/cli/{chunk-L352NOE3.mjs → chunk-PQHDZHZG.mjs} +2 -2
  37. package/dist/cli/{chunk-NRNWPWBW.js → chunk-PTM3QRAT.js} +37 -37
  38. package/dist/cli/{chunk-YDA3PMKK.mjs → chunk-PV7AYBKQ.mjs} +2 -2
  39. package/dist/cli/{chunk-ACTUAZYP.mjs → chunk-PYDHVRAF.mjs} +4 -4
  40. package/dist/cli/{chunk-775AZTO7.js → chunk-QD22TY33.js} +7 -7
  41. package/dist/cli/{chunk-EC2CVPN5.js → chunk-QEQ3KHVY.js} +3 -3
  42. package/dist/cli/{chunk-L7IQ3DFH.js → chunk-S5EYODEG.js} +53 -53
  43. package/dist/cli/{chunk-HKGXGGIV.js → chunk-S7OILDJH.js} +1 -1
  44. package/dist/cli/{chunk-G5PI3RNT.mjs → chunk-T3Q6BMVH.mjs} +1 -1
  45. package/dist/cli/{chunk-RZE5I2XJ.mjs → chunk-TBE2K5W4.mjs} +4 -4
  46. package/dist/cli/{chunk-CW6TAQBF.mjs → chunk-TE2QT2MX.mjs} +4 -4
  47. package/dist/cli/{chunk-AFADYKFE.js → chunk-TNHY3ATN.js} +8 -8
  48. package/dist/cli/{chunk-3DYU3JQN.mjs → chunk-U23L57VU.mjs} +2 -2
  49. package/dist/cli/{chunk-VZYTLWOM.mjs → chunk-UEJLWUJ3.mjs} +2 -2
  50. package/dist/cli/{chunk-676NZ7K4.mjs → chunk-VJLL5XIP.mjs} +1 -1
  51. package/dist/cli/{chunk-2ZEQ43B7.mjs → chunk-WCOJH4W4.mjs} +3 -3
  52. package/dist/cli/{chunk-SR6S4EYG.mjs → chunk-XAZWUW6I.mjs} +5 -5
  53. package/dist/cli/{chunk-UPHXGZCE.mjs → chunk-YIKHNZ6B.mjs} +4 -4
  54. package/dist/cli/{chunk-2ILND7XX.js → chunk-YS6JOYYS.js} +2 -2
  55. package/dist/cli/{chunk-62PJ6PK7.mjs → chunk-ZMRZ3BXG.mjs} +5 -5
  56. package/dist/cli/{chunk-OW4OTEFF.js → chunk-ZQI26KE4.js} +16 -16
  57. package/dist/cli/{csv-HFEQPGNY.js → csv-3PSMPZM5.js} +13 -13
  58. package/dist/cli/{csv-OHF3Y5KB.mjs → csv-LFCT3WQ4.mjs} +4 -4
  59. package/dist/cli/{db-M456OUXD.mjs → db-HULKVAMU.mjs} +6 -6
  60. package/dist/cli/{db-VLQKCYQS.js → db-R7I2PPTV.js} +27 -27
  61. package/dist/cli/{describe-M6VXFYVL.mjs → describe-D55V42LH.mjs} +17 -17
  62. package/dist/cli/describe-H47BLOEP.js +49 -0
  63. package/dist/cli/{executions-4FGRBPJF.mjs → executions-ICVVOYVG.mjs} +6 -6
  64. package/dist/cli/{executions-GKINJZI6.js → executions-O37FN2SK.js} +8 -8
  65. package/dist/cli/{feedback-D2WMGK3V.mjs → feedback-3K3QPGCQ.mjs} +4 -4
  66. package/dist/cli/{feedback-ZH5K7WV7.js → feedback-MAZQ7C6S.js} +8 -8
  67. package/dist/cli/{git-OCIJ5ME4.mjs → git-2MMD5KJS.mjs} +5 -5
  68. package/dist/cli/git-RQ2XLFYZ.js +25 -0
  69. package/dist/cli/index.js +137 -137
  70. package/dist/cli/index.mjs +40 -40
  71. package/dist/cli/{legacy-noops-QNIVP7LO.js → legacy-noops-2OX2Y3Y2.js} +8 -8
  72. package/dist/cli/{legacy-noops-V6Q2X34P.mjs → legacy-noops-VLSWJ6VE.mjs} +5 -5
  73. package/dist/cli/{monitors-2USHTG5G.mjs → monitors-2NODQQWG.mjs} +7 -7
  74. package/dist/cli/{monitors-5DNK7W2K.js → monitors-UCSV5FOR.js} +91 -91
  75. package/dist/cli/{org-RPGM5AN4.js → org-4YY73VTW.js} +72 -72
  76. package/dist/cli/{org-TL2YPYSE.mjs → org-W7AUQCDE.mjs} +6 -6
  77. package/dist/cli/{pages-PNUKPFWV.js → pages-FBZEUMXK.js} +17 -17
  78. package/dist/cli/{pages-XDEW6EE3.mjs → pages-ZRP7U5PO.mjs} +6 -6
  79. package/dist/cli/{play-F5LHRKV5.js → play-LFCTQJXA.js} +312 -312
  80. package/dist/cli/{play-WINNQ4HZ.mjs → play-XF2BSGTP.mjs} +17 -17
  81. package/dist/cli/{providers-BD4IS5U5.js → providers-5456JNHP.js} +9 -9
  82. package/dist/cli/{providers-PXGL3FRE.mjs → providers-SICAPKGI.mjs} +6 -6
  83. package/dist/cli/{quickstart-7LVF6HZF.js → quickstart-2KLLIPIU.js} +6 -6
  84. package/dist/cli/{quickstart-XTH3UQWZ.mjs → quickstart-IBVG6GX6.mjs} +4 -4
  85. package/dist/cli/{run-NH2BAWPA.js → run-DNLDGJRC.js} +36 -36
  86. package/dist/cli/{run-MBMUENR7.mjs → run-XPIZIQ7H.mjs} +22 -22
  87. package/dist/cli/search-2KQA65LH.js +32 -0
  88. package/dist/cli/{search-BMRWBV66.mjs → search-PW22AEAL.mjs} +7 -7
  89. package/dist/cli/{search-output-5NNT337U.js → search-output-H6F6QMRF.js} +6 -6
  90. package/dist/cli/{search-output-QKKRD4MF.mjs → search-output-JFD53H2N.mjs} +4 -4
  91. package/dist/cli/{secrets-AWEXBTJV.mjs → secrets-542CTZRZ.mjs} +6 -6
  92. package/dist/cli/{secrets-KQSTOREN.js → secrets-LCCRRAN7.js} +15 -15
  93. package/dist/cli/{sessions-DSPLZYCJ.js → sessions-5FYDQE3N.js} +6 -6
  94. package/dist/cli/{sessions-RO25Q67X.mjs → sessions-CALLS2XD.mjs} +5 -5
  95. package/dist/cli/{settings-JMGXGK4Z.mjs → settings-GSKPHUEC.mjs} +11 -11
  96. package/dist/cli/{settings-7JXIKNKI.js → settings-ORGKOBP6.js} +78 -78
  97. package/dist/cli/{setup-5QFAQQRW.js → setup-4BUWJKB6.js} +47 -47
  98. package/dist/cli/{setup-ZQZ47FHB.mjs → setup-V57GHVAF.mjs} +9 -9
  99. package/dist/cli/skills-KYZPPGSN.js +33 -0
  100. package/dist/cli/{skills-W3H2DL56.mjs → skills-NGLCFQFT.mjs} +7 -7
  101. package/dist/cli/tools-AFYXUEMD.js +56 -0
  102. package/dist/cli/{tools-2BZCVNBS.mjs → tools-G2YNCFNX.mjs} +16 -16
  103. package/dist/cli/{update-GAWYMGAW.mjs → update-IZ3Z5T5C.mjs} +9 -9
  104. package/dist/cli/update-T6JJ7A3K.js +33 -0
  105. package/dist/cli/{workflow-ZPTDFPKW.js → workflow-7AHST2XV.js} +17 -17
  106. package/dist/cli/{workflow-M6LLHQ2I.mjs → workflow-L7ROQIM7.mjs} +7 -7
  107. package/dist/index.js +9 -9
  108. package/dist/index.mjs +6 -6
  109. package/dist/install-integrity.json +98 -98
  110. package/dist/release.d.mts +1 -1
  111. package/dist/release.d.ts +1 -1
  112. package/dist/release.js +2 -2
  113. package/dist/release.mjs +1 -1
  114. package/dist/server.js +5 -5
  115. package/dist/server.mjs +3 -3
  116. package/package.json +1 -1
  117. package/dist/cli/auth-ABZBH55L.js +0 -43
  118. package/dist/cli/describe-CP35DZ5Z.js +0 -49
  119. package/dist/cli/git-IDALMZDN.js +0 -25
  120. package/dist/cli/search-R3MQJQMT.js +0 -32
  121. package/dist/cli/skills-EDZXY7DV.js +0 -33
  122. package/dist/cli/tools-2EY2ETCZ.js +0 -56
  123. package/dist/cli/update-UKDQKNBY.js +0 -33
@@ -205,7 +205,7 @@ export const SDK_RELEASE = {
205
205
  // getters keep their established compatibility behavior.
206
206
  // 0.3.1 deprecated the legacy `deepline enrich` command in favor of Plays.
207
207
  // 0.3.90 is the first deliberately versioned SDK release for API v3.
208
- version: '0.3.485',
208
+ version: '0.3.486',
209
209
  updateSummary: {
210
210
  introducedIn: '0.3.90',
211
211
  summary:
@@ -99,8 +99,12 @@ export function sanitizeLedgerLogLines(value: unknown): string[] {
99
99
  .filter(Boolean);
100
100
  }
101
101
 
102
- /** Runtime measurement records use the terminal transport's existing byte budget. */
103
- export function sanitizeLedgerLogLine(line: string, bounded = true): string {
104
- const redacted = ledgerIngressRedactor.redactString(line.trim());
105
- return bounded ? boundRunLogLine(redacted) : redacted;
102
+ /**
103
+ * The one canonical body of a Run Log line. App live ingress and the
104
+ * scheduler's terminal replay both call this, with no per-path options: a
105
+ * line that reaches the ledger by both paths must hash identically under its
106
+ * origin ID, or search projection quarantines the lane.
107
+ */
108
+ export function sanitizeLedgerLogLine(line: string): string {
109
+ return boundRunLogLine(ledgerIngressRedactor.redactString(line.trim()));
106
110
  }
@@ -1544,6 +1544,14 @@ process.stdout.on('error', (err: NodeJS.ErrnoException) => {
1544
1544
  // instead of polled out of a sidecar file by the worker. Set once in main().
1545
1545
  let runnerProgressPusher: RunnerProgressPusher | null = null;
1546
1546
 
1547
+ /**
1548
+ * Host diagnostic for the progress transport at a runtime deadline. It goes to
1549
+ * stderr like `[play-runner.runtime-deadline]`, not to the customer Run Log.
1550
+ */
1551
+ function logRunnerLogTransport(pusher: RunnerProgressPusher | null): void {
1552
+ console.warn('[runtime.log_transport]', pusher?.snapshot() ?? null);
1553
+ }
1554
+
1547
1555
  function emit(event: PlayRunnerEvent): void {
1548
1556
  emitProgressSidecarEvent(event);
1549
1557
  if (runnerProgressPusher && shouldEmitProgressSidecarEvent(event)) {
@@ -2130,38 +2138,26 @@ async function releaseRuntimeLeasesOnAppRunnerSettlement(input: {
2130
2138
  }
2131
2139
  }
2132
2140
 
2133
- function terminalLogIdsWithPhaseSummary(ctx: {
2134
- getLogIds(): string[];
2135
- }): string[] {
2136
- // Summaries are new occurrences at result construction. Terminal retries
2137
- // reuse that result and its IDs, including the frozen summary bodies.
2138
- return [...ctx.getLogIds(), crypto.randomUUID(), crypto.randomUUID()];
2139
- }
2140
-
2141
- function terminalLogsWithPhaseSummary(ctx: {
2142
- getLogs(): string[];
2143
- getRuntimeResourceSnapshot(): unknown;
2144
- getLogDiagnostics(): unknown;
2145
- }): string[] {
2146
- return [
2147
- ...ctx.getLogs(),
2148
- `[runtime.logs] ${JSON.stringify(ctx.getLogDiagnostics())}`,
2149
- `[runtime.phase_summary] ${JSON.stringify(ctx.getRuntimeResourceSnapshot())}`,
2150
- ];
2141
+ // Runtime measurements travel as structured `stats` (`runtimeResources`,
2142
+ // `runtimeLogBuffer`), never as Run Log lines: a diagnostic line could reach
2143
+ // the ledger by both the live and terminal paths with different bodies.
2144
+ function terminalLogs(ctx: { getLogs(): string[] }): string[] {
2145
+ // A copy: terminal retries reuse this result, aligned with its log IDs.
2146
+ return ctx.getLogs().slice();
2151
2147
  }
2152
2148
 
2153
- function terminalLogMetadataWithPhaseSummary(ctx: {
2149
+ function terminalLogMetadata(ctx: {
2154
2150
  getLogMetadata(): Array<PlayLogMetadata | null>;
2155
2151
  }): Array<PlayLogMetadata | null> | undefined {
2156
2152
  const metadata = ctx.getLogMetadata();
2157
- return metadata.some(Boolean) ? [...metadata, null, null] : undefined;
2153
+ return metadata.some(Boolean) ? metadata : undefined;
2158
2154
  }
2159
2155
 
2160
- function terminalLogContextsWithPhaseSummary(ctx: {
2156
+ function terminalLogContexts(ctx: {
2161
2157
  getLogContexts(): Array<PlayLogContext | null>;
2162
2158
  }): Array<PlayLogContext | null> | undefined {
2163
2159
  const contexts = ctx.getLogContexts();
2164
- return contexts.some(Boolean) ? [...contexts, null, null] : undefined;
2160
+ return contexts.some(Boolean) ? contexts : undefined;
2165
2161
  }
2166
2162
 
2167
2163
  function rowOutcomesFromCheckpoint(checkpoint: {
@@ -3458,6 +3454,7 @@ async function run(
3458
3454
  };
3459
3455
  const runtimeStats = () => ({
3460
3456
  ...ctx.getStats(),
3457
+ runtimeLogBuffer: ctx.getLogDiagnostics(),
3461
3458
  runtimeWorkCounterSegment: {
3462
3459
  invocationSeq: workCounterInvocationSeq,
3463
3460
  segmentId: workCounterSegmentId,
@@ -3471,12 +3468,12 @@ async function run(
3471
3468
  status: 'failed',
3472
3469
  error: runtimeLimitExceededCause(runtimeLimitSeconds),
3473
3470
  errors: [runtimeLimitExceededFailure(runtimeLimitSeconds)],
3474
- logs: terminalLogsWithPhaseSummary(ctx),
3471
+ logs: terminalLogs(ctx),
3475
3472
  ...(config.context.runtimeLogIdentity === 'origin'
3476
- ? { logIds: terminalLogIdsWithPhaseSummary(ctx) }
3473
+ ? { logIds: ctx.getLogIds() }
3477
3474
  : {}),
3478
- logContexts: terminalLogContextsWithPhaseSummary(ctx),
3479
- logMetadata: terminalLogMetadataWithPhaseSummary(ctx),
3475
+ logContexts: terminalLogContexts(ctx),
3476
+ logMetadata: terminalLogMetadata(ctx),
3480
3477
  stats: runtimeStats(),
3481
3478
  steps: ctx.getSteps(),
3482
3479
  tableNamespace: null,
@@ -3695,7 +3692,7 @@ async function run(
3695
3692
  reason: 'completed',
3696
3693
  });
3697
3694
 
3698
- const logs = terminalLogsWithPhaseSummary(ctx);
3695
+ const logs = terminalLogs(ctx);
3699
3696
  const runtimeDiagnostics = Array.from(
3700
3697
  new Map(
3701
3698
  logs
@@ -3721,10 +3718,10 @@ async function run(
3721
3718
  outputRowCount,
3722
3719
  logs,
3723
3720
  ...(config.context.runtimeLogIdentity === 'origin'
3724
- ? { logIds: terminalLogIdsWithPhaseSummary(ctx) }
3721
+ ? { logIds: ctx.getLogIds() }
3725
3722
  : {}),
3726
- logContexts: terminalLogContextsWithPhaseSummary(ctx),
3727
- logMetadata: terminalLogMetadataWithPhaseSummary(ctx),
3723
+ logContexts: terminalLogContexts(ctx),
3724
+ logMetadata: terminalLogMetadata(ctx),
3728
3725
  ...(runtimeDiagnostics.length > 0 ? { runtimeDiagnostics } : {}),
3729
3726
  ...(rowOutcomes ? { rowOutcomes } : {}),
3730
3727
  stats: runtimeStats(),
@@ -3778,12 +3775,12 @@ async function run(
3778
3775
  return {
3779
3776
  status: 'suspended',
3780
3777
  suspension: error.suspension,
3781
- logs: terminalLogsWithPhaseSummary(ctx),
3778
+ logs: terminalLogs(ctx),
3782
3779
  ...(config.context.runtimeLogIdentity === 'origin'
3783
- ? { logIds: terminalLogIdsWithPhaseSummary(ctx) }
3780
+ ? { logIds: ctx.getLogIds() }
3784
3781
  : {}),
3785
- logContexts: terminalLogContextsWithPhaseSummary(ctx),
3786
- logMetadata: terminalLogMetadataWithPhaseSummary(ctx),
3782
+ logContexts: terminalLogContexts(ctx),
3783
+ logMetadata: terminalLogMetadata(ctx),
3787
3784
  stats: runtimeStats(),
3788
3785
  steps: ctx.getSteps(),
3789
3786
  checkpoint: ctx.getCheckpoint(),
@@ -3818,12 +3815,12 @@ async function run(
3818
3815
  status: 'failed',
3819
3816
  error: formatRunnerFailure(error),
3820
3817
  errors: [failure],
3821
- logs: terminalLogsWithPhaseSummary(ctx),
3818
+ logs: terminalLogs(ctx),
3822
3819
  ...(config.context.runtimeLogIdentity === 'origin'
3823
- ? { logIds: terminalLogIdsWithPhaseSummary(ctx) }
3820
+ ? { logIds: ctx.getLogIds() }
3824
3821
  : {}),
3825
- logContexts: terminalLogContextsWithPhaseSummary(ctx),
3826
- logMetadata: terminalLogMetadataWithPhaseSummary(ctx),
3822
+ logContexts: terminalLogContexts(ctx),
3823
+ logMetadata: terminalLogMetadata(ctx),
3827
3824
  ...(rowOutcomes ? { rowOutcomes } : {}),
3828
3825
  stats: runtimeStats(),
3829
3826
  steps: ctx.getSteps(),
@@ -4164,9 +4161,7 @@ async function main() {
4164
4161
  const runtimeDeadline = startConfiguredPlayRunnerRuntimeDeadline({
4165
4162
  config,
4166
4163
  onDrain: (runtimeLimitSeconds) => {
4167
- runtimeState?.log(
4168
- `[runtime.log_transport] ${JSON.stringify(runnerProgressPusher?.snapshot() ?? null)}`,
4169
- );
4164
+ logRunnerLogTransport(runnerProgressPusher);
4170
4165
  runtimeState?.log(
4171
4166
  `Runtime limit approaching (${runtimeLimitSeconds}s configured); stopping new rows and saving started work for up to 4 seconds.`,
4172
4167
  );
@@ -4175,9 +4170,7 @@ async function main() {
4175
4170
  );
4176
4171
  },
4177
4172
  onDeadline: async (runtimeLimitSeconds) => {
4178
- runtimeState?.log(
4179
- `[runtime.log_transport] ${JSON.stringify(runnerProgressPusher?.snapshot() ?? null)}`,
4180
- );
4173
+ logRunnerLogTransport(runnerProgressPusher);
4181
4174
  executionController.abort(
4182
4175
  new Error(
4183
4176
  `Play runner reached its ${runtimeLimitSeconds}-second runtime limit.`,
@@ -5879,7 +5879,8 @@ function detachedRunnerLostResult(input: {
5879
5879
  return {
5880
5880
  status: 'failed',
5881
5881
  error: `RUNTIME_RUNNER_LOST: Detached runner heartbeat expired after ${input.heartbeatAgeMs ?? 'unknown'}ms without a terminal result. Deepline did not automatically retry because external actions may already have completed.`,
5882
- logs: [`[runtime.failure_diagnostic] ${JSON.stringify(runnerLiveness)}`],
5882
+ // The diagnostic is structured `stats`; the Run Log carries no copy.
5883
+ logs: [],
5883
5884
  stats: { runnerLiveness },
5884
5885
  steps: [],
5885
5886
  checkpoint: null,
@@ -295,15 +295,8 @@ function shouldPublishTerminalResultLog(
295
295
  line: string,
296
296
  ): boolean {
297
297
  // Direct workers keep host lifecycle noise out of the customer Run Log
298
- // Stream. The resource summary is one bounded, machine-readable terminal
299
- // diagnostic rather than a host log, though: the fixture harness needs it
300
- // after the runner has gone away and the normal terminal result is no longer
301
- // available through the status projection.
302
- return (
303
- mode !== 'direct_worker' ||
304
- CTX_LOG_TIMESTAMP_PREFIX_RE.test(line) ||
305
- line.startsWith('[runtime.phase_summary] ')
306
- );
298
+ // Stream. Runtime measurements travel as structured stats, not log lines.
299
+ return mode !== 'direct_worker' || CTX_LOG_TIMESTAMP_PREFIX_RE.test(line);
307
300
  }
308
301
 
309
302
  type TerminalLogReplayPayload = NonNullable<
@@ -15009,7 +15009,7 @@ export async function completePostgresSchedulerAttempt(
15009
15009
  );
15010
15010
  const terminalLogEntries = (input.terminalLogLines ?? [])
15011
15011
  .map((line, index) => ({
15012
- line: sanitizeTerminalLogBody(line),
15012
+ line: sanitizeLedgerLogLine(line),
15013
15013
  context: input.terminalLogContexts?.[index] ?? null,
15014
15014
  metadata: input.terminalLogMetadata?.[index] ?? null,
15015
15015
  entryId: terminalLogIds?.[index] ?? null,
@@ -15341,7 +15341,7 @@ export async function failPostgresSchedulerAttempt(
15341
15341
  );
15342
15342
  const terminalLogEntries = (input.terminalLogLines ?? [])
15343
15343
  .map((line, index) => ({
15344
- line: sanitizeTerminalLogBody(line),
15344
+ line: sanitizeLedgerLogLine(line),
15345
15345
  context: input.terminalLogContexts?.[index] ?? null,
15346
15346
  metadata: input.terminalLogMetadata?.[index] ?? null,
15347
15347
  entryId: terminalLogIds?.[index] ?? null,
@@ -16501,26 +16501,13 @@ function sanitizeTerminalProgressEvents(
16501
16501
  // Invalid values still reach the existing SQL validation unchanged.
16502
16502
  lines: item.lines.map((line) =>
16503
16503
  typeof line === 'string'
16504
- ? sanitizeTerminalLogBody(line) || '(blank log line)'
16504
+ ? sanitizeLedgerLogLine(line) || '(blank log line)'
16505
16505
  : line,
16506
16506
  ),
16507
16507
  };
16508
16508
  });
16509
16509
  }
16510
16510
 
16511
- function sanitizeTerminalLogBody(line: string): string {
16512
- const body = line.trim();
16513
- const runtimeDiagnostic =
16514
- body.startsWith('[runtime.failure_diagnostic] ') ||
16515
- body.startsWith('[runtime.phase_summary] ') ||
16516
- body.startsWith('[runtime.logs] ') ||
16517
- body.startsWith('[runtime.log_transport] ');
16518
- // These runtime records contain machine-readable JSON, already bounded by
16519
- // the terminal transport. Keep it parseable while applying the same redaction.
16520
- // Authored tagged lines retain the ordinary live-ingress line bound.
16521
- return sanitizeLedgerLogLine(body, !runtimeDiagnostic);
16522
- }
16523
-
16524
16511
  /**
16525
16512
  * One error line stating why a run failed. `message` must be the public failure
16526
16513
  * text. The line ID keeps it out of the envelope's position space, where a
@@ -16601,19 +16588,13 @@ function terminalLogProjectionForOutbox(
16601
16588
  .map((line, index) => {
16602
16589
  if (typeof line !== 'string') return null;
16603
16590
  const normalized = readProvenanceTag(line).line.trim();
16604
- // Retain bounded terminal measurement summaries alongside timestamped
16605
- // customer/recovery lines after a detached runner has exited.
16606
- const retained =
16607
- CTX_LOG_TIMESTAMP_PREFIX_RE.test(normalized) ||
16608
- normalized.startsWith('[runtime.failure_diagnostic] ') ||
16609
- normalized.startsWith('[runtime.phase_summary] ') ||
16610
- normalized.startsWith('[runtime.logs] ') ||
16611
- normalized.startsWith('[runtime.log_transport] ');
16612
- if (!retained) return null;
16591
+ // Retain timestamped customer/recovery lines after a detached runner
16592
+ // has exited. Runtime measurements travel as structured stats.
16593
+ if (!CTX_LOG_TIMESTAMP_PREFIX_RE.test(normalized)) return null;
16613
16594
  return {
16614
16595
  // The live API applies this same canonicalization before indexing.
16615
16596
  // Replaying an origin ID must carry that exact redacted, bounded body.
16616
- line: sanitizeTerminalLogBody(line),
16597
+ line: sanitizeLedgerLogLine(line),
16617
16598
  context: normalizePlayLogContext(logContexts?.[index]),
16618
16599
  metadata: normalizePlayLogMetadata(logMetadata?.[index]),
16619
16600
  entryId: logIds?.[index] ?? null,
@@ -0,0 +1,43 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
+
3
+
4
+
5
+
6
+
7
+
8
+
9
+
10
+
11
+
12
+
13
+
14
+
15
+
16
+
17
+ var _chunkS5EYODEGjs = require('./chunk-S5EYODEG.js');
18
+ require('./chunk-BYEDI5PM.js');
19
+ require('./chunk-BJL7RYQN.js');
20
+ require('./chunk-DFHS5XVZ.js');
21
+ require('./chunk-ALJJRZNJ.js');
22
+ require('./chunk-XNYIZMNQ.js');
23
+ require('./chunk-DIAWYWT5.js');
24
+ require('./chunk-S7OILDJH.js');
25
+ require('./chunk-OG64RBAC.js');
26
+ require('./chunk-COGTRVWW.js');
27
+
28
+
29
+
30
+
31
+
32
+
33
+
34
+
35
+
36
+
37
+
38
+
39
+
40
+
41
+
42
+
43
+ exports.EXIT_WORKSPACE_MISMATCH = _chunkS5EYODEGjs.EXIT_WORKSPACE_MISMATCH; exports.authStatusLine = _chunkS5EYODEGjs.authStatusLine; exports.clearPendingClaim = _chunkS5EYODEGjs.clearPendingClaim; exports.clearSatisfiedPendingClaim = _chunkS5EYODEGjs.clearSatisfiedPendingClaim; exports.handleRegister = _chunkS5EYODEGjs.handleRegister; exports.handleStatus = _chunkS5EYODEGjs.handleStatus; exports.handleWait = _chunkS5EYODEGjs.handleWait; exports.httpJson = _chunkS5EYODEGjs.httpJson; exports.readPendingAuthClaim = _chunkS5EYODEGjs.readPendingAuthClaim; exports.readStatusBanner = _chunkS5EYODEGjs.readStatusBanner; exports.registerAuthCommands = _chunkS5EYODEGjs.registerAuthCommands; exports.reportApprovalLinkShown = _chunkS5EYODEGjs.reportApprovalLinkShown; exports.reportSetupCompleted = _chunkS5EYODEGjs.reportSetupCompleted; exports.resolvePendingAuthClaimForResume = _chunkS5EYODEGjs.resolvePendingAuthClaimForResume; exports.statusBannerLine = _chunkS5EYODEGjs.statusBannerLine;
@@ -14,14 +14,14 @@ import {
14
14
  reportSetupCompleted,
15
15
  resolvePendingAuthClaimForResume,
16
16
  statusBannerLine
17
- } from "./chunk-2ZEQ43B7.mjs";
18
- import "./chunk-L352NOE3.mjs";
19
- import "./chunk-G5PI3RNT.mjs";
20
- import "./chunk-GHHJWCMD.mjs";
17
+ } from "./chunk-WCOJH4W4.mjs";
18
+ import "./chunk-PQHDZHZG.mjs";
19
+ import "./chunk-T3Q6BMVH.mjs";
20
+ import "./chunk-MJ56FCYU.mjs";
21
21
  import "./chunk-4QF2K7TM.mjs";
22
22
  import "./chunk-DLIRSHV6.mjs";
23
23
  import "./chunk-HBL4PM5Q.mjs";
24
- import "./chunk-TSCUWWTM.mjs";
24
+ import "./chunk-5RLVCOKH.mjs";
25
25
  import "./chunk-WZYKRD7T.mjs";
26
26
  import "./chunk-KRD6H754.mjs";
27
27
  export {