fix(team): require codex process evidence for activity
This commit is contained in:
parent
962721935d
commit
554112a3d8
2 changed files with 35 additions and 8 deletions
|
|
@ -99,6 +99,21 @@ describe('member runtime presentation', () => {
|
||||||
).toBe(false);
|
).toBe(false);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it('hides Codex native task activity for bootstrap-only runtime evidence without a verified process', () => {
|
||||||
|
expect(
|
||||||
|
shouldDisplayMemberCurrentTask({
|
||||||
|
member: createMember(),
|
||||||
|
isTeamAlive: true,
|
||||||
|
...createConfirmedCodexSpawn(),
|
||||||
|
runtimeEntry: createLiveRuntime({
|
||||||
|
livenessKind: 'confirmed_bootstrap',
|
||||||
|
pid: undefined,
|
||||||
|
rssBytes: undefined,
|
||||||
|
}),
|
||||||
|
})
|
||||||
|
).toBe(false);
|
||||||
|
});
|
||||||
|
|
||||||
it('marks stale confirmed Codex native spawn state as non-green runtime status', () => {
|
it('marks stale confirmed Codex native spawn state as non-green runtime status', () => {
|
||||||
const presentation = buildMemberLaunchPresentation({
|
const presentation = buildMemberLaunchPresentation({
|
||||||
member: createMember(),
|
member: createMember(),
|
||||||
|
|
@ -155,6 +170,25 @@ describe('member runtime presentation', () => {
|
||||||
expect(presentation.dotClass).toContain('bg-red-400');
|
expect(presentation.dotClass).toContain('bg-red-400');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it('does not mark bootstrap-only Codex native runtime evidence as green', () => {
|
||||||
|
const presentation = buildMemberLaunchPresentation({
|
||||||
|
member: createMember(),
|
||||||
|
spawnLivenessSource: 'heartbeat',
|
||||||
|
runtimeAdvisory: undefined,
|
||||||
|
isTeamAlive: true,
|
||||||
|
isTeamProvisioning: false,
|
||||||
|
...createConfirmedCodexSpawn(),
|
||||||
|
runtimeEntry: createLiveRuntime({
|
||||||
|
livenessKind: 'confirmed_bootstrap',
|
||||||
|
pid: undefined,
|
||||||
|
rssBytes: undefined,
|
||||||
|
}),
|
||||||
|
});
|
||||||
|
|
||||||
|
expect(presentation.launchVisualState).toBe('stale_runtime');
|
||||||
|
expect(presentation.dotClass).toContain('bg-red-400');
|
||||||
|
});
|
||||||
|
|
||||||
it('does not require runtime evidence for non-Codex teammates', () => {
|
it('does not require runtime evidence for non-Codex teammates', () => {
|
||||||
expect(
|
expect(
|
||||||
shouldDisplayMemberCurrentTask({
|
shouldDisplayMemberCurrentTask({
|
||||||
|
|
|
||||||
|
|
@ -993,14 +993,7 @@ function isCodexNativeProcessTeammate(member: ResolvedTeamMember): boolean {
|
||||||
}
|
}
|
||||||
|
|
||||||
function hasLiveRuntimeProcessEvidence(runtimeEntry: TeamAgentRuntimeEntry | undefined): boolean {
|
function hasLiveRuntimeProcessEvidence(runtimeEntry: TeamAgentRuntimeEntry | undefined): boolean {
|
||||||
if (runtimeEntry?.alive !== true) {
|
return runtimeEntry?.alive === true && runtimeEntry.livenessKind === 'runtime_process';
|
||||||
return false;
|
|
||||||
}
|
|
||||||
return (
|
|
||||||
runtimeEntry.livenessKind == null ||
|
|
||||||
runtimeEntry.livenessKind === 'runtime_process' ||
|
|
||||||
runtimeEntry.livenessKind === 'confirmed_bootstrap'
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function hasSpawnRuntimeLiveClaim({
|
function hasSpawnRuntimeLiveClaim({
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue