fix(ide): upgrade managed agent and migrate existing member media connection
This commit is contained in:
@@ -3,6 +3,18 @@ export interface BootstrapMarkerLike {
|
||||
schemaVersion?: unknown
|
||||
}
|
||||
|
||||
// An AITURK package upgrade must bring its managed agent along with the UI.
|
||||
// Developer checkouts and installs without proven Desktop ownership keep their
|
||||
// existing launch behavior. The installer preserves edits and refuses rollback.
|
||||
export function needsPackagedRuntimeUpgrade(
|
||||
packaged: boolean, stamp: { commit?: string; source?: string } | null,
|
||||
marker: BootstrapMarkerLike | null
|
||||
): boolean {
|
||||
return Boolean(packaged && stamp?.source !== 'fallback' &&
|
||||
/^[0-9a-f]{40}$/i.test(stamp?.commit || '') && !/^0+$/.test(stamp?.commit || '') &&
|
||||
hasValidBootstrapMarker(marker, 1) && marker?.pinnedCommit !== stamp?.commit)
|
||||
}
|
||||
|
||||
export interface ActiveRuntimeState {
|
||||
hasValidMarker: boolean
|
||||
shouldUseActiveRuntime: boolean
|
||||
|
||||
Reference in New Issue
Block a user