{"session": "ae4d5770-7617-4c2d-be1e-123543cc7126", "env": "main-coco-runwright", "command": "journal helper done 4214 \"coco-orphans b4f93edaa: orphaned journals are stopped at start and in the hourly tidy\" 2>&1 | tail -1 | cut -c1-50; journal helper report \"To-do 4214 is on branch coco-orphans (from origin/main 2.268.30), commit b4f93edaa. I ran no tests. New src/engine/orphans.py: it reads ps (pid, parent, age, command), recognises a journal process by journal.py, journal.pyz or runner.engines in its command and reads the journal folder it names (the path before /.journal, read whole when the path has a space, as 'Project builds' in the test folders), and finds the orphaned ones: (1) the folder is gone; (2) the folder is in a temporary place (/tmp, /var/folders and the private forms) and the process has no parent (parent 1) and has run longer than half an hour, so a test that is still running is left; then it takes every process of that folder with it (server, supervisor, workers, engine children) and sends SIGTERM. Never: this journal's own folder, this process and its parent, a folder that exists and is not temporary, and anything that is no journal (no absolute /.journal in its command). Run at the server's start (serve.py run, through bus.background so tests are not scanned) and in the hourly tidy (TidyRuntime, only when background work is on). Dry run on this machine with the real ps: 59 journal processes of 2 folders, both live projects, and nothing it would stop, so it does not hit a live project's journal. Test: the added lines at the end of test_it_runs_on_its_own_on_the_engines_clock in src/features/runtime_cleanup/test.py (a gone folder with its supervisor and worker, a temporary folder with a space in its name whose supervisor has no parent with its engine child, against a fresh test journal, a live project, this journal, and a process that is no journal).\" 2>&1 | tail -1 | cut -c1-50; journal work end 113 --how \"coco-orphans b4f93edaa\" 2>&1 | tail -1 | cut -c1-30", "parts": ["journal helper done 4214 \"coco-orphans b4f93edaa: orphaned journals are stopped at start and in the hourly tidy\" 2>&1 | tail -1 | cut -c1-50", "journal helper report \"To-do 4214 is on branch coco-orphans (from origin/main 2.268.30), commit b4f93edaa. I ran no tests. New src/engine/orphans.py: it reads ps (pid, parent, age, command), recognises a journal process by journal.py, journal.pyz or runner.engines in its command and reads the journal folder it names (the path before /.journal, read whole when the path has a space, as 'Project builds' in the test folders), and finds the orphaned ones: (1) the folder is gone; (2) the folder is in a temporary place (/tmp, /var/folders and the private forms) and the process has no parent (parent 1) and has run longer than half an hour, so a test that is still running is left; then it takes every process of that folder with it (server, supervisor, workers, engine children) and sends SIGTERM. Never: this journal's own folder, this process and its parent, a folder that exists and is not temporary, and anything that is no journal (no absolute /.journal in its command). Run at the server's start (serve.py run, through bus.background so tests are not scanned) and in the hourly tidy (TidyRuntime, only when background work is on). Dry run on this machine with the real ps: 59 journal processes of 2 folders, both live projects, and nothing it would stop, so it does not hit a live project's journal. Test: the added lines at the end of test_it_runs_on_its_own_on_the_engines_clock in src/features/runtime_cleanup/test.py (a gone folder with its supervisor and worker, a temporary folder with a space in its name whose supervisor has no parent with its engine child, against a fresh test journal, a live project, this journal, and a process that is no journal).\" 2>&1 | tail -1 | cut -c1-50", "journal work end 113 --how \"coco-orphans b4f93edaa\" 2>&1 | tail -1 | cut -c1-30"]}