Post

Replies

Boosts

Views

Activity

osascript System Events Failed to list Processes That Have The Same Name
I ran the following script while both VSCode and Windsurf were open. tell application "System Events" set electronProcesses to every application process whose name is "Electron" set outputText to "" repeat with p in electronProcesses set outputText to outputText & "Process: " & name of p set outputText to outputText & ", Displayed name: " & displayed name of p set outputText to outputText & ", Frontmost: " & frontmost of p & " " end repeat return outputText end tell The script incorrectly returned two Electron processes, where both were showing Windsurf as the displayed name. The output of the above script is: Process: Electron, Displayed name: Windsurf, Frontmost: false Process: Electron, Displayed name: Windsurf, Frontmost: false Separately, both Windsurf and VSCode share the same process name (Electron) but have different displayed names. This issue appears to affect how the frontmost application is detected, when using the following script: set frontApp to first application process whose frontmost is true The frontApp is incorrectly returned when switching between VSCode and Windsurf.
4
0
122
May ’25