Page 1 of 1

Unexpected errors

PostPosted: Sun Jan 06, 2019 1:43 pm
by justlen
Starting today, out of the blue, I've been getting errors in my Announcements plugin. I suspect something was corrupted when we had a power outage last night.

The error is:

Announcements Error Error in plugin execution ExecuteAction:

Traceback (most recent call last):
File "plugin.py", line 630, in announcementSpeakAction
KeyError: 'key not found in dict'

I tried updating my plugin to 1.0.2, but I still keep getting the error. Any suggestions? I figure my next step is to manually delete the plugin and start over from scratch.

Re: Unexpected errors

PostPosted: Sun Jan 06, 2019 2:35 pm
by DaveL17
justlen wrote:
Starting today, out of the blue, I've been getting errors in my Announcements plugin. I suspect something was corrupted when we had a power outage last night.

The error is:

Announcements Error Error in plugin execution ExecuteAction:

Traceback (most recent call last):
File "plugin.py", line 630, in announcementSpeakAction
KeyError: 'key not found in dict'

I tried updating my plugin to 1.0.2, but I still keep getting the error. Any suggestions? I figure my next step is to manually delete the plugin and start over from scratch.

Hi justlen - I can confirm this is a bug, and I'm seeing it on mine as well. I will look into it and hopefully have a fix posted soon. Please do not start from scratch as it's extremely likely that the error will still be there.

Re: Unexpected errors

PostPosted: Sun Jan 06, 2019 5:52 pm
by DaveL17
I have isolated the error (that bit was straight forward). The issue is that you're making an Action call to speak an announcement, but the plugin cannot find the announcement to speak. This could happen for several reasons, but I'd limit that list based on the experience you had.

For some reason, the plugin couldn't see or lost access to the announcements file which--up until the most recent update--was stored in the ~/Users/[useraccount] folder. The most recent update moves that file to the Indigo folder structure to be consistent with convention but to also ensure that it won't be lost if there are future upgrades to Indigo. Since you were seeing the error before you upgraded, I suspect it was the former.

Please look in your ~/User/[useraccount] folder to see if there is a folder called ../Announcements Plugin/ and a file called announcements.txt. If there is, I want you to copy it over to the following folder:

/Library/Application Support/Perceptive Automation/Indigo 7.2/Preferences/Plugins/

and rename the file:

com.fogbert.indigoplugin.announcements.txt

If there is not a file called announcements.txt in the useraccount folder or com.fogbert.indigoplugin.announcements.txt in the Indigo plugins preferences folder, you may be forced to recreate your announcements. I apologize for any trouble, but the bug described above wouldn't have caused the loss of the announcements--that's a symptom, not a cause.