SpamSieve scripts after migrating from Snow Leopard to Mavericks

I got a new computer and ran the Migration Assistant. After noticing that SpamSieve didn’t work I checked out the rules and noticed that I had to move the scripts from their earlier location to ~/Library/Application Scripts/com.apple.mail. Ok, so I move them.

They show up in the Rules section of the preferences, which means I can attach them to the correct rule again. Today I notice that one of the okay messages that my mail provider decided was bad is not moved from the Junk box to the Inbox.
This is the script:

on perform_mail_action(info)
tell application “Mail”
set _mailbox to mailbox “Junk” of account “My Account”
repeat with _message in messages of _mailbox
set _source to _message’s source
tell application “SpamSieve”
set _isSpam to looks like spam message _source
end tell
if not _isSpam then
set read status of _message to false
set _message’s mailbox to mailbox “INBOX” of account “My Account”
end if
end repeat
end tell
end perform_mail_action

Is this still okay for Mavericks? I also have the suspicion that the other scripts (Train Good and Bad) aren’t working either, but I thought of trying to get this one working so I may be able to get the others working on my own again.

Thanks.

I suggest checking SpamSieve’s log to see whether it predicted this message to be good. If so, there’s likely a problem with the script moving the message back. If it did not make a prediction, the script did not run that message through SpamSieve. If it predicted the message to be spam, then SpamSieve made a mistake.

It looks OK to me, but I recommend using the official script for this, Apple Mail - Server Junk Mailbox, as I will be maintaining it going forward.

The log said the file message was deemed okay, so it should have been moved to the Inbox. Which is what made me wonder whether the scripts have changed for Mavericks. Anyway, I took the script you pointed to, and I also took the Remote Training just to make sure that works okay. As far as I can see it works like a charm.

Thanks for the scripts.