@opengeni/worker-bundle 2.2.1-canary.36927100590001 → 2.2.1
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/activities/agent-turn/run-credentials.d.ts +0 -2
- package/dist/activities/scheduled-tasks.d.ts +35 -4
- package/dist/activities/types.d.ts +0 -3
- package/dist/activities/workspace-capture.d.ts +0 -2
- package/dist/{activities-control-4F2A734B.js → activities-control-55ECL47G.js} +20 -102
- package/dist/activities-control-55ECL47G.js.map +1 -0
- package/dist/{activities-turn-TESOIOEX.js → activities-turn-T7Y3BWYO.js} +7 -20
- package/dist/activities-turn-T7Y3BWYO.js.map +1 -0
- package/dist/{chunk-YG27NEMX.js → chunk-IJZU752L.js} +1 -34
- package/dist/chunk-IJZU752L.js.map +1 -0
- package/dist/{chunk-4PJTUBWQ.js → chunk-OWNLATJL.js} +11 -34
- package/dist/chunk-OWNLATJL.js.map +1 -0
- package/dist/index.js +2 -2
- package/dist/observability-metrics.d.ts +1 -16
- package/dist/workflow-bundle.js +12 -18
- package/dist/workflows/scheduled-tasks.d.ts +0 -4
- package/package.json +21 -21
- package/src/activities/agent-turn/claim.ts +1 -13
- package/src/activities/agent-turn/run-credentials.ts +0 -5
- package/src/activities/agent-turn/run.ts +0 -1
- package/src/activities/agent-turn/tool-environment.ts +0 -4
- package/src/activities/automations.ts +1 -23
- package/src/activities/goals.ts +8 -33
- package/src/activities/sandbox-lease.ts +0 -22
- package/src/activities/scheduled-tasks.ts +25 -89
- package/src/activities/site-auth-maintenance.ts +0 -1
- package/src/activities/types.ts +0 -3
- package/src/activities/workspace-capture.ts +2 -13
- package/src/observability-metrics.ts +1 -55
- package/src/workflows/scheduled-tasks.ts +13 -26
- package/dist/activities/agent-turn/credential-restriction.d.ts +0 -3
- package/dist/activities-control-4F2A734B.js.map +0 -1
- package/dist/activities-turn-TESOIOEX.js.map +0 -1
- package/dist/chunk-4PJTUBWQ.js.map +0 -1
- package/dist/chunk-YG27NEMX.js.map +0 -1
- package/src/activities/agent-turn/credential-restriction.ts +0 -14
|
@@ -83,7 +83,6 @@ import {
|
|
|
83
83
|
signalPendingCodexCapacityWakeTargets,
|
|
84
84
|
startActivityHeartbeat,
|
|
85
85
|
throwIfTurnOperationCancelled,
|
|
86
|
-
turnCredentialRestriction,
|
|
87
86
|
turnFinalizerCancellationSignal,
|
|
88
87
|
turnInput,
|
|
89
88
|
turnOperationCancellationFailure,
|
|
@@ -95,7 +94,7 @@ import {
|
|
|
95
94
|
withFirstPartyTools,
|
|
96
95
|
wrapLazyTurnBoxWithRouting,
|
|
97
96
|
wrapTurnBoxWithRouting
|
|
98
|
-
} from "./chunk-
|
|
97
|
+
} from "./chunk-OWNLATJL.js";
|
|
99
98
|
import {
|
|
100
99
|
StreamTimingMetrics,
|
|
101
100
|
makeMachineOpObserver,
|
|
@@ -127,7 +126,7 @@ import {
|
|
|
127
126
|
runtimeMetricsHooksForObservability,
|
|
128
127
|
sandboxAutomaticRecoveryOutcome,
|
|
129
128
|
turnLifecycleMetricsFor
|
|
130
|
-
} from "./chunk-
|
|
129
|
+
} from "./chunk-IJZU752L.js";
|
|
131
130
|
import {
|
|
132
131
|
__export
|
|
133
132
|
} from "./chunk-PZ5AY32C.js";
|
|
@@ -4461,16 +4460,13 @@ async function runCapture(input, ctx, startedAt, signal, stage, ownership) {
|
|
|
4461
4460
|
"error.message": gcError instanceof Error ? gcError.message : String(gcError)
|
|
4462
4461
|
});
|
|
4463
4462
|
}
|
|
4464
|
-
|
|
4465
|
-
}
|
|
4466
|
-
function recordWorkspaceCaptureCompleted(observability, durationMs) {
|
|
4463
|
+
const durationMs = Date.now() - startedAt;
|
|
4467
4464
|
observability.incrementCounter({
|
|
4468
4465
|
name: "opengeni_workspace_capture_total",
|
|
4469
4466
|
labels: { result: "ok" }
|
|
4470
4467
|
});
|
|
4471
4468
|
observability.observeHistogram({
|
|
4472
|
-
name: "
|
|
4473
|
-
help: "Turn-end logical workspace revision capture duration for committed revisions.",
|
|
4469
|
+
name: "opengeni_workspace_capture_duration_seconds",
|
|
4474
4470
|
value: durationMs / 1e3
|
|
4475
4471
|
});
|
|
4476
4472
|
}
|
|
@@ -10462,9 +10458,7 @@ async function claimTurnAttempt(deps) {
|
|
|
10462
10458
|
claimedPolicy.kind === "valid" ? claimedPolicy.policy.productModelId : turn.model
|
|
10463
10459
|
);
|
|
10464
10460
|
const codexAppsCredentialId = capabilitySettings.codexConnectedAppsEnabled ? await resolveCodexAppsCredentialIdForRun(db, input.workspaceId) : null;
|
|
10465
|
-
const
|
|
10466
|
-
const credentialRestriction = claimedPolicy.kind === "absent" ? turn.initiatorContext?.credentialRestriction === "developer_setup" ? "developer_setup" : turnCredentialRestriction(candidatePolicy, session.metadata) : void 0;
|
|
10467
|
-
const policyForAbsent = credentialRestriction ? { ...candidatePolicy, credentialRestriction } : candidatePolicy;
|
|
10461
|
+
const policyForAbsent = claimedPolicy.kind === "valid" ? claimedPolicy.policy : resolveTurnExecutionPolicyV12(capabilitySettings, legacyTurnExecutionPolicyInput(turn));
|
|
10468
10462
|
const installedPolicy = await installOrReadTurnExecutionPolicyForAttempt(db, {
|
|
10469
10463
|
accountId: input.accountId,
|
|
10470
10464
|
workspaceId: input.workspaceId,
|
|
@@ -15419,7 +15413,6 @@ async function prepareRunCredentials(deps) {
|
|
|
15419
15413
|
sandboxState,
|
|
15420
15414
|
turn,
|
|
15421
15415
|
session,
|
|
15422
|
-
turnExecutionPolicy,
|
|
15423
15416
|
fileAuthoritySubjectId,
|
|
15424
15417
|
runSettings,
|
|
15425
15418
|
workspaceVariableSet,
|
|
@@ -15578,13 +15571,11 @@ async function prepareRunCredentials(deps) {
|
|
|
15578
15571
|
attemptId: input.attemptId,
|
|
15579
15572
|
turn
|
|
15580
15573
|
}) : void 0;
|
|
15581
|
-
const credentialRestriction = turnCredentialRestriction(turnExecutionPolicy, session.metadata);
|
|
15582
15574
|
const codemodeAuthority = {
|
|
15583
15575
|
sessionId: input.sessionId,
|
|
15584
15576
|
turnId: turn.id,
|
|
15585
15577
|
attemptId: input.attemptId,
|
|
15586
|
-
executionGeneration: turn.executionGeneration
|
|
15587
|
-
...credentialRestriction ? { credentialRestriction } : {}
|
|
15578
|
+
executionGeneration: turn.executionGeneration
|
|
15588
15579
|
};
|
|
15589
15580
|
const sandboxArtifactRuntime = sandboxArtifactRuntimeAdmission(
|
|
15590
15581
|
settings,
|
|
@@ -34236,7 +34227,6 @@ async function prepareTurnToolRuntime(deps) {
|
|
|
34236
34227
|
});
|
|
34237
34228
|
const runSettings = accountRoutes.settings;
|
|
34238
34229
|
const turnTools = accountRoutes.tools;
|
|
34239
|
-
const credentialRestriction = turnCredentialRestriction(turnExecutionPolicy, session.metadata);
|
|
34240
34230
|
const toolContextPreparationStartedAt = performance.now();
|
|
34241
34231
|
throwIfWorkerShuttingDown();
|
|
34242
34232
|
throwIfTurnCancelled();
|
|
@@ -34760,7 +34750,6 @@ async function prepareTurnToolRuntime(deps) {
|
|
|
34760
34750
|
] : [],
|
|
34761
34751
|
...createFirstPartyInteractionAttemptToolDefinitions({
|
|
34762
34752
|
settings: runSettings,
|
|
34763
|
-
...credentialRestriction ? { credentialRestriction } : {},
|
|
34764
34753
|
scope: {
|
|
34765
34754
|
accountId: input.accountId,
|
|
34766
34755
|
workspaceId: input.workspaceId,
|
|
@@ -34847,7 +34836,6 @@ async function prepareTurnToolRuntime(deps) {
|
|
|
34847
34836
|
try {
|
|
34848
34837
|
eventing.preparedTools = await waitForTurnOperation(
|
|
34849
34838
|
runtime.prepareTools(githubRestMcp.settings, githubRestMcp.tools, {
|
|
34850
|
-
...credentialRestriction ? { credentialRestriction } : {},
|
|
34851
34839
|
mcpAccountLabels: accountRoutes.accountLabels,
|
|
34852
34840
|
accountId: input.accountId,
|
|
34853
34841
|
workspaceId: input.workspaceId,
|
|
@@ -37999,7 +37987,6 @@ These are publication receipts for the human's earlier answer. Do not call the r
|
|
|
37999
37987
|
sandboxRuntime,
|
|
38000
37988
|
turn,
|
|
38001
37989
|
session,
|
|
38002
|
-
turnExecutionPolicy,
|
|
38003
37990
|
fileAuthoritySubjectId,
|
|
38004
37991
|
runSettings,
|
|
38005
37992
|
workspaceVariableSet,
|
|
@@ -39752,4 +39739,4 @@ export {
|
|
|
39752
39739
|
createTurnActivities,
|
|
39753
39740
|
createTurnActivitiesFromServices
|
|
39754
39741
|
};
|
|
39755
|
-
//# sourceMappingURL=activities-turn-
|
|
39742
|
+
//# sourceMappingURL=activities-turn-T7Y3BWYO.js.map
|