{"version":"2.1.251","anchor":"background-daemon-waits-on-the-repl-process-during-terminal-","canonical_anchor":"background-daemon-waits-on-the-repl-process-during-terminal-","heading":"Background daemon waits on the REPL process during terminal teardown","tier":"notice","area":"Background Tasks","scope":null,"heads_up":null,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.251\/e\/background-daemon-waits-on-the-repl-process-during-terminal-","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.251","markdown":"### Background daemon waits on the REPL process during terminal teardown\n\nTerminal cleanup targets the right process instead of killing the whole group.\n\n**What**\n\nWhen the background daemon tears down a terminal worker, it now checks the recorded REPL process before falling back to killing the whole process group, on top of the existing attempts to close sockets. This makes cleanup less likely to kill more than it should.\n\n**Details**\n\n- The check uses the process id and start time stored for the worker, so a recycled process id is not mistaken for the original.\n- Unconditional part of background worker cleanup.\n\n**Evidence**\n\n`await UV(A.replPid, A.replProcStart)`\n\n- Area: Background Tasks\n- Tier: You'll notice\n- Useful: 3\/5\n- Signal: 2\/5"}