mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-12-02 19:08:33 +01:00
Use remote process authority for Cursor Stop proof
Keep local PID transition tracking inside the local observer; the remote case retains its sandbox boot and start-tick lifetime proof. 134 fixture tests and fixture typecheck pass. Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
1 parent
df1c6569f7
commit
2cad239c8c
2 files changed
+8
-1
No files matched your search
@@ -68,9 +68,12 @@ export async function runNativeActiveStopFlow(input: {
|
||||
let fixture: NativeRemoteFixture | undefined, baseline: NativeRemoteSnapshot | undefined, sealed: NativeRemoteSnapshot | undefined;
|
||||
let completed: Awaited<ReturnType<typeof stopAtPendingPermission>> | undefined;
|
||||
const observeProcesses = () => {
|
||||
// Remote ownership comes from the sandbox boot/start-tick journal. The
|
||||
// API PID transitions from the controller command to the remote runner.
|
||||
if (!observer) return;
|
||||
const run = runs[0], authority = run?.processPid ? { pid: run.processPid, groupId: run.processGroupId, startedAt: run.processStartedAt, runId: run.id } : undefined;
|
||||
if (authority) { const key = JSON.stringify(authority); if (processIdentity && processIdentity !== key) processError = true; processIdentity ??= key; }
|
||||
if (observer) processes = observer.sample(authority);
|
||||
processes = observer.sample(authority);
|
||||
};
|
||||
const load = async (): Promise<ActiveStopState> => {
|
||||
if (issue.id) issue = await api.get<Row>(`/api/issues/${issue.id}`);
|
||||
|
||||
Reference in new issue
Block a user