[RELEASE] Alexa Helper

Upon commenting out line 91 and saving I get this error:

forgotā€¦need to do 92, 93 and 94

86,87,90-94 are all commented out and I still get the unexpected error.

Okā€¦I am going to look at this in the morningā€¦will try to give you more troubleshooting in the morningā€¦in the mean time, try to keep what you have an comment out 82,83 and 85ā€¦

Thanks for the help and goodnight.

That got this result:

Caught me before I went to bedā€¦I bet if you uncomment all the lines except 82, 83, and 85 it will work. After that, try to uncomment everything but 83.

If that works, then that is indicative either you donā€™t have any phrases set up (routines), or there is an issue with your account and SmartThings routinesā€¦maybe you have some routine named strangely (commas, periods, etc.)?

Sorry I missed your post. It looks like it is in line 85.

So everything is uncommented but 85? If you remove the comments and then remove the ā€˜If(phrases)ā€™ and just leave the rest of the line does it still fail?

That would indicate you have something strange with your routinesā€¦can you list them out (or screen shot)? Anything with punctuation or non-characters may be suspectā€¦I would be interested if that is the issue as that is something I can document.

I am now going to bedā€¦I will check this in the morningā€¦

I had already tried your suggestion for line 85 and it still fails. I think this is the list you are asking for:

Goodnight!

So I threw in a trace and this is what I got for my Phrases in the log:

[null, Going To Bed, Good Morning!, Good Night!, Goodbye!, Iā€™m Back!, Kids Awake, Kids Going To Bed, Nightstands Off, Nightstands On, Weekday Outside Off, Weekend Outside Off, Weekly Outside On]

I used the IDE to remove the null SmartApp and everything is now working great. Thanks for all your help tonight. Please let me know how to donate.

Interestingā€¦so a Null phrase will kill the appā€¦I will put that in the documentation and try to program around it.

Glad we were able to figure this out!

My PayPal address is: https://www.paypal.me/mstruck

Thanks for being patient in troubleshooting this!

Edit
I put some notes in the documentation about thisā€¦

Just got my thermostat working with ST. I then paired it with my Alexa. I was just reading thru the documentation for Alexa Helper working with the thermostat. Question, do I need to ā€œunpairā€ the thermostat with Alexa before I start setting up the scenario?
Thanks

Do you need the extra functions that Alexa Helper gives like changing modes or the temperature range protection? If not you can keep it paired. But to be clear, Alexa Helper and the native integration are not mutually exclusive. They work independently.

Does that make sense?

1 Like

Hey, great work on this @MichaelS

Iā€™m no noob and Iā€™ve installed the Alexa Helper and Alexa Helper scenario. However, Iā€™m getting the ā€œunexpected errorā€ as well. Iā€™ve tried on my Android Galaxy S7 as well as my chickā€™s iPhone 7.

Iā€™ve ripped out the code and reinstalled it from GitHub to no avail.

Is there a fix for this right now?

Did it work before and just stopped working today or is this a new installation? And, when are you getting there error? On the creation of the scenario or when you first start the app? Do you see any red entries in the IDE Live Logging?

Let me know and we can narrow down the issue.

This is a new installation. I can create the scenario and select ā€œscenario typeā€ (Modes/routines/devices) but I get the error when I try to select ā€œcontrol Scenario Settingsā€. Here are the live logs when I click on control scenario settings:

697784e9-caf3-4a44-80e1-1db8d64c6e6f 1:50:50 AM: trace getPhrases(), state.welcomeIssue = null
697784e9-caf3-4a44-80e1-1db8d64c6e6f 1:50:50 AM: trace getPhrases(), state.welcomeIssue = null
dc6cd498-f114-4b30-8f8e-22f5743ef7b4 1:50:42 AM: debug getChildDevices(false), children=0
dc6cd498-f114-4b30-8f8e-22f5743ef7b4 1:50:42 AM: debug getChildDevices(false), children=0
dc6cd498-f114-4b30-8f8e-22f5743ef7b4 1:50:42 AM: debug getChildDevices(false), children=0
dc6cd498-f114-4b30-8f8e-22f5743ef7b4 1:50:41 AM: debug getChildDevices(false), children=0
dc6cd498-f114-4b30-8f8e-22f5743ef7b4 1:50:41 AM: debug getChildDevices(false), children=0
dc6cd498-f114-4b30-8f8e-22f5743ef7b4 1:50:41 AM: debug getChildDevices(false), children=0
697784e9-caf3-4a44-80e1-1db8d64c6e6f 1:50:33 AM: trace getPhrases(), state.welcomeIssue = null
697784e9-caf3-4a44-80e1-1db8d64c6e6f 1:50:33 AM: trace getPhrases(), state.welcomeIssue = null

Does this happen when you first attempt to create the scenario or after you press done? Also, a real screenshot of the live logging will help; however, here is the first thing I am betting is wrongā€¦look up on one of the previous posting (around 627). You may have a phrase (routine that is blank)ā€¦To test this theory remark out (//) lines 83, 84 and 86 on the scenario code and save (but DONā€™T publish) the code. If the app works, do what he did and go into the IDE and see if you have some blank (null) routines in your profile.

@MichaelS I was having the same problem as well. In the IDE I found a Routine called ā€œPhraseā€ with Null properties. Deleting that fixed it for me & I was able to complete a scenario to change a mode using a virtual switch.

Bad news is that before trying that, I deleted something in the other category called Rule (dev) . It was the same hierarchy as the other Smart Apps with nothing under it. Not sure what impact that will have on anything if at all.