When creating an AppleScript Script Command by copy-pasting the official Raycast template into a newly created file, the command fails to execute with:
NSPOSIXErrorDomain 8 – Exec format error
This occurs when the script metadata contains an emoji (for example in @raycast.icon), including emojis inserted via Raycast’s own emoji picker.
The same script works correctly when:
• the template file is downloaded directly
• the emoji metadata line is removed
This suggests a Unicode encoding or normalization issue triggered by emoji metadata in combination with copy-paste file creation. The error happens before the script runs and shows up as a low-level execution error, not a metadata error. I’ve seen the same behavior with newly created scripts as well, not only when starting from the template.