Scripts: queued startup runs keep the file access scope of the request that queued them

In the app, script.startup.run starts only the first queued run inside the request; the later
startup scripts and the chosen script start from the frame loop. Each of them now starts, and its
file is read, in the scope captured when the queue was built, so a confined request's automation
roots apply to every run it queued.
This commit is contained in:
dotCooCoo committed 2026-11-22 08:06:13 -08:00
1 parent 81dfbf4078
commit 909c169afe
5 files changed
+41 -2

No files matched your search

+1
View File
@@ -1884,6 +1884,7 @@ impl Session {
pub fn script_abandon(&mut self) -> bool {
// The runs queued after it are not started.
self.script_queue.clear();
self.script_queue_scope = None;
self.startup_ended();
let Some(key) = self.script_key.take() else { return false };
let Some(job) = JOBS.with(|jobs| jobs.borrow_mut().remove(&key.id)) else {