A scheduled launchd job using scp failed to complete because macOS went to sleep mid-transfer, interrupting the connection. Adding caffeinate -s to the job prevented system sleep during execution, resolving the issue and ensuring all files transferred reliably.