Still reproduces on 0.1.6-nightly.20261031.3956 (macOS 27.0.1, Apple silicon, SentinelOne agent 26.1.4 installed). The desktop trace shows the same code: null, SIGKILL from runMacLookup() about 7 ms after the spawn.
One correction to the analysis above: the trigger is the size of the inline -e argument, not the ObjC bridge. A JXA script with no ObjC calls, only a comment, gets killed once it passes 938 bytes:
| 1 | # 938 bytes: exits 0 |
| 2 | osascript -l JavaScript -e "1//$(printf 'a%.0s' $(seq 1 935))" |
| 3 | # 939 bytes: exits 137 (SIGKILL) |
| 4 | osascript -l JavaScript -e "1//$(printf 'a%.0s' $(seq 1 936))" |
- AppleScript (
osascript -e) with a 2,000-byte script is not killed. Only-l JavaScript -ehits the limit. - The same long script works from a file and from stdin (
osascript -l JavaScript -). - The lookup script is 1,226 bytes, so it is over the limit. The modifier-pair poller in
MacModifierPairShortcutProcess.tsis under it, which explains why it survives. - Every part of the lookup script works through
-ewhen run on its own under the limit, includingCGWindowListCopyWindowInfo, the window loop andfrontmostApplication.
This supports the stdin approach in #21749. Any future osascript -l JavaScript -e call with a script over about 900 bytes will fail the same way on machines with this agent.
Investigated with T3 Code using Claude Opus 5.5.