I’ve posted a support ticket about this, but I am posting it here because it has caused some of my scripts to break or behave in strange ways
The behaviour of the applescript import verb appears to have changed in 2.8.8. Now as soon as an applescript imports a document using the ‘import’ verb, the imported document is automatically selected.
These seems to me to be an undesirable behaviour. An import action taken by a script should be silent to the user of the script unless the script specifically makes the imported document the selected document. The script may take other actions in the background including wanting to keep the existing selection.
If you have existing scripts which rely on the fact that the selection state hasn’t changed after an import, the scripts may not work or may give an unexpected result.
A script splits up a document into pages and imports them. Each import should not result in a new automatic selection of the imported document.
This is a brief applescript which demonstrates the behaviour
tell application id "DNtp" activate try set theInbox to (create location "/Inbox") -- this results in the existing selection being removed and the new test.jog being selected and displayed set r to import "/Users/[user]/Desktop/test.jpg" name "test.jpg" to theInbox on error error_message number error_number if the error_number is not -128 then display alert "DEVONthink Pro" message error_message as warning end try end tell