PREPARE AND RESTORE DON'T WORK IN TAHOE 26.2

42 views
Skip to first unread message

JV

unread,
Feb 4, 2026, 10:22:18 AM (7 days ago) Feb 4
to QLab
Hi, in Qlab 5.5.9  the script prepare and restore doesn't work: 


error capture screen



Screenshot 2026-02-04 at 10.17.47 AM.png
Screenshot 2026-02-04 at 10.18.10 AM.png
Screenshot 2026-02-04 at 10.17.58 AM.png

JV

unread,
Feb 4, 2026, 10:26:17 AM (7 days ago) Feb 4
to QLab
I add the code, highlighting in bold the error that the program underlines.



tell application id "com.figure53.QLab.5" to tell front workspace

display dialog "This script will disable Spotlight, Time Machine, system sleep, display sleep, screen saver, and software update checking." & return & return & "You'll be asked for your system password more than once, and in more than one way. QLab does not learn or save your password, and nothing is transmitted over the internet during this process." & return & return & "You might be asked to grant permissions in Security & Privacy preferences. Fear not." with title "Prepare system for QLab use?" with icon 1 buttons {"Cancel", "Prep"} default button "Prep" cancel button "Cancel"

end tell

tell application "Finder"
-- check for at least 16 GB free space on the startup disk
-- to ensure there's enough space for swap
-- free space is reported in bytes, so we do math to convert it to gigabytes
set freeSpace to ((free space of disk (name of startup disk)) / (1024 * 1024 * 0.1024) div 100) / 100

-- figure out where to place a terminal window
set screenSize to bounds of window of desktop
set screenWidth to item 3 of screenSize
set screenHeight to item 4 of screenSize
end tell

-- save current screen saver delay time and disable screen saver
tell application "System Events" to tell screen saver preferences
try
set screenSaverTime to delay interval
on error
set screenSaverTime to "1200"
end try
set delay interval to 0
end tell

tell application id "com.figure53.qlab.5" to tell front workspace
if freeSpace < 16 then
set theAlertText to "There is less than 16 GB of free space available."
set theAlertMessage to "Having too little free space available on the startup disk can prevent macOS from working properly, which can in turn cause performance problems in QLab. Please free up at least 16 GB of space on this Mac's startup disk."
display alert theAlertText message theAlertMessage as critical buttons {"OK"} default button "OK"
end if

-- save current display sleep, disk sleep, and system sleep preferences
set q name of cue "displaySleepTime" to do shell script "pmset -g | awk '$1 == \"displaysleep\" {print 0+$2}'"
set q name of cue "diskSleepTime" to do shell script "pmset -g | awk '$1 == \"disksleep\" {print 0+$2}'"
set q name of cue "sleepTime" to do shell script "pmset -g | awk '$1 == \"sleep\" {print 0+$2}'"

-- stash screen saver time in the storage cue
if class of screenSaverTime is not integer then set screenSaverTime to "1200"
set q name of cue "screenSaverTime" to screenSaverTime
end tell

-- disable time machine
tell application "Terminal"
activate
delay 1
set win to front window
set number of columns of win to 20
set number of rows of win to 10

set windowSize to bounds of win
set windowXl to item 1 of windowSize
set windowYt to item 2 of windowSize
set windowXr to item 3 of windowSize
set windowYb to item 4 of windowSize

set windowWidth to windowXr - windowXl
set windowHeight to windowYb - windowYt

set bounds of win to {¬
round ((screenWidth - windowWidth) / 2) rounding as taught in school, ¬
round ((screenHeight + windowHeight) / 2) rounding as taught in school, ¬
round ((screenWidth + windowWidth) / 2) rounding as taught in school, ¬
round ((screenHeight + windowHeight) / 2 + windowHeight) rounding as taught in school}

set number of rows of win to 1

do script "sudo tmutil disable;open -a QLab" in win
repeat until busy of win is false
delay 1
end repeat
quit
end tell

-- disable display sleep, disk sleep, and system sleep
do shell script "pmset -a displaysleep 0 disksleep 0 sleep 0" with administrator privileges

-- disable software update
do shell script "softwareupdate --schedule off" with administrator privileges

-- disable spotlight
do shell script "mdutil -ai off" with administrator privileges

-- wrap up
tell application id "com.figure53.qlab.5" to tell front workspace
activate
display dialog "QLab prep complete." with icon 1 with title "Standing by!"
end tell

Screenshot 2026-02-04 at 10.25.58 AM.png
Reply all
Reply to author
Forward
0 new messages