openmeld 0.3.98 → 0.3.100
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/{add-me-membership-CnjkM97q.js → add-me-membership-TPvrNV3W.js} +2 -2
- package/dist/{add-me-membership-CnjkM97q.js.map → add-me-membership-TPvrNV3W.js.map} +1 -1
- package/dist/{api-client-foundation-DhBFOgEh.js → api-client-foundation-Dkpm10n_.js} +3 -3
- package/dist/{api-client-foundation-DhBFOgEh.js.map → api-client-foundation-Dkpm10n_.js.map} +1 -1
- package/dist/{auth-session-BH5KpxlR.js → auth-session-DIMnEdJJ.js} +2 -2
- package/dist/{auth-session-BH5KpxlR.js.map → auth-session-DIMnEdJJ.js.map} +1 -1
- package/dist/{command-BzpvQPph.js → command-D3JnXEV4.js} +9675 -8883
- package/dist/{command-BzpvQPph.js.map → command-D3JnXEV4.js.map} +1 -1
- package/dist/{dist-BKlTzgZt.js → dist-tBSl0WJC.js} +2 -2
- package/dist/{dist-BKlTzgZt.js.map → dist-tBSl0WJC.js.map} +1 -1
- package/dist/openmeld.js +115 -164
- package/dist/openmeld.js.map +1 -1
- package/dist/{runtime-transport-Ch3hTK9F.js → runtime-transport-DTqyhBcv.js} +13 -1
- package/dist/runtime-transport-DTqyhBcv.js.map +1 -0
- package/package.json +1 -1
- package/dist/runtime-transport-Ch3hTK9F.js.map +0 -1
package/dist/openmeld.js
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
import { $ as LEGACY_OPENMELD_AGENT_SESSION_ENV_KEY, At as openMeldManagedBinaryPath, Bt as resolveOpenMeldCliEntryNameFromArgv, D as toSpaceBoardUrl, Et as normalizeAccountKey, Ft as organizationSkillReleaseDir, G as isOpenMeldOrphanedLockError, H as acquireLock, It as profileDir, J as releaseLockSync, Jt as systemDir, Kt as skillsDir, Lt as profileViewPath, M as toSpaceDispatchLookupUrl, N as toSpaceDispatchTraceUrl, Nt as openMeldRootDir, O as toSpaceContractUrl, Ot as openMeldBackupsDir, S as updateConfiguredOnboardingConfig, T as normalizeBaseUrl, U as buildOpenMeldOrphanedLockAction, Ut as resolveOpenMeldRootDir, Vt as resolveOpenMeldEnvPreset, W as isOpenMeldLockError, X as resolveOpenMeldOrphanedLockIssue, Y as repairOrphanedLegacyLocks, Yt as formatLocalMachineIssueMessage, Z as runWithHeldLock, _t as accountProfileSpaceCacheDir, a as resolveBaseUrl, b as setConfiguredSkillsConfig, bt as accountsDir, c as resolveExplicitGatewayUrlOrThrow, ct as LocalMachineFailureError, et as OPENMELD_CLI_CONTEXT_ENV_KEY, ft as createOrphanedSetupConcurrencyIssue, h as getConfiguredSkillsConfig, jt as openMeldManagedVersionBinaryPath, m as getConfiguredOnboardingDisclaimerAcceptedAt, mt as toRecognizedLocalMachineFailureError, nn as agentControllerConversationRefSchema, o as resolveBaseUrlOrNull, ot as formatLaneScopeSentence, pt as isLocalMachineFailureError, qt as spacesDir, rt as resolveCliContext, st as resolveOpenMeldLaneDescriptor, u as alignRuntimeConfigStorage, ut as createActiveSetupConcurrencyIssue, vt as accountProfileViewPath, w as updateConfiguredStartV1OnboardingState, y as setConfiguredBaseUrl, z as toSpaceResultUrl } from "./base-url-Cv9x5Es9.js";
|
|
4
|
-
import { $ as runAgentsRepair, $a as uninstallAgentActivityIntegrations, $i as performManagedInstall, $n as formatDaemonServiceDowngradeBlockedRecommendation, $r as resolveProfileWorkspaceRuntime, $t as readBundledOpenMeldCliSkillDocumentByPath, A as assertFullSignalIdArgument, Aa as getSelectedOpenMeldProfileId, Ai as getAgentControllerPermissionModeDisplayMetadata, An as inspectSpaceCacheFile, Ao as enqueueControllerTaskLifecycleEventWhileLocked, Ar as buildAgentOverviewFromContract, At as shouldEmitAgentOverview, B as persistAgentTransportSelection, Ba as LocalProjectConnectionError, Bi as getCurrentCommandCheckState, Bn as formatRemovedCcRelationMessage, Bo as cliJsonOutputEnvelopeSchema, Br as runDaemonServiceFullAlignment, Bt as parseJsonResponse, C as toSpaceMetaUpsertInput, Ca as deleteOpenMeldProfile, Ci as classifyDaemonServiceWakeability, Cn as submitProfileRuntimeAgentControllerReport, Co as listProjectConnectionsWithStatus, Cr as registerSpaceMemberSelectionOptions, Ct as runDaemonTeardownStrict, D as formatHumanReadTargetList, Da as updateOpenMeldProfile, Di as resolveOpenMeldEnvironmentTarget, Dn as resolveLocalAgentControllerBlockerReasonCodes, Do as setDefaultProjectConnection, Dr as registerDaemonControlTargetOptions, Dt as reconcileCliVersionView, E as buildHumanReplyContextSummary, Ea as resolveOpenMeldProfile, Ei as resolveDaemonDeviceId, En as collectLocalAgentControllerInventory, Eo as runIfAgentActivityBindingGenerationIsCurrent, Er as getCliVersionInfo, Et as buildProfileWorkspaceRows, F as emitSpaceAgentOverview, Fa as resolveAuthenticationGuidance, Fi as resolveAgentExecutionStatus, Fn as buildSignalIndex, Fo as emitCliJsonEnvelope, Fr as OPENMELD_AGENT_MENTAL_MODEL_LINES, Ft as fetchSpaceMeta, G as runAgentsCustomList, Ga as registerAgentActivityRoute, Gi as resolveVersionChangeDirection, Gn as assessCliUpdate, Go as organizationJoinLinkErrorResponseSchema, Gr as formatAgentReplyReadinessLabel, Gt as runDaemonStartDecisionPrompt, H as runAgents, Ha as LocalDaemonControlPlaneClientError, Hi as resetCurrentCommandCheckState, Hn as promptSearchSelect, Ho as cliJsonSkillsLoadEnvelopeSchema, Hr as resolveServiceReadinessFromServiceStatus, Ht as writeInstalledLocalComponentsSnapshot, I as emitSpaceCliAgentOverview, Ia as resolveAuthenticationGuidanceFromError, Ii as resolveAgentProfileEditCapabilities, In as buildSignalMessageReadProjection, Io as errLine, Ir as SPACE_CONTRACT_ALLOWED_ACTION_ORDER, It as updateSpaceMeta, J as runAgentsDetect, Ji as getDaemonSystemServiceLogPath, Jn as readDispatchOwnedRuntimeGuard, Jo as package_default, Jr as mapAgentReplyReadinessToLegacyAutoReply, Jt as runSkillsEnsure, K as runAgentsCustomRemove, Ka as resolveAgentActivityRouteForPath, Ki as readCurrentDaemonRuntimeContext, Kn as isCliUpdateCheckApplicable, Ko as revokeOrganizationJoinLinkResponseSchema, Kr as formatDeviceReplyReadinessLabel, Kt as collectSkillsReadinessSnapshot, L as prepareLocalAgentReadiness, La as resolveAuthenticationGuidanceFromMessage, Li as resolveEvidenceSyncHealth, Ln as buildSpaceRoundReadProjection, Lo as outJsonLine, Lr as areAllowedActionsEquivalent, Lt as readGatewayJsonResponse, M as prepareAuthenticatedSpaceCommandContext, Ma as buildAgentAuthenticationGuide, Mi as listAgentControllerPermissionModeOptions, Mn as assertNoRemovedCcSpaceAddressingSyntax, Mo as renderInfoCard, Mr as formatDualViewGuideForDisplay, Mt as readDaemonStartFailureLogTailLines, N as resolveOpenMeldProfileForSpaceCommand, Na as buildHumanAuthenticationCard, Ni as parseAgentControllerRef, Nn as buildDispatchResultMessageReadProjection, No as renderTextInfoCard, Nr as buildDualViewGuideMessage, Nt as fetchSpaceUpdates, O as parseEnvelope, Oa as alignSelectedOpenMeldProfileStorage, Oi as buildAgentControllerRef, On as resolveLocalAgentControllerLaunchability, Oo as unbindProject, Or as registerAuthLoginRequestOptions, Ot as emitDaemonAgentOverview, P as resolveSpaceAccessLabel, Pa as createAuthenticationError, Pi as resolveAgentControllerPermissionModeForController, Pn as buildDispatchResultReplyWorkflowProjection, Po as sanitizeTerminalDisplayText, Pr as formatAgentOverviewPayload, Pt as createCliSpaceApi, Q as runAgentsManage, Qa as resolveAgentActivityDispatcherCommand, Qi as buildInstallSelfJsonPayload, Qn as resolveElapsedTimeMs, Qr as createModelCatalogReadSession, Qt as ensureLocalSkills, R as buildReplyReadinessGuidance, Ra as getProfileDefaultView, Ri as resolveNativeAgentControllerPermissionModeForController, Rn as buildUpdatesReplyWorkflowProjection, Ro as outLine, Rr as buildAgentFacingPublicationModeGuideLines, Rt as readGatewayTextResponse, S as loadSpaceSignalIndexOrNull, Sa as createOpenMeldHumanProfile, Si as classifyDaemonServiceRunStartability, Sn as computeRetryDelayMs, So as listProjectBindings, Sr as getCommandHintsFromContract, St as runDaemonStop, T as buildFormalSignalReadPayload, Ta as primeOpenMeldProfilesSessionCache, Ti as ensureDaemonRuntimePaths, Tn as submitRuntimeAgentControllerReports, To as removeProjectConnection, Tr as registerSkillsTargetSelectionOptions, Tt as buildProfileWorkspacePresentation, U as runAgentsConfig, Ua as requestLocalAgentActivitySync, Ui as startCurrentCommandCheckScope, Un as isReturnKeypress, Uo as cliJsonSkillsShowEnvelopeSchema, Ur as resolveDaemonServiceFreshnessWarning, Ut as resolveDaemonServiceParticipationStatus, V as resolveAgentProfileSetup, Va as validateLocalProjectConnectionPath, Vi as isCurrentCommandCheckScopeActive, Vn as promptSearchMultiselect, Vo as cliJsonSkillsListEnvelopeSchema, Vr as formatDaemonFailureContextText, Vt as resolveLocalComponentsStatus, W as runAgentsCustomAdd, Wa as isAgentActivityRouteRegistered, Wi as inspectDaemonServiceInventory, Wn as runInteractivePrompt, Wo as getOrganizationJoinLinkResponseSchema, Wr as resolveCurrentReplyReadinessSnapshot, Wt as runDaemonServiceParticipationGate, X as runAgentsEnable, Xa as installAgentActivityIntegrations, Xi as readDaemonServiceJobCrashExitCode, Xn as writeDispatchSpaceActionRecord, Xr as resolveOpenClawLocalDiagnosticsValue, Xt as runSkillsUninstall, Y as runAgentsDisable, Ya as defaultManagedIntegrationPaths, Yi as isDaemonServiceJobNeverSpawned, Yn as readDispatchSpaceActionContextFromEnv, Yr as resolveGatewayChainReadiness, Yt as runSkillsInstall, Z as runAgentsList, Za as readAgentActivityIntegrationStatus, Zi as resolveDaemonServiceManager, Zn as formatElapsedTime, Zr as syncProfileWorkspaceState, Zt as runSkillsUpdate, _ as runSpaceWriteWithPasswordRetry, _a as resolveViewProfileKey, _i as buildDaemonRouteObservationPresentation$1, _n as promptTextEntry, _o as enqueueAgentActivityHookEvent, _r as createSpaceUpdatesGuideError, _t as runDaemonInterrupt, a as runSpaceDelete, aa as readVersionState, ai as setOpenMeldManagedProfileWorkspace, an as ensureCommandAuthenticationOrCancel, ao as formatProfileAwareOpenMeldCliCommands, ar as createProfileMenuGuideError, at as printOpenMeldBanner, b as buildIdentityOnlyMembersSnapshotForReadProjection, ba as resolveOpenMeldProfileOrNull, bi as buildDaemonServiceTargetSpec, bn as resolveServiceParticipationReadiness, bo as removeProjectOutbox, br as createUpgradeConfirmationGuideError, bt as runDaemonSnapshot, c as runSpaceLeave, ca as toStartBackgroundHelperExecutionCompatibility, ci as syncDeviceRuntimeStateProjection, cn as runAuthLogout, co as syncLocalAgentActivity, cr as createSpaceAliasTargetGuideError, ct as renderOpenMeldLogo, d as runSpaceRemoveMembers, da as renderHumanErrorCard, di as listAgentTargetStates, dn as buildAuthStatusRows, do as readAgentActivityContextForPath, dr as createSpaceMenuGuideError, dt as resolveSpaceSendText, ea as buildNextVersionState, ei as ensureOpenMeldManagedProfileWorkspace, en as readRuntimeReportingHealthState, eo as formatInlineOpenMeldCliCommands, er as formatDaemonServiceMissingRecommendation, et as runAgentsShow, f as runSpaceSend, fa as renderHumanTextErrorCard, fi as reconcileNewRunnableBuiltinAgentsForSetup, fn as buildAuthStatusSnapshot, fo as removeAgentActivityContextCache, fr as createSpacePublicationSetGuideError, ft as runDaemon, g as runSpaceReadWithPasswordRetry, ga as resolveRuntimeContext, gn as resolveCreateProfileName, go as readCodexSessionTitles, gr as createSpaceTargetGuideError, gt as runDaemonInstall, h as uploadPreparedSpaceFiles, ha as parseCliViewMode, hi as resolveLocalRegistryAgentIdFromAgentControllerRef, hn as resolveCreateProfileKind, ho as normalizeSharedSessionTitle, hr as createSpaceSubcommandTargetGuideError, ht as runDaemonCancel, i as runSpaceCreate, ia as fetchLatestPackageInfo, ii as setCustomProfileWorkspace, in as buildCommandAuthenticationPromptMessage, io as formatOpenMeldCliTextBlock, ir as createProfileCreateGuideError, it as colorizeDisplayProfileLabel, j as assertValidSpaceIdTarget, ja as setSelectedOpenMeldProfileId, ji as getAgentControllerPermissionModeFieldLabel, jn as upsertSpaceConfig, jo as readControllerTaskLifecycleOutboxHealth, jr as DualViewGuideError, jt as runDaemonStartupPreflight, k as isSpaceCommandOutputHandledError, ka as clearSelectedOpenMeldProfileId, ki as createAgentExecutionStatusDisplayRows, kn as resolveLocalAgentControllerReportDecision, ko as canonicalizeLocalProjectPath, kr as registerBuiltinAgentSelectionOptions, kt as createDelayedSpinner, l as runSpaceList, la as resolveCurrentDaemonExpectedVersion, li as createPrimaryBindingReadSession, ln as runAuthMenu, lo as readDaemonServiceContract, lr as createSpaceContractSetGuideError, lt as renderOpenMeldTagline, m as prepareRequestedSpaceSendFiles, ma as formatMessage, mi as notifyDaemonRouteCatalogChanged, mn as createProfileByKind, mo as resolveObservedAgentActivityBinding, mr as createSpaceResultGuideError, mt as runDaemonBackgroundStartForDecision, n as promptAndConfirmSpacePassword, na as ensureVersionStateReady, ni as readProfileWorkspaceConfig, nn as connectWebSocket, no as formatOpenMeldCliCommands, nr as createDoctorFailedGuideError, nt as postLocalParticipationMutationReconcile, o as runSpaceHistory, oa as writeVersionState, oi as validateCustomProfileWorkspacePath, on as evaluateCommandAuthentication, oo as resolveSetupFollowUpCliEntryCommand, or as createResetConfirmationGuideError, ot as renderOpenMeldBrandBlockLines, p as runSpaceWatch, pa as createPresenter, pi as listBuiltinAgentsRegistryEntries, pn as formatActiveOrganizationLabel, po as buildAgentActivityEvent, pr as createSpaceRemoveMembersGuideError, pt as runDaemonAutostart, q as runAgentsCustomUpdate, qa as unregisterAgentActivityRoute, qi as readCurrentObservedDaemonRuntimeStatus, qn as assertDispatchOwnedRuntimePublicWriteAllowed, qo as compareAgentControllerRefsForDisplay, qr as formatHumanReplyReadinessReason$1, qt as runSkillsCheck$1, r as runSpaceAddMembers, ra as fetchLatestCliBinaryRelease, ri as resolveConfiguredProfileWorkspacePath, rn as assessServerRequiredVersion, ro as formatOpenMeldCliLine, rr as createProfileActionGuideError, rt as colorizeAgentLabel, s as runSpaceJoin, sa as resolveDaemonRuntimeContractCompatibility, si as describeProfileWorkspacePathValidationFailure, sn as runAuthLogin, so as resolveUserFacingCliEntryCommand, sr as createSpaceAddMembersGuideError, st as renderOpenMeldHeader, t as buildCreateSpacePasswordPromptConfig, ta as compareSemver, ti as normalizeCustomProfileWorkspacePath, tn as readRecentDaemonDispatchJournalEvents, to as formatOpenMeldCliCommand, tr as canUseInteractivePrompts, tt as formatTransportModeDisplay, u as runSpacePassword, ua as buildHumanErrorCopy, ui as resolveAgentProfilePrimaryAgentControllerReport, un as runAuthStatus, uo as upsertDaemonServiceContract, ur as createSpaceLeaveGuideError, ut as resolveGatewayWebOrigin, v as buildHumanReadSignalsTranscriptItems, va as isSelectedOpenMeldProfileRequiredError, vi as buildOnboardingPlan, vn as ensureAgentProfileRuntimeBinding, vo as removeProjectInbox, vr as createStartAgentIdentityGuideError, vt as runDaemonReinstall, w as buildFormalDispatchResultReadPayload, wa as listOpenMeldProfiles, wi as readRecentDaemonLifecycleEvents, wn as submitRuntimeAgentControllerReport, wo as migrateProjectBindingStore, wr as SPACE_ADD_MEMBERS_PROGRESS_HEARTBEAT_MS, wt as runDaemonUninstall, x as loadSpaceIdentityDirectoryOrNull, xa as createOpenMeldAgentProfile, xi as resolveDaemonServiceAlignmentDecision, xn as assessActionParticipationCandidate, xo as bindProject, xr as getCommandEntryContract, xt as runDaemonStatusFlow, y as emitHumanReadSignalsTextProjection, ya as requireOpenMeldProfile, yi as getSetupFlowCopy, yn as formatServiceParticipationReadinessLabel, yo as readAgentActivityOutboxHealth, yr as createStartAuthenticationGuideError, yt as runDaemonRunAfterEntryChecks, z as resolveHumanControllerDisplayName, za as setProfileDefaultView, zi as finishCurrentCommandCheckScope, zn as createSpaceMemberIdentityIndex, zo as cliBinaryDeltaPatchSchema, zr as canonicalizeAllowedActions, zt as toStructuredGatewayFailure } from "./command-BzpvQPph.js";
|
|
5
|
-
import { $ as ownerComputerDiagnosticsSchema, $t as agentActivityInventorySessionStatusSchema, B as sleep, Bt as agentActivityProviderSchema, Ct as authProfileKindSchema, D as toStructuredApiClientFailure, F as OPENMELD_HEADER_PROFILE_ID, G as projectSpaceDispatchTraceFinalVisibleOutcome, Ht as agentActivitySnapshotQuerySchema, J as spaceDispatchTraceDispatchStatusSchema, K as resolveSpaceDispatchTraceRootCause, Ot as submitFeedbackIssueRequestSchema, Qt as agentActivityInventorySessionOriginSchema, Vt as agentActivitySessionStatusSchema, W as SPACE_DISPATCH_TRACE_RESPONSE_CONTRACT_VERSION_HEADER, X as observabilityWakeTraceSelectorSchema, Y as spaceDispatchTraceResponseSchema, Z as projectObservabilityWakeCorrelation, _ as createOrganizationSkillsApi, b as createProjectsApi, c as createAgentProfileBindingApi, d as createCurrentDeviceApi, dn as START_BOUNDED_ID_SCHEMA, en as agentActivitySessionInventoryQuerySchema, et as projectOwnerComputerLocalRuntimes, f as createFeedbackApi, fn as START_BOUNDED_VERSION_SCHEMA, g as createOrganizationApi, gn as localAgentCatalogSchema, gt as organizationSkillBundleSchema, hn as startReplyReadinessSummarySchema, l as createCenterAgentApi, mn as START_TRIMMED_NON_EMPTY_STRING_SCHEMA, nn as localAgentSessionProviderSchema, nt as DEFAULT_AGENT_PROFILE_CREATION_CONFIGURATION, pn as START_ISO_DATE_TIME_SCHEMA, q as spaceDispatchTraceAttemptStatusSchema, rt as agentProfileCreationConfigurationSchema, s as createAgentActivityApi, tt as summarizeComputerFileAccessPolicy, u as createComputerFileAccessApi, v as createPrepareReadinessApi, wt as authProfileManagedRoleSchema, x as createRoutinesApi, yt as stringifyOrganizationSkillBundleCanonicalJson } from "./dist-
|
|
6
|
-
import { At as centerAgentInteractionSourceSchema, Er as trimmedStringFromUnknown, Ft as isSpaceFileTextEditable, Gn as clientMessageIdSchema, Rt as resolveSpaceFileMimeType, _r as openMeldRuntimeProfileIdSchema, an as spaceContractFieldsSchema, en as dispatchExecutionSchema, fr as openMeldProfileIdSchema, kt as spaceStatusSchema, on as spaceContractSchema, tn as spaceThreadContextSchema, vn as messageEnvelopeSchema, wr as nonEmptyTrimmedStringFromUnknown } from "./runtime-transport-
|
|
4
|
+
import { $ as runAgentsRepair, $a as readAgentActivityIntegrationStatus, $i as resolveDaemonServiceManager, $n as formatDaemonServiceMissingRecommendation, $r as readRecentDaemonLifecycleEvents, $t as readBundledOpenMeldCliSkillDocumentByPath, A as assertFullSignalIdArgument, Aa as alignSelectedOpenMeldProfileStorage, An as upsertSpaceConfig, Ao as unbindProject, Ar as DualViewGuideError, At as shouldEmitAgentOverview, B as persistAgentTransportSelection, Ba as getProfileDefaultView, Bi as resolveOpenMeldEnvironmentTarget, Bn as promptSearchMultiselect, Bo as outLine, Br as scheduleDaemonServiceUpdate, Bt as parseJsonResponse, C as toSpaceMetaUpsertInput, Ca as createOpenMeldAgentProfile, Ci as listAgentControllerPermissionModeOptions, Cn as submitRuntimeAgentControllerReport, Co as bindProject, Cr as SPACE_ADD_MEMBERS_PROGRESS_HEARTBEAT_MS, Ct as runDaemonTeardownStrict, D as formatHumanReadTargetList, Da as primeOpenMeldProfilesSessionCache, Di as resolveAgentProfileEditCapabilities, Dn as resolveLocalAgentControllerLaunchability, Do as removeProjectConnection, Dr as registerAuthLoginRequestOptions, Dt as reconcileCliVersionView, E as buildHumanReplyContextSummary, Ea as listOpenMeldProfiles, Ei as resolveAgentExecutionStatus, En as resolveLocalAgentControllerBlockerReasonCodes, Eo as migrateProjectBindingStore, Er as registerDaemonControlTargetOptions, Et as buildProfileWorkspaceRows, F as emitSpaceAgentOverview, Fa as buildHumanAuthenticationCard, Fi as resolveDaemonServiceAlignmentDecision, Fn as buildSignalMessageReadProjection, Fo as renderTextInfoCard, Fr as SPACE_CONTRACT_ALLOWED_ACTION_ORDER, Ft as fetchSpaceMeta, G as runAgentsCustomList, Ga as requestLocalAgentActivitySync, Gi as startCurrentCommandCheckScope, Gn as isCliUpdateCheckApplicable, Go as cliJsonSkillsShowEnvelopeSchema, Gr as resolveDaemonServiceFreshnessWarning, Gt as runDaemonStartDecisionPrompt, H as runAgents, Ha as LocalProjectConnectionError, Hi as getCurrentCommandCheckState, Hn as isReturnKeypress, Ho as cliJsonOutputEnvelopeSchema, Hr as resolveDaemonDeviceId, Ht as writeInstalledLocalComponentsSnapshot, I as emitSpaceCliAgentOverview, Ia as createAuthenticationError, Ii as classifyDaemonServiceRunStartability, In as buildSpaceRoundReadProjection, Io as sanitizeTerminalDisplayText, Ir as areAllowedActionsEquivalent, It as updateSpaceMeta, J as runAgentsDetect, Ja as resolveAgentActivityRouteForPath, Ji as readCurrentDaemonRuntimeContext, Jn as readDispatchSpaceActionContextFromEnv, Jo as revokeOrganizationJoinLinkResponseSchema, Jr as formatDeviceReplyReadinessLabel, Jt as runSkillsEnsure, K as runAgentsCustomRemove, Ka as isAgentActivityRouteRegistered, Ki as inspectDaemonServiceInventory, Kn as assertDispatchOwnedRuntimePublicWriteAllowed, Ko as getOrganizationJoinLinkResponseSchema, Kr as resolveCurrentReplyReadinessSnapshot, Kt as collectSkillsReadinessSnapshot, L as prepareLocalAgentReadiness, La as resolveAuthenticationGuidance, Li as classifyDaemonServiceWakeability, Ln as buildUpdatesReplyWorkflowProjection, Lo as emitCliJsonEnvelope, Lr as buildAgentFacingPublicationModeGuideLines, Lt as readGatewayJsonResponse, M as prepareAuthenticatedSpaceCommandContext, Ma as getSelectedOpenMeldProfileId, Mi as buildOnboardingPlan, Mn as buildDispatchResultMessageReadProjection, Mo as enqueueControllerTaskLifecycleEventWhileLocked, Mr as buildDualViewGuideMessage, Mt as readDaemonStartFailureLogTailLines, N as resolveOpenMeldProfileForSpaceCommand, Na as setSelectedOpenMeldProfileId, Ni as getSetupFlowCopy, Nn as buildDispatchResultReplyWorkflowProjection, No as readControllerTaskLifecycleOutboxHealth, Nr as formatAgentOverviewPayload, Nt as fetchSpaceUpdates, O as parseEnvelope, Oa as resolveOpenMeldProfile, Oi as resolveEvidenceSyncHealth, On as resolveLocalAgentControllerReportDecision, Oo as runIfAgentActivityBindingGenerationIsCurrent, Or as registerBuiltinAgentSelectionOptions, Ot as emitDaemonAgentOverview, P as resolveSpaceAccessLabel, Pa as buildAgentAuthenticationGuide, Pi as buildDaemonServiceTargetSpec, Pn as buildSignalIndex, Po as renderInfoCard, Pr as OPENMELD_AGENT_MENTAL_MODEL_LINES, Pt as createCliSpaceApi, Q as runAgentsManage, Qa as installAgentActivityIntegrations, Qi as readDaemonServiceJobCrashExitCode, Qn as formatDaemonServiceDowngradeBlockedRecommendation, Qr as resolveOpenClawLocalDiagnosticsValue, Qt as ensureLocalSkills, R as buildReplyReadinessGuidance, Ra as resolveAuthenticationGuidanceFromError, Ri as resolveServiceUpdateUrgency, Rn as createSpaceMemberIdentityIndex, Ro as errLine, Rr as canonicalizeAllowedActions, Rt as readGatewayTextResponse, S as loadSpaceSignalIndexOrNull, Sa as resolveOpenMeldProfileOrNull, Si as getAgentControllerPermissionModeFieldLabel, Sn as submitProfileRuntimeAgentControllerReport, So as removeProjectOutbox, Sr as registerSpaceMemberSelectionOptions, St as runDaemonStop, T as buildFormalSignalReadPayload, Ta as deleteOpenMeldProfile, Ti as resolveAgentControllerPermissionModeForController, Tn as collectLocalAgentControllerInventory, To as listProjectConnectionsWithStatus, Tr as getCliVersionInfo, Tt as buildProfileWorkspacePresentation, U as runAgentsConfig, Ua as validateLocalProjectConnectionPath, Ui as isCurrentCommandCheckScopeActive, Un as runInteractivePrompt, Uo as cliJsonSkillsListEnvelopeSchema, Ur as formatDaemonFailureContextText, Ut as resolveDaemonServiceParticipationStatus, V as resolveAgentProfileSetup, Va as setProfileDefaultView, Vi as finishCurrentCommandCheckScope, Vn as promptSearchSelect, Vo as cliBinaryDeltaPatchSchema, Vr as ensureDaemonRuntimePaths, Vt as resolveLocalComponentsStatus, W as runAgentsCustomAdd, Wa as LocalDaemonControlPlaneClientError, Wi as resetCurrentCommandCheckState, Wn as assessCliUpdate, Wo as cliJsonSkillsLoadEnvelopeSchema, Wr as resolveServiceReadinessFromServiceStatus, Wt as runDaemonServiceParticipationGate, X as runAgentsEnable, Xi as getDaemonSystemServiceLogPath, Xn as formatElapsedTime, Xo as package_default, Xr as mapAgentReplyReadinessToLegacyAutoReply, Xt as runSkillsUninstall, Y as runAgentsDisable, Ya as unregisterAgentActivityRoute, Yi as readCurrentObservedDaemonRuntimeStatus, Yn as writeDispatchSpaceActionRecord, Yo as compareAgentControllerRefsForDisplay, Yr as formatHumanReplyReadinessReason$1, Yt as runSkillsInstall, Z as runAgentsList, Za as defaultManagedIntegrationPaths, Zi as isDaemonServiceJobNeverSpawned, Zn as resolveElapsedTimeMs, Zr as resolveGatewayChainReadiness, Zt as runSkillsUpdate, _ as runSpaceWriteWithPasswordRetry, _a as parseCliViewMode, _i as notifyDaemonRouteCatalogChanged, _n as ensureAgentProfileRuntimeBinding, _o as normalizeSharedSessionTitle, _r as createStartAgentIdentityGuideError, _t as runDaemonInterrupt, a as runSpaceDelete, aa as fetchLatestCliBinaryRelease, ai as readProfileWorkspaceConfig, an as evaluateCommandAuthentication, ao as formatOpenMeldCliLine, ar as createResetConfirmationGuideError, at as printOpenMeldBanner, b as buildIdentityOnlyMembersSnapshotForReadProjection, ba as isSelectedOpenMeldProfileRequiredError, bi as createAgentExecutionStatusDisplayRows, bn as assessActionParticipationCandidate, bo as removeProjectInbox, br as getCommandEntryContract, bt as runDaemonSnapshot, c as runSpaceLeave, ca as writeVersionState, ci as setOpenMeldManagedProfileWorkspace, cn as runAuthMenu, co as resolveSetupFollowUpCliEntryCommand, cr as createSpaceContractSetGuideError, ct as renderOpenMeldLogo, d as runSpaceRemoveMembers, da as resolveCurrentDaemonExpectedVersion, di as syncDeviceRuntimeStateProjection, dn as buildAuthStatusSnapshot, do as readDaemonServiceContract, dr as createSpacePublicationSetGuideError, dt as resolveSpaceSendText, ea as buildInstallSelfJsonPayload, ei as syncProfileWorkspaceState, en as readRuntimeReportingHealthState, eo as resolveAgentActivityDispatcherCommand, er as canUseInteractivePrompts, et as runAgentsShow, f as runSpaceSend, fa as buildHumanErrorCopy, fi as createPrimaryBindingReadSession, fn as formatActiveOrganizationLabel, fo as upsertDaemonServiceContract, fr as createSpaceRemoveMembersGuideError, ft as runDaemon, g as runSpaceReadWithPasswordRetry, ga as formatMessage, gi as listBuiltinAgentsRegistryEntries, gn as promptTextEntry, go as resolveObservedAgentActivityBinding, gr as createSpaceUpdatesGuideError, gt as runDaemonInstall, h as uploadPreparedSpaceFiles, ha as createPresenter, hi as reconcileNewRunnableBuiltinAgentsForSetup, hn as resolveCreateProfileName, ho as buildAgentActivityEvent, hr as createSpaceTargetGuideError, ht as runDaemonCancel, i as runSpaceCreate, ia as ensureVersionStateReady, ii as normalizeCustomProfileWorkspacePath, in as ensureCommandAuthenticationOrCancel, io as formatOpenMeldCliCommands, ir as createProfileMenuGuideError, it as colorizeDisplayProfileLabel, j as assertValidSpaceIdTarget, ja as clearSelectedOpenMeldProfileId, ji as buildDaemonRouteObservationPresentation$1, jn as assertNoRemovedCcSpaceAddressingSyntax, jo as canonicalizeLocalProjectPath, jr as formatDualViewGuideForDisplay, jt as runDaemonStartupPreflight, k as isSpaceCommandOutputHandledError, ka as updateOpenMeldProfile, ki as resolveNativeAgentControllerPermissionModeForController, kn as inspectSpaceCacheFile, ko as setDefaultProjectConnection, kr as buildAgentOverviewFromContract, kt as createDelayedSpinner, l as runSpaceList, la as resolveDaemonRuntimeContractCompatibility, li as validateCustomProfileWorkspacePath, ln as runAuthStatus, lo as resolveUserFacingCliEntryCommand, lr as createSpaceLeaveGuideError, lt as renderOpenMeldTagline, m as prepareRequestedSpaceSendFiles, ma as renderHumanTextErrorCard, mi as listAgentTargetStates, mn as resolveCreateProfileKind, mo as removeAgentActivityContextCache, mr as createSpaceSubcommandTargetGuideError, mt as runDaemonBackgroundStartForDecision, n as promptAndConfirmSpacePassword, na as buildNextVersionState, ni as resolveProfileWorkspaceRuntime, nn as connectWebSocket, no as formatInlineOpenMeldCliCommands, nr as createProfileActionGuideError, nt as postLocalParticipationMutationReconcile, o as runSpaceHistory, oa as fetchLatestPackageInfo, oi as resolveConfiguredProfileWorkspacePath, on as runAuthLogin, oo as formatOpenMeldCliTextBlock, or as createSpaceAddMembersGuideError, ot as renderOpenMeldBrandBlockLines, p as runSpaceWatch, pa as renderHumanErrorCard, pi as resolveAgentProfilePrimaryAgentControllerReport, pn as createProfileByKind, po as readAgentActivityContextForPath, pr as createSpaceResultGuideError, pt as runDaemonAutostart, q as runAgentsCustomUpdate, qa as registerAgentActivityRoute, qi as resolveVersionChangeDirection, qn as readDispatchOwnedRuntimeGuard, qo as organizationJoinLinkErrorResponseSchema, qr as formatAgentReplyReadinessLabel, qt as runSkillsCheck$1, r as runSpaceAddMembers, ra as compareSemver, ri as ensureOpenMeldManagedProfileWorkspace, rn as buildCommandAuthenticationPromptMessage, ro as formatOpenMeldCliCommand, rr as createProfileCreateGuideError, rt as colorizeAgentLabel, s as runSpaceJoin, sa as readVersionState, si as setCustomProfileWorkspace, sn as runAuthLogout, so as formatProfileAwareOpenMeldCliCommands, sr as createSpaceAliasTargetGuideError, st as renderOpenMeldHeader, t as buildCreateSpacePasswordPromptConfig, ta as performManagedInstall, ti as createModelCatalogReadSession, tn as readRecentDaemonDispatchJournalEvents, to as uninstallAgentActivityIntegrations, tr as createDoctorFailedGuideError, tt as formatTransportModeDisplay, u as runSpacePassword, ua as toStartBackgroundHelperExecutionCompatibility, ui as describeProfileWorkspacePathValidationFailure, un as buildAuthStatusRows, uo as syncLocalAgentActivity, ur as createSpaceMenuGuideError, ut as resolveGatewayWebOrigin, v as buildHumanReadSignalsTranscriptItems, va as resolveRuntimeContext, vi as resolveLocalRegistryAgentIdFromAgentControllerRef, vn as formatServiceParticipationReadinessLabel, vo as readCodexSessionTitles, vr as createStartAuthenticationGuideError, vt as runDaemonReinstall, w as buildFormalDispatchResultReadPayload, wa as createOpenMeldHumanProfile, wi as parseAgentControllerRef, wn as submitRuntimeAgentControllerReports, wo as listProjectBindings, wr as registerSkillsTargetSelectionOptions, wt as runDaemonUninstall, x as loadSpaceIdentityDirectoryOrNull, xa as requireOpenMeldProfile, xi as getAgentControllerPermissionModeDisplayMetadata, xn as computeRetryDelayMs, xo as readAgentActivityOutboxHealth, xr as getCommandHintsFromContract, xt as runDaemonStatusFlow, y as emitHumanReadSignalsTextProjection, ya as resolveViewProfileKey, yi as buildAgentControllerRef, yn as resolveServiceParticipationReadiness, yo as enqueueAgentActivityHookEvent, yr as createUpgradeConfirmationGuideError, yt as runDaemonRunAfterEntryChecks, z as resolveHumanControllerDisplayName, za as resolveAuthenticationGuidanceFromMessage, zi as assessServerRequiredVersion, zn as formatRemovedCcRelationMessage, zo as outJsonLine, zr as runPendingDaemonServiceUpdate, zt as toStructuredGatewayFailure } from "./command-D3JnXEV4.js";
|
|
5
|
+
import { $ as ownerComputerDiagnosticsSchema, $t as agentActivityInventorySessionStatusSchema, B as sleep, Bt as agentActivityProviderSchema, Ct as authProfileKindSchema, D as toStructuredApiClientFailure, F as OPENMELD_HEADER_PROFILE_ID, G as projectSpaceDispatchTraceFinalVisibleOutcome, Ht as agentActivitySnapshotQuerySchema, J as spaceDispatchTraceDispatchStatusSchema, K as resolveSpaceDispatchTraceRootCause, Ot as submitFeedbackIssueRequestSchema, Qt as agentActivityInventorySessionOriginSchema, Vt as agentActivitySessionStatusSchema, W as SPACE_DISPATCH_TRACE_RESPONSE_CONTRACT_VERSION_HEADER, X as observabilityWakeTraceSelectorSchema, Y as spaceDispatchTraceResponseSchema, Z as projectObservabilityWakeCorrelation, _ as createOrganizationSkillsApi, b as createProjectsApi, c as createAgentProfileBindingApi, d as createCurrentDeviceApi, dn as START_BOUNDED_ID_SCHEMA, en as agentActivitySessionInventoryQuerySchema, et as projectOwnerComputerLocalRuntimes, f as createFeedbackApi, fn as START_BOUNDED_VERSION_SCHEMA, g as createOrganizationApi, gn as localAgentCatalogSchema, gt as organizationSkillBundleSchema, hn as startReplyReadinessSummarySchema, l as createCenterAgentApi, mn as START_TRIMMED_NON_EMPTY_STRING_SCHEMA, nn as localAgentSessionProviderSchema, nt as DEFAULT_AGENT_PROFILE_CREATION_CONFIGURATION, pn as START_ISO_DATE_TIME_SCHEMA, q as spaceDispatchTraceAttemptStatusSchema, rt as agentProfileCreationConfigurationSchema, s as createAgentActivityApi, tt as summarizeComputerFileAccessPolicy, u as createComputerFileAccessApi, v as createPrepareReadinessApi, wt as authProfileManagedRoleSchema, x as createRoutinesApi, yt as stringifyOrganizationSkillBundleCanonicalJson } from "./dist-tBSl0WJC.js";
|
|
6
|
+
import { At as centerAgentInteractionSourceSchema, Er as trimmedStringFromUnknown, Ft as isSpaceFileTextEditable, Gn as clientMessageIdSchema, Rt as resolveSpaceFileMimeType, _r as openMeldRuntimeProfileIdSchema, an as spaceContractFieldsSchema, en as dispatchExecutionSchema, fr as openMeldProfileIdSchema, kt as spaceStatusSchema, on as spaceContractSchema, tn as spaceThreadContextSchema, vn as messageEnvelopeSchema, wr as nonEmptyTrimmedStringFromUnknown } from "./runtime-transport-DTqyhBcv.js";
|
|
7
7
|
import { r as daemonServiceLaneSchema } from "./service-contract-DZWQdPz5.js";
|
|
8
8
|
import { O as getDaemonStatus } from "./daemon-runtime-lease-DiRoGxhm.js";
|
|
9
|
-
import { a as getCurrentAuthOwnerUserId, c as updateAuthSessionActiveOrganization, d as resolveOpenMeldDistribution, i as getAuthSessionState, l as runMacOsNativeKeychainHelperIfRequested, n as clearAuthSession, o as normalizeStoredActiveOrganization, r as getAuthSessionMetadata, u as isBinaryDistribution } from "./auth-session-
|
|
10
|
-
import { c as buildRequestAuthHeaders, d as buildOpenMeldRequestContextFromProfile, n as createCliApiClientFoundation, p as deriveAuthBaseUrlFromGatewayUrl, r as fetchSpaceRequestWithTimeout, s as buildOpenMeldRequestContextHeadersWithAuth } from "./api-client-foundation-
|
|
9
|
+
import { a as getCurrentAuthOwnerUserId, c as updateAuthSessionActiveOrganization, d as resolveOpenMeldDistribution, i as getAuthSessionState, l as runMacOsNativeKeychainHelperIfRequested, n as clearAuthSession, o as normalizeStoredActiveOrganization, r as getAuthSessionMetadata, u as isBinaryDistribution } from "./auth-session-DIMnEdJJ.js";
|
|
10
|
+
import { c as buildRequestAuthHeaders, d as buildOpenMeldRequestContextFromProfile, n as createCliApiClientFoundation, p as deriveAuthBaseUrlFromGatewayUrl, r as fetchSpaceRequestWithTimeout, s as buildOpenMeldRequestContextHeadersWithAuth } from "./api-client-foundation-Dkpm10n_.js";
|
|
11
11
|
import { Command, Option } from "commander";
|
|
12
12
|
import os, { homedir, hostname, release, tmpdir } from "node:os";
|
|
13
13
|
import { z } from "zod/v4";
|
|
@@ -2997,77 +2997,6 @@ function formatNpmPackageAcquisitionFailureDiagnosis(diagnosis) {
|
|
|
2997
2997
|
].join("\n");
|
|
2998
2998
|
}
|
|
2999
2999
|
//#endregion
|
|
3000
|
-
//#region src/system/local-service-alignment-progress-ui.ts
|
|
3001
|
-
const DEFAULT_SPINNER_DELAY_MS = 250;
|
|
3002
|
-
function createDaemonServiceAlignmentProgressUi(input) {
|
|
3003
|
-
if (!(input.view === "human" && (input.isTTY ?? process.stdout.isTTY) === true)) return {
|
|
3004
|
-
onProgress: () => void 0,
|
|
3005
|
-
complete: () => void 0,
|
|
3006
|
-
fail: () => void 0
|
|
3007
|
-
};
|
|
3008
|
-
const progressSpinner = spinner();
|
|
3009
|
-
const delayMs = input.delayMs ?? DEFAULT_SPINNER_DELAY_MS;
|
|
3010
|
-
let pendingTimer = null;
|
|
3011
|
-
let spinnerVisible = false;
|
|
3012
|
-
let latestMessage = resolveAlignmentProgressMessage("inspecting_local_service");
|
|
3013
|
-
const clearPendingTimer = () => {
|
|
3014
|
-
if (!pendingTimer) return;
|
|
3015
|
-
clearTimeout(pendingTimer);
|
|
3016
|
-
pendingTimer = null;
|
|
3017
|
-
};
|
|
3018
|
-
const ensureSpinnerStarted = () => {
|
|
3019
|
-
if (spinnerVisible || pendingTimer) return;
|
|
3020
|
-
pendingTimer = setTimeout(() => {
|
|
3021
|
-
pendingTimer = null;
|
|
3022
|
-
spinnerVisible = true;
|
|
3023
|
-
progressSpinner.start(latestMessage);
|
|
3024
|
-
}, delayMs);
|
|
3025
|
-
};
|
|
3026
|
-
return {
|
|
3027
|
-
onProgress: (step) => {
|
|
3028
|
-
latestMessage = resolveAlignmentProgressMessage(step);
|
|
3029
|
-
if (spinnerVisible) {
|
|
3030
|
-
progressSpinner.message(latestMessage);
|
|
3031
|
-
return;
|
|
3032
|
-
}
|
|
3033
|
-
ensureSpinnerStarted();
|
|
3034
|
-
},
|
|
3035
|
-
complete: (message) => {
|
|
3036
|
-
clearPendingTimer();
|
|
3037
|
-
if (!spinnerVisible) return;
|
|
3038
|
-
spinnerVisible = false;
|
|
3039
|
-
if (message) {
|
|
3040
|
-
progressSpinner.stop(message);
|
|
3041
|
-
return;
|
|
3042
|
-
}
|
|
3043
|
-
progressSpinner.clear();
|
|
3044
|
-
},
|
|
3045
|
-
fail: () => {
|
|
3046
|
-
clearPendingTimer();
|
|
3047
|
-
if (!spinnerVisible) return;
|
|
3048
|
-
spinnerVisible = false;
|
|
3049
|
-
progressSpinner.clear();
|
|
3050
|
-
}
|
|
3051
|
-
};
|
|
3052
|
-
}
|
|
3053
|
-
function resolveAlignmentProgressMessage(step) {
|
|
3054
|
-
switch (step) {
|
|
3055
|
-
case "inspecting_local_service": return "Inspecting local OpenMeld service...";
|
|
3056
|
-
case "backing_up_runtime_data": return "Backing up OpenMeld service data...";
|
|
3057
|
-
case "stopping_old_service_processes": return "Stopping old OpenMeld service processes...";
|
|
3058
|
-
case "removing_system_service_registration": return "Removing old OpenMeld service registration...";
|
|
3059
|
-
case "cleaning_old_service_files": return "Cleaning old OpenMeld service files...";
|
|
3060
|
-
case "preparing_latest_service_bundle": return "Checking the replacement OpenMeld Service...";
|
|
3061
|
-
case "installing_latest_service_bundle": return "Updating OpenMeld Service files...";
|
|
3062
|
-
case "installing_system_service_registration": return "Registering OpenMeld background service...";
|
|
3063
|
-
case "restoring_runtime_data": return "Restoring local OpenMeld service data...";
|
|
3064
|
-
case "starting_background_service": return "Starting OpenMeld background service...";
|
|
3065
|
-
case "verifying_service_health": return "Verifying OpenMeld service health...";
|
|
3066
|
-
case "cleaning_stale_backups": return "Cleaning temporary OpenMeld service backups...";
|
|
3067
|
-
default: return "Aligning OpenMeld background service...";
|
|
3068
|
-
}
|
|
3069
|
-
}
|
|
3070
|
-
//#endregion
|
|
3071
3000
|
//#region src/commands/top-level-agent-overview.ts
|
|
3072
3001
|
function emitTopLevelAgentOverview(input) {
|
|
3073
3002
|
input.presenter.data({
|
|
@@ -3102,6 +3031,8 @@ const OPENMELD_PACKAGE_NAME = "openmeld";
|
|
|
3102
3031
|
const CLI_BINARY_DOWNLOAD_TIMEOUT_MS = 6e4;
|
|
3103
3032
|
const BINARY_MANUAL_OPENMELD_UPGRADE_COMMAND = "curl -fsSL 'https://openmeld.ai/setup?dist=binary' | sh";
|
|
3104
3033
|
const INSTALL_SELF_JSON_LINE_SPLIT_RE = /\r?\n/u;
|
|
3034
|
+
const SERVICE_CHECK_STARTED_TEXT = "Checking OpenMeld Service";
|
|
3035
|
+
const SERVICE_CHECK_COMPLETED_TEXT = "OpenMeld Service check finished.";
|
|
3105
3036
|
const UPGRADE_INTERNAL_ALIGN_SERVICE_FLAG$1 = "--internal-align-service";
|
|
3106
3037
|
var UpgradeOutputHandledError = class extends Error {
|
|
3107
3038
|
code = "openmeld.upgrade.output_handled";
|
|
@@ -3311,8 +3242,8 @@ async function installAndReconcileBinaryUpgrade(input) {
|
|
|
3311
3242
|
presenter: input.presenter,
|
|
3312
3243
|
resolvedView: input.resolvedView,
|
|
3313
3244
|
code: "upgrade.service_alignment",
|
|
3314
|
-
startedText:
|
|
3315
|
-
completedText:
|
|
3245
|
+
startedText: SERVICE_CHECK_STARTED_TEXT,
|
|
3246
|
+
completedText: SERVICE_CHECK_COMPLETED_TEXT,
|
|
3316
3247
|
run: async () => await handoffUpgradeServiceAlignmentToLatestBinary({
|
|
3317
3248
|
resolvedView: input.resolvedView,
|
|
3318
3249
|
command: binaryInstall.managedBinaryPath,
|
|
@@ -3360,8 +3291,8 @@ async function installAndReconcileNpmUpgrade(input) {
|
|
|
3360
3291
|
presenter: input.presenter,
|
|
3361
3292
|
resolvedView: input.resolvedView,
|
|
3362
3293
|
code: "upgrade.service_alignment",
|
|
3363
|
-
startedText:
|
|
3364
|
-
completedText:
|
|
3294
|
+
startedText: SERVICE_CHECK_STARTED_TEXT,
|
|
3295
|
+
completedText: SERVICE_CHECK_COMPLETED_TEXT,
|
|
3365
3296
|
run: async () => await handoffUpgradeServiceAlignmentToLatestBinary({
|
|
3366
3297
|
resolvedView: input.resolvedView,
|
|
3367
3298
|
command: process.execPath,
|
|
@@ -3623,60 +3554,26 @@ async function runInternalUpgradeServiceAlignment(input) {
|
|
|
3623
3554
|
});
|
|
3624
3555
|
throw new UpgradeOutputHandledError(errorMessage);
|
|
3625
3556
|
}
|
|
3626
|
-
const
|
|
3627
|
-
|
|
3628
|
-
|
|
3629
|
-
|
|
3630
|
-
...input.cliScriptPath ? { cliScriptPath: input.cliScriptPath } : {},
|
|
3631
|
-
onProgress: alignmentProgressUi.onProgress
|
|
3557
|
+
const scheduled = await scheduleDaemonServiceUpdate({
|
|
3558
|
+
targetVersion: input.daemonVersion,
|
|
3559
|
+
urgency: await resolveServiceUpdateUrgency(),
|
|
3560
|
+
...input.cliScriptPath ? { cliScriptPath: input.cliScriptPath } : {}
|
|
3632
3561
|
});
|
|
3633
|
-
if (
|
|
3634
|
-
|
|
3635
|
-
|
|
3636
|
-
|
|
3637
|
-
resolvedView: input.resolvedView,
|
|
3638
|
-
expectedVersion: input.daemonVersion
|
|
3639
|
-
});
|
|
3640
|
-
return;
|
|
3641
|
-
}
|
|
3642
|
-
if (alignmentResult.status === "stopped_safe") {
|
|
3643
|
-
alignmentProgressUi.fail();
|
|
3644
|
-
emitUpgradeReconcileStoppedSafe({
|
|
3645
|
-
presenter: input.presenter,
|
|
3646
|
-
resolvedView: input.resolvedView,
|
|
3647
|
-
expectedVersion: input.daemonVersion,
|
|
3648
|
-
errorMessage: alignmentResult.errorMessage,
|
|
3649
|
-
failureStage: alignmentResult.failureStage ?? null,
|
|
3650
|
-
evidencePath: alignmentResult.evidencePath ?? null
|
|
3651
|
-
});
|
|
3652
|
-
return;
|
|
3653
|
-
}
|
|
3654
|
-
if (alignmentResult.status === "already_aligned") {
|
|
3655
|
-
alignmentProgressUi.complete();
|
|
3656
|
-
emitUpgradeReconcileAlreadyCurrent({
|
|
3657
|
-
presenter: input.presenter,
|
|
3658
|
-
resolvedView: input.resolvedView,
|
|
3659
|
-
expectedVersion: input.daemonVersion
|
|
3562
|
+
if (input.resolvedView === "human") {
|
|
3563
|
+
input.presenter.line({
|
|
3564
|
+
code: "upgrade.reconcile.scheduled",
|
|
3565
|
+
text: "OpenMeld will finish updating the Service in the background. You can close this Terminal."
|
|
3660
3566
|
});
|
|
3661
3567
|
return;
|
|
3662
3568
|
}
|
|
3663
|
-
|
|
3664
|
-
|
|
3665
|
-
|
|
3666
|
-
|
|
3667
|
-
|
|
3668
|
-
|
|
3669
|
-
|
|
3670
|
-
backupDataPath: alignmentResult.backupDataPath,
|
|
3671
|
-
failureStage: alignmentResult.failureStage ?? null,
|
|
3672
|
-
evidencePath: alignmentResult.evidencePath ?? null
|
|
3673
|
-
}),
|
|
3674
|
-
errorMessage,
|
|
3675
|
-
backupDataPath: alignmentResult.status === "failed" ? alignmentResult.backupDataPath : null,
|
|
3676
|
-
failureStage: alignmentResult.status === "failed" ? alignmentResult.failureStage ?? null : null,
|
|
3677
|
-
evidencePath: alignmentResult.status === "failed" ? alignmentResult.evidencePath ?? null : null
|
|
3569
|
+
input.presenter.data({
|
|
3570
|
+
code: "upgrade.reconcile.scheduled",
|
|
3571
|
+
payload: {
|
|
3572
|
+
status: scheduled.status,
|
|
3573
|
+
jobId: scheduled.job.jobId,
|
|
3574
|
+
targetVersion: scheduled.job.targetVersion
|
|
3575
|
+
}
|
|
3678
3576
|
});
|
|
3679
|
-
throw new UpgradeOutputHandledError(errorMessage);
|
|
3680
3577
|
}
|
|
3681
3578
|
async function handoffUpgradeServiceAlignmentToLatestBinary(input) {
|
|
3682
3579
|
const useInheritedOutput = input.resolvedView === "human" && process.stdout.isTTY === true && process.stderr.isTTY === true;
|
|
@@ -3782,12 +3679,6 @@ function buildUpgradeAlignmentBlockedMessage(reasonCodes) {
|
|
|
3782
3679
|
if (reasonCodes.includes("downgrade_blocked")) return formatDaemonServiceDowngradeBlockedRecommendation({ expectedVersion: package_default.version });
|
|
3783
3680
|
return formatInlineOpenMeldCliCommands(`Service alignment is blocked (${reasonCodes.length > 0 ? reasonCodes.join(", ") : "unknown"}). Please run \`openmeld service status\` or \`openmeld service repair\` manually.`);
|
|
3784
3681
|
}
|
|
3785
|
-
function emitUpgradeReconcileCompleted(input) {
|
|
3786
|
-
input.presenter.line({
|
|
3787
|
-
code: "upgrade.reconcile.completed",
|
|
3788
|
-
text: `OpenMeld Service reconciled to v${input.expectedVersion}.`
|
|
3789
|
-
});
|
|
3790
|
-
}
|
|
3791
3682
|
function emitUpgradeReconcileAlreadyCurrent(input) {
|
|
3792
3683
|
if (input.resolvedView === "human") {
|
|
3793
3684
|
input.presenter.line({
|
|
@@ -3825,31 +3716,6 @@ function emitUpgradeReconcileFailure(input) {
|
|
|
3825
3716
|
}
|
|
3826
3717
|
});
|
|
3827
3718
|
}
|
|
3828
|
-
function emitUpgradeReconcileStoppedSafe(input) {
|
|
3829
|
-
const message = formatInlineOpenMeldCliCommands(`OpenMeld Service reconciled to v${input.expectedVersion} and is safely stopped on the current version. OpenMeld did not roll back to older local service state. Run \`openmeld service start\` when you want to start it again.${input.errorMessage.length > 0 ? ` Reason: ${input.errorMessage}.` : ""}${input.failureStage || input.evidencePath ? ` ${formatDaemonFailureContextText({
|
|
3830
|
-
failureStage: input.failureStage ?? null,
|
|
3831
|
-
evidencePath: input.evidencePath
|
|
3832
|
-
})}` : ""}`);
|
|
3833
|
-
if (input.resolvedView === "human") {
|
|
3834
|
-
input.presenter.line({
|
|
3835
|
-
code: "upgrade.reconcile.stopped_safe",
|
|
3836
|
-
text: message
|
|
3837
|
-
});
|
|
3838
|
-
return;
|
|
3839
|
-
}
|
|
3840
|
-
input.presenter.data({
|
|
3841
|
-
code: "upgrade.reconcile.stopped_safe",
|
|
3842
|
-
payload: {
|
|
3843
|
-
status: "stopped_safe",
|
|
3844
|
-
expectedVersion: input.expectedVersion,
|
|
3845
|
-
message,
|
|
3846
|
-
errorMessage: input.errorMessage,
|
|
3847
|
-
...input.failureStage ? { failureStage: input.failureStage } : {},
|
|
3848
|
-
...input.evidencePath ? { evidencePath: input.evidencePath } : {},
|
|
3849
|
-
command: "openmeld service start"
|
|
3850
|
-
}
|
|
3851
|
-
});
|
|
3852
|
-
}
|
|
3853
3719
|
function resolveUpgradeReconcileSkipMessage(reason) {
|
|
3854
3720
|
if (reason === "not_installed") return {
|
|
3855
3721
|
text: formatDaemonServiceMissingRecommendation(),
|
|
@@ -5922,6 +5788,77 @@ function emitSelectedProfileStatus(input) {
|
|
|
5922
5788
|
});
|
|
5923
5789
|
}
|
|
5924
5790
|
//#endregion
|
|
5791
|
+
//#region src/system/local-service-alignment-progress-ui.ts
|
|
5792
|
+
const DEFAULT_SPINNER_DELAY_MS = 250;
|
|
5793
|
+
function createDaemonServiceAlignmentProgressUi(input) {
|
|
5794
|
+
if (!(input.view === "human" && (input.isTTY ?? process.stdout.isTTY) === true)) return {
|
|
5795
|
+
onProgress: () => void 0,
|
|
5796
|
+
complete: () => void 0,
|
|
5797
|
+
fail: () => void 0
|
|
5798
|
+
};
|
|
5799
|
+
const progressSpinner = spinner();
|
|
5800
|
+
const delayMs = input.delayMs ?? DEFAULT_SPINNER_DELAY_MS;
|
|
5801
|
+
let pendingTimer = null;
|
|
5802
|
+
let spinnerVisible = false;
|
|
5803
|
+
let latestMessage = resolveAlignmentProgressMessage("inspecting_local_service");
|
|
5804
|
+
const clearPendingTimer = () => {
|
|
5805
|
+
if (!pendingTimer) return;
|
|
5806
|
+
clearTimeout(pendingTimer);
|
|
5807
|
+
pendingTimer = null;
|
|
5808
|
+
};
|
|
5809
|
+
const ensureSpinnerStarted = () => {
|
|
5810
|
+
if (spinnerVisible || pendingTimer) return;
|
|
5811
|
+
pendingTimer = setTimeout(() => {
|
|
5812
|
+
pendingTimer = null;
|
|
5813
|
+
spinnerVisible = true;
|
|
5814
|
+
progressSpinner.start(latestMessage);
|
|
5815
|
+
}, delayMs);
|
|
5816
|
+
};
|
|
5817
|
+
return {
|
|
5818
|
+
onProgress: (step) => {
|
|
5819
|
+
latestMessage = resolveAlignmentProgressMessage(step);
|
|
5820
|
+
if (spinnerVisible) {
|
|
5821
|
+
progressSpinner.message(latestMessage);
|
|
5822
|
+
return;
|
|
5823
|
+
}
|
|
5824
|
+
ensureSpinnerStarted();
|
|
5825
|
+
},
|
|
5826
|
+
complete: (message) => {
|
|
5827
|
+
clearPendingTimer();
|
|
5828
|
+
if (!spinnerVisible) return;
|
|
5829
|
+
spinnerVisible = false;
|
|
5830
|
+
if (message) {
|
|
5831
|
+
progressSpinner.stop(message);
|
|
5832
|
+
return;
|
|
5833
|
+
}
|
|
5834
|
+
progressSpinner.clear();
|
|
5835
|
+
},
|
|
5836
|
+
fail: () => {
|
|
5837
|
+
clearPendingTimer();
|
|
5838
|
+
if (!spinnerVisible) return;
|
|
5839
|
+
spinnerVisible = false;
|
|
5840
|
+
progressSpinner.clear();
|
|
5841
|
+
}
|
|
5842
|
+
};
|
|
5843
|
+
}
|
|
5844
|
+
function resolveAlignmentProgressMessage(step) {
|
|
5845
|
+
switch (step) {
|
|
5846
|
+
case "inspecting_local_service": return "Inspecting local OpenMeld service...";
|
|
5847
|
+
case "backing_up_runtime_data": return "Backing up OpenMeld service data...";
|
|
5848
|
+
case "stopping_old_service_processes": return "Stopping old OpenMeld service processes...";
|
|
5849
|
+
case "removing_system_service_registration": return "Removing old OpenMeld service registration...";
|
|
5850
|
+
case "cleaning_old_service_files": return "Cleaning old OpenMeld service files...";
|
|
5851
|
+
case "preparing_latest_service_bundle": return "Checking the replacement OpenMeld Service...";
|
|
5852
|
+
case "installing_latest_service_bundle": return "Updating OpenMeld Service files...";
|
|
5853
|
+
case "installing_system_service_registration": return "Registering OpenMeld background service...";
|
|
5854
|
+
case "restoring_runtime_data": return "Restoring local OpenMeld service data...";
|
|
5855
|
+
case "starting_background_service": return "Starting OpenMeld background service...";
|
|
5856
|
+
case "verifying_service_health": return "Verifying OpenMeld service health...";
|
|
5857
|
+
case "cleaning_stale_backups": return "Cleaning temporary OpenMeld service backups...";
|
|
5858
|
+
default: return "Aligning OpenMeld background service...";
|
|
5859
|
+
}
|
|
5860
|
+
}
|
|
5861
|
+
//#endregion
|
|
5925
5862
|
//#region src/command-entry-checks/check-service.ts
|
|
5926
5863
|
async function runServiceCheck(input) {
|
|
5927
5864
|
if (input.requirement.mode === "skip") return { status: "continue" };
|
|
@@ -18620,11 +18557,19 @@ async function maybeCompleteServiceReadinessAfterPreparation(input) {
|
|
|
18620
18557
|
expectedVersion: resolveCurrentDaemonExpectedVersion(),
|
|
18621
18558
|
intent: "status_cleanup"
|
|
18622
18559
|
});
|
|
18623
|
-
const
|
|
18624
|
-
const
|
|
18560
|
+
const wakeability = classifyDaemonServiceWakeability({ inventory });
|
|
18561
|
+
const startability = classifyDaemonServiceRunStartability({ inventory });
|
|
18562
|
+
const hasBlockingServiceDrift = wakeability.blocksWake;
|
|
18563
|
+
const serviceRunWouldBeBlocked = startability.blocksStart;
|
|
18564
|
+
const scheduleBackgroundUpdate = shouldScheduleSetupServiceUpdate({
|
|
18565
|
+
inventory,
|
|
18566
|
+
serviceRunWouldBeBlocked,
|
|
18567
|
+
wakeability
|
|
18568
|
+
});
|
|
18625
18569
|
if (hasBlockingServiceDrift || serviceRunWouldBeBlocked || reasonCodes.includes("service.drifted")) {
|
|
18626
18570
|
const refreshOutcome = await runDaemonReinstall({
|
|
18627
18571
|
agentOverviewHandled: true,
|
|
18572
|
+
...scheduleBackgroundUpdate ? { displayAction: "update" } : {},
|
|
18628
18573
|
gatewayUrl: await resolveBaseUrl(),
|
|
18629
18574
|
profile: input.profile.openMeldProfileId,
|
|
18630
18575
|
view: input.view
|
|
@@ -18659,6 +18604,9 @@ async function maybeCompleteServiceReadinessAfterPreparation(input) {
|
|
|
18659
18604
|
}
|
|
18660
18605
|
return "completed";
|
|
18661
18606
|
}
|
|
18607
|
+
function shouldScheduleSetupServiceUpdate(input) {
|
|
18608
|
+
return input.inventory.anomalies.some((anomaly) => anomaly.code === "version_outdated" || anomaly.code === "bundle_version_drift") && input.wakeability.executionEvidenceSafe && !input.wakeability.blocksWake && !input.serviceRunWouldBeBlocked;
|
|
18609
|
+
}
|
|
18662
18610
|
function collectReadinessReasonCodes(input) {
|
|
18663
18611
|
const reasonCodes = [];
|
|
18664
18612
|
for (const reasonCode of input.deviceReplyReadiness.reasonCodes) if (!reasonCodes.includes(reasonCode)) reasonCodes.push(reasonCode);
|
|
@@ -27399,7 +27347,7 @@ function normalizeOptionalString(value) {
|
|
|
27399
27347
|
return normalized.length > 0 ? normalized : null;
|
|
27400
27348
|
}
|
|
27401
27349
|
async function runDefaultSpaceAddMeMembership(input) {
|
|
27402
|
-
const { runSpaceAddMeMembership } = await import("./add-me-membership-
|
|
27350
|
+
const { runSpaceAddMeMembership } = await import("./add-me-membership-TPvrNV3W.js");
|
|
27403
27351
|
return await runSpaceAddMeMembership(input);
|
|
27404
27352
|
}
|
|
27405
27353
|
//#endregion
|
|
@@ -32160,6 +32108,9 @@ const serviceCmd = program.command("service").alias("daemon").description("Manag
|
|
|
32160
32108
|
});
|
|
32161
32109
|
serviceCmd.command("start").description("Start OpenMeld Service on this device.").option("--mode <mode>", "Start mode: background (default) or foreground").option("--gateway-url <url>", "OpenMeld gateway URL (command line, OPENMELD_GATEWAY_URL, or saved OpenMeld settings)").option("--profile <id-or-name>", "Optional OpenMeld profile override used for owner resolution").option("--device-id <id>", "Override daemon device id for this run").option("--heartbeat-ms <n>", "Heartbeat interval in milliseconds (default: 25000)").option("--json", "Print machine-readable JSON.", false).action(runServiceStartCliAction);
|
|
32162
32110
|
serviceCmd.command("run", { hidden: true }).description("Run OpenMeld Service in this process. System service entrypoint (launchd/systemd unit definitions call this); humans should use `openmeld service start`.").option("--mode <mode>", "Run mode: background (default) or foreground").option("--gateway-url <url>", "OpenMeld gateway URL (command line, OPENMELD_GATEWAY_URL, or saved OpenMeld settings)").option("--profile <id-or-name>", "Optional OpenMeld profile override used for owner resolution").option("--device-id <id>", "Override daemon device id for this run").option("--heartbeat-ms <n>", "Heartbeat interval in milliseconds (default: 25000)").action(runServiceStartCliAction);
|
|
32111
|
+
serviceCmd.command("update-worker", { hidden: true }).description("Resume one durable OpenMeld Service update in the background.").action(async () => {
|
|
32112
|
+
if ((await runPendingDaemonServiceUpdate())?.status === "failed") process.exitCode = 1;
|
|
32113
|
+
});
|
|
32163
32114
|
serviceCmd.command("status").description("Show OpenMeld Service status on this device.").option("--json", "Print machine-readable JSON.", false).option("--profile <id-or-name>", "Optional OpenMeld profile context for local service diagnostics").action(async (opts) => {
|
|
32164
32115
|
const json = opts.json === true;
|
|
32165
32116
|
const view = json ? "agent" : getGlobalViewOption();
|
|
@@ -32330,7 +32281,7 @@ serviceCmd.command("uninstall").description("Remove OpenMeld Service from this d
|
|
|
32330
32281
|
serviceCmd.command("repair").description("Repair OpenMeld Service on this device.").option("--force", "Allow force-continue when graceful stop/drain times out (may drop in-flight tasks)").option("--json", "Print machine-readable JSON.", false).action(async (opts) => {
|
|
32331
32282
|
await runServiceMaintenanceCliAction(opts, "repair");
|
|
32332
32283
|
});
|
|
32333
|
-
serviceCmd.command("update").description("Update OpenMeld Service on this device.").option("--force", "
|
|
32284
|
+
serviceCmd.command("update").description("Update OpenMeld Service on this device.").option("--force", "This option is no longer needed. Updates always let running Agent work finish.").option("--json", "Print machine-readable JSON.", false).action(async (opts) => {
|
|
32334
32285
|
await runServiceMaintenanceCliAction(opts, "update");
|
|
32335
32286
|
});
|
|
32336
32287
|
serviceCmd.command("reinstall", { hidden: true }).description("Deprecated alias for `openmeld service repair`.").option("--force", "Allow force-continue when graceful stop/drain times out (may drop in-flight tasks)").option("--json", "Print machine-readable JSON.", false).action(async (opts) => {
|