Marked 3.2.4 (1218), Mac App Store, macOS 26.5 (via Claude Code)
close document 1 errors with -1708. The document class has no close in the dictionary. close window "name" returns success but the document stays in the app's document list and comes back on the next launch.
This means a script that opens files has no way to close them. With NSQuitAlwaysKeepsWindows on, documents accumulate across sessions. After enough pile up, I've seen File ▸ Publish… grey out for a valid document; quitting and relaunching fixes it immediately.
The workaround is to raise each new window via AXRaise and click File ▸ Close through System Events. Keystroke ⌘W fails silently; only the menu item works.
Either close on document or close window actually releasing the document would fix this.