deepline 0.3.271 → 0.3.272
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/bundling-sources/sdk/src/release.ts +1 -1
- package/dist/bundling-sources/shared_libs/play-runtime/activity-observation.ts +3 -2
- package/dist/bundling-sources/shared_libs/play-runtime/app-runtime-api.ts +11 -9
- package/dist/bundling-sources/shared_libs/play-runtime/context.ts +5 -4
- package/dist/bundling-sources/shared_libs/play-runtime/ctx-types.ts +2 -1
- package/dist/bundling-sources/shared_libs/play-runtime/run-event-catalog.ts +610 -0
- package/dist/bundling-sources/shared_libs/play-runtime/run-ledger-event-transport.ts +3 -1
- package/dist/bundling-sources/shared_libs/play-runtime/run-ledger-projection-diagnostics.ts +3 -2
- package/dist/bundling-sources/shared_libs/play-runtime/run-ledger.ts +80 -67
- package/dist/bundling-sources/shared_libs/play-runtime/runner-app/index.ts +5 -4
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/absurd-shared.ts +3 -2
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres-progress.ts +19 -9
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/postgres.ts +103 -78
- package/dist/bundling-sources/shared_libs/play-runtime/scheduler-backends/runtime-event-search.ts +125 -81
- package/dist/cli/index.js +429 -3
- package/dist/cli/index.mjs +429 -3
- package/dist/index.js +420 -1
- package/dist/index.mjs +420 -1
- package/dist/install-integrity.json +1 -0
- package/dist/release.d.mts +1 -1
- package/dist/release.d.ts +1 -1
- package/dist/release.js +1 -1
- package/dist/release.mjs +1 -1
- package/package.json +1 -1
package/dist/cli/index.mjs
CHANGED
|
@@ -3507,7 +3507,7 @@ var SDK_RELEASE = {
|
|
|
3507
3507
|
// getters keep their established compatibility behavior.
|
|
3508
3508
|
// 0.3.1 deprecated the legacy `deepline enrich` command in favor of Plays.
|
|
3509
3509
|
// 0.3.90 is the first deliberately versioned SDK release for API v3.
|
|
3510
|
-
version: "0.3.
|
|
3510
|
+
version: "0.3.272",
|
|
3511
3511
|
updateSummary: "Play grep now returns concise results with the matched fields and terms. Automatic CLI updates are enabled by default; use `deepline settings autoupdate off` to opt out, `deepline settings autoupdate on` to re-enable updates, or `deepline settings autoupdate pin <version>` to hold an exact release.",
|
|
3512
3512
|
packageCapabilities: {
|
|
3513
3513
|
updatePreferences: 1
|
|
@@ -5221,6 +5221,425 @@ var ledgerIngressRedactor = createSecretRedactionContext();
|
|
|
5221
5221
|
var utf8Encoder = new TextEncoder();
|
|
5222
5222
|
var PLAY_DATASET_BRAND = Symbol.for("deepline.play.dataset");
|
|
5223
5223
|
|
|
5224
|
+
// ../play-runtime/run-event-catalog.ts
|
|
5225
|
+
var RUN_EVENT_KIND = {
|
|
5226
|
+
runCreated: "run.created",
|
|
5227
|
+
runStarted: "run.started",
|
|
5228
|
+
runWaiting: "run.waiting",
|
|
5229
|
+
runResumed: "run.resumed",
|
|
5230
|
+
runCompleted: "run.completed",
|
|
5231
|
+
runFailed: "run.failed",
|
|
5232
|
+
runCancelled: "run.cancelled",
|
|
5233
|
+
stepStarted: "step.started",
|
|
5234
|
+
stepProgress: "step.progress",
|
|
5235
|
+
stepCompleted: "step.completed",
|
|
5236
|
+
stepFailed: "step.failed",
|
|
5237
|
+
stepSkipped: "step.skipped",
|
|
5238
|
+
logAppended: "log.appended",
|
|
5239
|
+
datasetLifecycle: "dataset.lifecycle",
|
|
5240
|
+
activityObserved: "activity.observed",
|
|
5241
|
+
workCounters: "work.counters"
|
|
5242
|
+
};
|
|
5243
|
+
var SEARCHABLE_EVENT_FIELDS = [
|
|
5244
|
+
"kind",
|
|
5245
|
+
"runId",
|
|
5246
|
+
"playName",
|
|
5247
|
+
"source",
|
|
5248
|
+
"occurredAt"
|
|
5249
|
+
];
|
|
5250
|
+
var RUN_SNAPSHOT_DESTINATION = {
|
|
5251
|
+
searchIndex: "planet_scale_runtime_event_index",
|
|
5252
|
+
markedRunStore: "planet_scale",
|
|
5253
|
+
planetScaleContent: "event_payload",
|
|
5254
|
+
convexProjection: "run_snapshot",
|
|
5255
|
+
convexRetainedFacts: ["saved_play_rollup_if_eligible"],
|
|
5256
|
+
legacyConvexDestination: "run_ledger_history",
|
|
5257
|
+
explanation: "PlanetScale retains the complete event. Convex reduces it into bounded current run state and keeps only selected saved-Play rollup facts when eligible; unmarked legacy runs retain Convex event history."
|
|
5258
|
+
};
|
|
5259
|
+
var RUN_CREATED_DESTINATION = {
|
|
5260
|
+
...RUN_SNAPSHOT_DESTINATION,
|
|
5261
|
+
convexRetainedFacts: ["admission_fence", "saved_play_rollup_if_eligible"],
|
|
5262
|
+
explanation: "PlanetScale retains the complete event. Convex uses it for the live run snapshot, retains the admission fence, and may retain a saved-Play rollup fact; unmarked legacy runs retain Convex event history."
|
|
5263
|
+
};
|
|
5264
|
+
var RUN_LOG_DESTINATION = {
|
|
5265
|
+
searchIndex: "planet_scale_runtime_event_index",
|
|
5266
|
+
markedRunStore: "planet_scale",
|
|
5267
|
+
planetScaleContent: "log_body",
|
|
5268
|
+
convexProjection: null,
|
|
5269
|
+
convexRetainedFacts: [],
|
|
5270
|
+
legacyConvexDestination: "run_log_stream",
|
|
5271
|
+
explanation: "PlanetScale retains the canonical log line and its search metadata. Marked-run log bodies are not copied into Convex; unmarked legacy runs continue to use the Convex Run Log Stream."
|
|
5272
|
+
};
|
|
5273
|
+
var RUN_EVENT_KIND_CATALOG = {
|
|
5274
|
+
[RUN_EVENT_KIND.runCreated]: {
|
|
5275
|
+
description: "The run was admitted and received its run ID.",
|
|
5276
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5277
|
+
outboxCarriers: ["run.created"],
|
|
5278
|
+
destination: RUN_CREATED_DESTINATION,
|
|
5279
|
+
example: {
|
|
5280
|
+
runId: "play/enrich/run/abc123",
|
|
5281
|
+
type: RUN_EVENT_KIND.runCreated,
|
|
5282
|
+
seq: 1
|
|
5283
|
+
}
|
|
5284
|
+
},
|
|
5285
|
+
[RUN_EVENT_KIND.runStarted]: {
|
|
5286
|
+
description: "The run began execution.",
|
|
5287
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5288
|
+
outboxCarriers: ["run.started"],
|
|
5289
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5290
|
+
example: {
|
|
5291
|
+
runId: "play/enrich/run/abc123",
|
|
5292
|
+
type: RUN_EVENT_KIND.runStarted,
|
|
5293
|
+
seq: 2
|
|
5294
|
+
}
|
|
5295
|
+
},
|
|
5296
|
+
[RUN_EVENT_KIND.runWaiting]: {
|
|
5297
|
+
description: "The run entered a durable wait.",
|
|
5298
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5299
|
+
outboxCarriers: ["run.waiting"],
|
|
5300
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5301
|
+
example: {
|
|
5302
|
+
runId: "play/enrich/run/abc123",
|
|
5303
|
+
type: RUN_EVENT_KIND.runWaiting,
|
|
5304
|
+
waitKind: "sleep"
|
|
5305
|
+
}
|
|
5306
|
+
},
|
|
5307
|
+
[RUN_EVENT_KIND.runResumed]: {
|
|
5308
|
+
description: "The run resumed after a durable wait.",
|
|
5309
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5310
|
+
outboxCarriers: ["run.resumed"],
|
|
5311
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5312
|
+
example: {
|
|
5313
|
+
runId: "play/enrich/run/abc123",
|
|
5314
|
+
type: RUN_EVENT_KIND.runResumed
|
|
5315
|
+
}
|
|
5316
|
+
},
|
|
5317
|
+
[RUN_EVENT_KIND.runCompleted]: {
|
|
5318
|
+
description: "The run completed successfully.",
|
|
5319
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5320
|
+
outboxCarriers: ["run.completed", "runner.logs"],
|
|
5321
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5322
|
+
example: {
|
|
5323
|
+
runId: "play/enrich/run/abc123",
|
|
5324
|
+
type: RUN_EVENT_KIND.runCompleted
|
|
5325
|
+
}
|
|
5326
|
+
},
|
|
5327
|
+
[RUN_EVENT_KIND.runFailed]: {
|
|
5328
|
+
description: "The run ended with a failure.",
|
|
5329
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5330
|
+
outboxCarriers: ["run.failed", "runner.logs"],
|
|
5331
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5332
|
+
example: {
|
|
5333
|
+
runId: "play/enrich/run/abc123",
|
|
5334
|
+
type: RUN_EVENT_KIND.runFailed,
|
|
5335
|
+
error: "Request timed out"
|
|
5336
|
+
}
|
|
5337
|
+
},
|
|
5338
|
+
[RUN_EVENT_KIND.runCancelled]: {
|
|
5339
|
+
description: "The run was cancelled.",
|
|
5340
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5341
|
+
outboxCarriers: ["run.cancelled"],
|
|
5342
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5343
|
+
example: {
|
|
5344
|
+
runId: "play/enrich/run/abc123",
|
|
5345
|
+
type: RUN_EVENT_KIND.runCancelled
|
|
5346
|
+
}
|
|
5347
|
+
},
|
|
5348
|
+
[RUN_EVENT_KIND.stepStarted]: {
|
|
5349
|
+
description: "A named step began execution.",
|
|
5350
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5351
|
+
outboxCarriers: [
|
|
5352
|
+
"run.events",
|
|
5353
|
+
"run.completed",
|
|
5354
|
+
"run.failed",
|
|
5355
|
+
"runner.logs"
|
|
5356
|
+
],
|
|
5357
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5358
|
+
example: {
|
|
5359
|
+
runId: "play/enrich/run/abc123",
|
|
5360
|
+
type: RUN_EVENT_KIND.stepStarted,
|
|
5361
|
+
stepId: "lookup"
|
|
5362
|
+
}
|
|
5363
|
+
},
|
|
5364
|
+
[RUN_EVENT_KIND.stepProgress]: {
|
|
5365
|
+
description: "A named step reported progress.",
|
|
5366
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5367
|
+
outboxCarriers: [
|
|
5368
|
+
"run.events",
|
|
5369
|
+
"run.completed",
|
|
5370
|
+
"run.failed",
|
|
5371
|
+
"runner.logs"
|
|
5372
|
+
],
|
|
5373
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5374
|
+
example: {
|
|
5375
|
+
runId: "play/enrich/run/abc123",
|
|
5376
|
+
type: RUN_EVENT_KIND.stepProgress,
|
|
5377
|
+
stepId: "lookup"
|
|
5378
|
+
}
|
|
5379
|
+
},
|
|
5380
|
+
[RUN_EVENT_KIND.stepCompleted]: {
|
|
5381
|
+
description: "A named step completed.",
|
|
5382
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5383
|
+
outboxCarriers: [
|
|
5384
|
+
"run.events",
|
|
5385
|
+
"run.completed",
|
|
5386
|
+
"run.failed",
|
|
5387
|
+
"runner.logs"
|
|
5388
|
+
],
|
|
5389
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5390
|
+
example: {
|
|
5391
|
+
runId: "play/enrich/run/abc123",
|
|
5392
|
+
type: RUN_EVENT_KIND.stepCompleted,
|
|
5393
|
+
stepId: "lookup"
|
|
5394
|
+
}
|
|
5395
|
+
},
|
|
5396
|
+
[RUN_EVENT_KIND.stepFailed]: {
|
|
5397
|
+
description: "A named step failed.",
|
|
5398
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5399
|
+
outboxCarriers: [
|
|
5400
|
+
"run.events",
|
|
5401
|
+
"run.completed",
|
|
5402
|
+
"run.failed",
|
|
5403
|
+
"runner.logs"
|
|
5404
|
+
],
|
|
5405
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5406
|
+
example: {
|
|
5407
|
+
runId: "play/enrich/run/abc123",
|
|
5408
|
+
type: RUN_EVENT_KIND.stepFailed,
|
|
5409
|
+
stepId: "lookup"
|
|
5410
|
+
}
|
|
5411
|
+
},
|
|
5412
|
+
[RUN_EVENT_KIND.stepSkipped]: {
|
|
5413
|
+
description: "A named step was skipped.",
|
|
5414
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5415
|
+
outboxCarriers: [
|
|
5416
|
+
"run.events",
|
|
5417
|
+
"run.completed",
|
|
5418
|
+
"run.failed",
|
|
5419
|
+
"runner.logs"
|
|
5420
|
+
],
|
|
5421
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5422
|
+
example: {
|
|
5423
|
+
runId: "play/enrich/run/abc123",
|
|
5424
|
+
type: RUN_EVENT_KIND.stepSkipped,
|
|
5425
|
+
stepId: "lookup"
|
|
5426
|
+
}
|
|
5427
|
+
},
|
|
5428
|
+
[RUN_EVENT_KIND.logAppended]: {
|
|
5429
|
+
description: "A text log line was appended to the unified run history and log view.",
|
|
5430
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5431
|
+
outboxCarriers: [
|
|
5432
|
+
"run.events",
|
|
5433
|
+
"run.waiting",
|
|
5434
|
+
"run.resumed",
|
|
5435
|
+
"run.completed",
|
|
5436
|
+
"run.failed",
|
|
5437
|
+
"runner.logs",
|
|
5438
|
+
"run.wait_timeout"
|
|
5439
|
+
],
|
|
5440
|
+
destination: RUN_LOG_DESTINATION,
|
|
5441
|
+
example: {
|
|
5442
|
+
runId: "play/enrich/run/abc123",
|
|
5443
|
+
type: RUN_EVENT_KIND.logAppended,
|
|
5444
|
+
lines: ["Waiting for integration_event:contact.updated."]
|
|
5445
|
+
}
|
|
5446
|
+
},
|
|
5447
|
+
[RUN_EVENT_KIND.datasetLifecycle]: {
|
|
5448
|
+
description: "A run dataset was registered, made available, or failed.",
|
|
5449
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5450
|
+
outboxCarriers: [
|
|
5451
|
+
"run.events",
|
|
5452
|
+
"run.completed",
|
|
5453
|
+
"run.failed",
|
|
5454
|
+
"runner.logs"
|
|
5455
|
+
],
|
|
5456
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5457
|
+
example: {
|
|
5458
|
+
runId: "play/enrich/run/abc123",
|
|
5459
|
+
type: RUN_EVENT_KIND.datasetLifecycle,
|
|
5460
|
+
phase: "available"
|
|
5461
|
+
}
|
|
5462
|
+
},
|
|
5463
|
+
[RUN_EVENT_KIND.activityObserved]: {
|
|
5464
|
+
description: "The runtime recorded an activity observation.",
|
|
5465
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5466
|
+
outboxCarriers: [
|
|
5467
|
+
"run.events",
|
|
5468
|
+
"run.completed",
|
|
5469
|
+
"run.failed",
|
|
5470
|
+
"runner.logs"
|
|
5471
|
+
],
|
|
5472
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5473
|
+
example: {
|
|
5474
|
+
runId: "play/enrich/run/abc123",
|
|
5475
|
+
type: RUN_EVENT_KIND.activityObserved
|
|
5476
|
+
}
|
|
5477
|
+
},
|
|
5478
|
+
[RUN_EVENT_KIND.workCounters]: {
|
|
5479
|
+
description: "A work segment reported logical call, provider request, and rate-limit counters.",
|
|
5480
|
+
searchableFields: SEARCHABLE_EVENT_FIELDS,
|
|
5481
|
+
outboxCarriers: [
|
|
5482
|
+
"run.events",
|
|
5483
|
+
"run.completed",
|
|
5484
|
+
"run.failed",
|
|
5485
|
+
"runner.logs"
|
|
5486
|
+
],
|
|
5487
|
+
destination: RUN_SNAPSHOT_DESTINATION,
|
|
5488
|
+
example: {
|
|
5489
|
+
runId: "play/enrich/run/abc123",
|
|
5490
|
+
type: RUN_EVENT_KIND.workCounters,
|
|
5491
|
+
attempt: 1,
|
|
5492
|
+
logicalCalls: 4,
|
|
5493
|
+
providerRequests: 4,
|
|
5494
|
+
provider429s: 0,
|
|
5495
|
+
final: true
|
|
5496
|
+
}
|
|
5497
|
+
}
|
|
5498
|
+
};
|
|
5499
|
+
var RUN_EVENT_KINDS = Object.freeze(
|
|
5500
|
+
Object.keys(RUN_EVENT_KIND_CATALOG)
|
|
5501
|
+
);
|
|
5502
|
+
var RUN_SCHEDULER_OUTBOX_EVENT_TYPE = {
|
|
5503
|
+
runCreated: RUN_EVENT_KIND.runCreated,
|
|
5504
|
+
runStarted: RUN_EVENT_KIND.runStarted,
|
|
5505
|
+
runWaiting: RUN_EVENT_KIND.runWaiting,
|
|
5506
|
+
runResumed: RUN_EVENT_KIND.runResumed,
|
|
5507
|
+
runCompleted: RUN_EVENT_KIND.runCompleted,
|
|
5508
|
+
runFailed: RUN_EVENT_KIND.runFailed,
|
|
5509
|
+
runCancelled: RUN_EVENT_KIND.runCancelled,
|
|
5510
|
+
runEvents: "run.events",
|
|
5511
|
+
runnerLogs: "runner.logs",
|
|
5512
|
+
runWaitTimeout: "run.wait_timeout"
|
|
5513
|
+
};
|
|
5514
|
+
var RUN_SCHEDULER_OUTBOX_EVENT_TYPES = Object.freeze(
|
|
5515
|
+
Object.values(RUN_SCHEDULER_OUTBOX_EVENT_TYPE)
|
|
5516
|
+
);
|
|
5517
|
+
var RUN_SCHEDULER_OUTBOX_START_EVENT_TYPES = [
|
|
5518
|
+
RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runCreated,
|
|
5519
|
+
RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runStarted
|
|
5520
|
+
];
|
|
5521
|
+
var RUN_SCHEDULER_OUTBOX_PREFIX_STOP_EVENT_TYPES = [
|
|
5522
|
+
...RUN_SCHEDULER_OUTBOX_START_EVENT_TYPES,
|
|
5523
|
+
RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runEvents
|
|
5524
|
+
];
|
|
5525
|
+
var RUN_SCHEDULER_OUTBOX_TERMINAL_EVENT_TYPES = [
|
|
5526
|
+
RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runCompleted,
|
|
5527
|
+
RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runFailed,
|
|
5528
|
+
RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runCancelled
|
|
5529
|
+
];
|
|
5530
|
+
var RUN_EVENT_CONVEX_INTERNAL_KIND = {
|
|
5531
|
+
rollupMembershipAdded: "rollup.membership.added",
|
|
5532
|
+
rollupMembershipRemoved: "rollup.membership.removed"
|
|
5533
|
+
};
|
|
5534
|
+
var RUN_RECEIPT_SEARCH_KIND = {
|
|
5535
|
+
completed: "receipt.completed",
|
|
5536
|
+
failed: "receipt.failed",
|
|
5537
|
+
skipped: "receipt.skipped"
|
|
5538
|
+
};
|
|
5539
|
+
var RUN_RECEIPT_SEARCH_KIND_CATALOG = {
|
|
5540
|
+
[RUN_RECEIPT_SEARCH_KIND.completed]: {
|
|
5541
|
+
description: "A durable work receipt completed.",
|
|
5542
|
+
searchIndex: "planet_scale_runtime_event_index",
|
|
5543
|
+
payloadStore: "authoritative_work_receipt"
|
|
5544
|
+
},
|
|
5545
|
+
[RUN_RECEIPT_SEARCH_KIND.failed]: {
|
|
5546
|
+
description: "A durable work receipt failed.",
|
|
5547
|
+
searchIndex: "planet_scale_runtime_event_index",
|
|
5548
|
+
payloadStore: "authoritative_work_receipt"
|
|
5549
|
+
},
|
|
5550
|
+
[RUN_RECEIPT_SEARCH_KIND.skipped]: {
|
|
5551
|
+
description: "A durable work receipt was skipped.",
|
|
5552
|
+
searchIndex: "planet_scale_runtime_event_index",
|
|
5553
|
+
payloadStore: "authoritative_work_receipt"
|
|
5554
|
+
}
|
|
5555
|
+
};
|
|
5556
|
+
var RUN_EVENT_SEARCH_FALLBACK_KIND = "runtime.event";
|
|
5557
|
+
var RUN_EVENT_SEARCH_KIND_VALUES = Object.freeze([
|
|
5558
|
+
...RUN_EVENT_KINDS,
|
|
5559
|
+
...Object.keys(RUN_RECEIPT_SEARCH_KIND_CATALOG),
|
|
5560
|
+
RUN_EVENT_SEARCH_FALLBACK_KIND
|
|
5561
|
+
]);
|
|
5562
|
+
var RUN_EVENT_TERMINAL_KIND_VALUES = [
|
|
5563
|
+
RUN_EVENT_KIND.runCompleted,
|
|
5564
|
+
RUN_EVENT_KIND.runFailed,
|
|
5565
|
+
RUN_EVENT_KIND.runCancelled
|
|
5566
|
+
];
|
|
5567
|
+
var RUN_LOG_RETENTION_MAX_BYTES = 5 * 1024 * 1024;
|
|
5568
|
+
function sqlStringLiteral(value) {
|
|
5569
|
+
return "'" + value.replaceAll("'", "''") + "'";
|
|
5570
|
+
}
|
|
5571
|
+
var RUN_EVENT_KNOWN_KIND_SQL_LIST = RUN_EVENT_KINDS.map(sqlStringLiteral).join(", ");
|
|
5572
|
+
var RUN_EVENT_LIFECYCLE_KIND_SQL_LIST = [
|
|
5573
|
+
RUN_EVENT_KIND.runCreated,
|
|
5574
|
+
RUN_EVENT_KIND.runStarted,
|
|
5575
|
+
RUN_EVENT_KIND.runWaiting,
|
|
5576
|
+
RUN_EVENT_KIND.runResumed,
|
|
5577
|
+
RUN_EVENT_KIND.runCompleted,
|
|
5578
|
+
RUN_EVENT_KIND.runFailed,
|
|
5579
|
+
RUN_EVENT_KIND.runCancelled
|
|
5580
|
+
].map(sqlStringLiteral).join(", ");
|
|
5581
|
+
var RUN_EVENT_SNAPSHOT_KIND_SQL_LIST = RUN_EVENT_KINDS.filter(
|
|
5582
|
+
(kind) => kind !== RUN_EVENT_KIND.logAppended
|
|
5583
|
+
).map(sqlStringLiteral).join(", ");
|
|
5584
|
+
var RUN_EVENT_KIND_SQL_LITERAL = {
|
|
5585
|
+
runCreated: sqlStringLiteral(RUN_EVENT_KIND.runCreated),
|
|
5586
|
+
runStarted: sqlStringLiteral(RUN_EVENT_KIND.runStarted),
|
|
5587
|
+
runWaiting: sqlStringLiteral(RUN_EVENT_KIND.runWaiting),
|
|
5588
|
+
runResumed: sqlStringLiteral(RUN_EVENT_KIND.runResumed),
|
|
5589
|
+
runCompleted: sqlStringLiteral(RUN_EVENT_KIND.runCompleted),
|
|
5590
|
+
runFailed: sqlStringLiteral(RUN_EVENT_KIND.runFailed),
|
|
5591
|
+
runCancelled: sqlStringLiteral(RUN_EVENT_KIND.runCancelled),
|
|
5592
|
+
stepStarted: sqlStringLiteral(RUN_EVENT_KIND.stepStarted),
|
|
5593
|
+
stepProgress: sqlStringLiteral(RUN_EVENT_KIND.stepProgress),
|
|
5594
|
+
stepCompleted: sqlStringLiteral(RUN_EVENT_KIND.stepCompleted),
|
|
5595
|
+
stepFailed: sqlStringLiteral(RUN_EVENT_KIND.stepFailed),
|
|
5596
|
+
stepSkipped: sqlStringLiteral(RUN_EVENT_KIND.stepSkipped),
|
|
5597
|
+
logAppended: sqlStringLiteral(RUN_EVENT_KIND.logAppended),
|
|
5598
|
+
datasetLifecycle: sqlStringLiteral(RUN_EVENT_KIND.datasetLifecycle),
|
|
5599
|
+
activityObserved: sqlStringLiteral(RUN_EVENT_KIND.activityObserved),
|
|
5600
|
+
workCounters: sqlStringLiteral(RUN_EVENT_KIND.workCounters)
|
|
5601
|
+
};
|
|
5602
|
+
var RUN_SCHEDULER_OUTBOX_EVENT_TYPE_SQL_LITERAL = {
|
|
5603
|
+
runCreated: sqlStringLiteral(RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runCreated),
|
|
5604
|
+
runStarted: sqlStringLiteral(RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runStarted),
|
|
5605
|
+
runWaiting: sqlStringLiteral(RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runWaiting),
|
|
5606
|
+
runResumed: sqlStringLiteral(RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runResumed),
|
|
5607
|
+
runCompleted: sqlStringLiteral(RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runCompleted),
|
|
5608
|
+
runFailed: sqlStringLiteral(RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runFailed),
|
|
5609
|
+
runCancelled: sqlStringLiteral(RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runCancelled),
|
|
5610
|
+
runEvents: sqlStringLiteral(RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runEvents),
|
|
5611
|
+
runnerLogs: sqlStringLiteral(RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runnerLogs),
|
|
5612
|
+
runWaitTimeout: sqlStringLiteral(
|
|
5613
|
+
RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runWaitTimeout
|
|
5614
|
+
)
|
|
5615
|
+
};
|
|
5616
|
+
var RUN_EVENT_CONVEX_INTERNAL_KIND_SQL_LITERAL = {
|
|
5617
|
+
rollupMembershipAdded: sqlStringLiteral(
|
|
5618
|
+
RUN_EVENT_CONVEX_INTERNAL_KIND.rollupMembershipAdded
|
|
5619
|
+
),
|
|
5620
|
+
rollupMembershipRemoved: sqlStringLiteral(
|
|
5621
|
+
RUN_EVENT_CONVEX_INTERNAL_KIND.rollupMembershipRemoved
|
|
5622
|
+
)
|
|
5623
|
+
};
|
|
5624
|
+
var RUN_EVENT_TERMINAL_LOG_CARRIER_SQL_LIST = [
|
|
5625
|
+
RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runCompleted,
|
|
5626
|
+
RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runFailed,
|
|
5627
|
+
RUN_SCHEDULER_OUTBOX_EVENT_TYPE.runnerLogs
|
|
5628
|
+
].map(sqlStringLiteral).join(", ");
|
|
5629
|
+
var RUN_SCHEDULER_OUTBOX_TERMINAL_EVENT_TYPE_SQL_LIST = [
|
|
5630
|
+
...RUN_SCHEDULER_OUTBOX_TERMINAL_EVENT_TYPES
|
|
5631
|
+
].map(sqlStringLiteral).join(", ");
|
|
5632
|
+
var RUN_EVENT_SEARCH_FALLBACK_KIND_SQL_LITERAL = sqlStringLiteral(
|
|
5633
|
+
RUN_EVENT_SEARCH_FALLBACK_KIND
|
|
5634
|
+
);
|
|
5635
|
+
|
|
5636
|
+
// ../play-runtime/run-ledger.ts
|
|
5637
|
+
var TERMINAL_STATUS_BY_EVENT_TYPE = {
|
|
5638
|
+
[RUN_EVENT_KIND.runCompleted]: "completed",
|
|
5639
|
+
[RUN_EVENT_KIND.runFailed]: "failed",
|
|
5640
|
+
[RUN_EVENT_KIND.runCancelled]: "cancelled"
|
|
5641
|
+
};
|
|
5642
|
+
|
|
5224
5643
|
// ../play-runtime/run-lifecycle-policy.ts
|
|
5225
5644
|
var TERMINAL_PLAY_RUN_STATUSES = /* @__PURE__ */ new Set([
|
|
5226
5645
|
"completed",
|
|
@@ -36466,6 +36885,13 @@ Notes:
|
|
|
36466
36885
|
index request/response bodies or promise one event per provider call. --payloads
|
|
36467
36886
|
includes full result data in this command, capped at ten events and 16 MiB.
|
|
36468
36887
|
|
|
36888
|
+
Event, log, and receipt search share one PlanetScale index. For runs marked
|
|
36889
|
+
runEventStore=planet_scale, PlanetScale owns full event/log history; Convex
|
|
36890
|
+
keeps the live run snapshot, admission fence, and eligible saved-Play rollup
|
|
36891
|
+
facts. Marked-run log bodies are not copied into Convex. Unmarked legacy runs
|
|
36892
|
+
keep their existing Convex event history and Run Log Stream.
|
|
36893
|
+
Known --kind values: ${RUN_EVENT_SEARCH_KIND_VALUES.join(", ")}.
|
|
36894
|
+
|
|
36469
36895
|
Examples:
|
|
36470
36896
|
deepline runs logs play/my-play/run/20260501t000000-000
|
|
36471
36897
|
deepline runs logs play/my-play/run/20260501t000000-000 --limit 500
|
|
@@ -39515,7 +39941,7 @@ function enrichReportJson(report) {
|
|
|
39515
39941
|
} : {}
|
|
39516
39942
|
};
|
|
39517
39943
|
}
|
|
39518
|
-
function
|
|
39944
|
+
function sqlStringLiteral2(value) {
|
|
39519
39945
|
return `'${value.replace(/'/g, "''")}'`;
|
|
39520
39946
|
}
|
|
39521
39947
|
function failureAliasFromCellMeta(cellMeta) {
|
|
@@ -39610,7 +40036,7 @@ async function collectCustomerDbFailureJobs(input2) {
|
|
|
39610
40036
|
const aliasIndexByName = new Map(
|
|
39611
40037
|
fallbackAliases.map((spec, index) => [normalizeAlias2(spec.alias), index])
|
|
39612
40038
|
);
|
|
39613
|
-
const sql = `select _input_index, _status, _error, _cell_meta from ${customerDb.sqlQualifiedTableName} where _run_id = ${
|
|
40039
|
+
const sql = `select _input_index, _status, _error, _cell_meta from ${customerDb.sqlQualifiedTableName} where _run_id = ${sqlStringLiteral2(customerDb.runId)} and (_error is not null or lower(coalesce(_status, '')) in ('failed', 'error')) order by _input_index limit 1000`;
|
|
39614
40040
|
const retryDelays = enrichCustomerDbFailureLookupRetryDelaysMs();
|
|
39615
40041
|
let lastError = null;
|
|
39616
40042
|
let attempts = 0;
|