• 1
  • 30
  • 31
  • 32(current)
  • 33
  • 34
  • 176
Release Kanzi: Amazon Alexa skill for Kodi
(2016-11-17, 21:47)jingai Wrote:
(2016-11-17, 04:26)BDPNA Wrote: If Alexa is 5 hours off on when my video will "end" when I ask her (and thanks to whomever added this feature, it ROCKS!!!)...How do I adjust the skill or app to make up for the 5 hour time difference? Where do I have this set wrong?

If you can (or anyone else, specifically those using AWS Lambda), would you mind testing this change on my branch here?

Please test with SKILL_TZ as empty, undefined, and whatever time zones you'd like to test.

With SKILL_TZ unset/empty, the expected behavior is to return the time the item will end in UTC. With it set to a valid time zone, it should tell you the time it will end for the given time zone. Ultimately this will be your local TZ, but feel free to play with it for testing purposes Smile

I can confirm this works as expected for leaving it blank (UTC end time given) and US/Eastern time. I did not test with other values. I tested this with AWS Lambda.
Reply
(2016-11-18, 20:25)jacobh Wrote: I can confirm this works as expected for leaving it blank (UTC end time given) and US/Eastern time. I did not test with other values. I tested this with AWS Lambda.

Would you mind testing also with the variable undefined (commented out/deleted)?
Reply
(2016-11-18, 20:36)jingai Wrote: Would you mind testing also with the variable undefined (commented out/deleted)?

Alexa politely informed me there was a problem with the requested skill Smile.

Here's the logs from AWS:

20:14:23 Requested intent: CurrentPlayItemTimeRemaining
20:14:23 Time left on currently playing item
20:14:23 Sending request to http://xxxxxxx:xxxx/jsonrpc
20:14:24 'None': UnknownTimeZoneError Traceback (most recent call last): File "/var/task/wsgi.py", line 1611, in lambda_handler return on_intent(event['request'], event['session']) File "/var/task/wsgi.py", line 1578, in on_intent return one_intent[1](intent_slots) File "/var/task/wsgi.py", line 222, in alexa_current_playitem_time_remaining loctime = utctime.astimezone(pytz.timezone(env('
20:14:24 END RequestId: 990c38f4-adcb-11e6-bb6b-09b01f31d23b
20:14:24 REPORT RequestId: 990c38f4-adcb-11e6-bb6b-09b01f31d23b Duration: 100.19 ms Billed Duration: 200 ms Memory Size: 128 MB Max Memory Used: 57 MB

This is with the SKILL_TZ commented out in the .env file. If it's not obvious, I modified my Kodi url for privacy reasons.
Reply
Thanks @jacobh.
Reply
@jacobh, just pushed what I think will fix it to the same branch. Mind pulling it and checking once more?
Reply
(2016-11-18, 22:32)jingai Wrote: @jacobh, just pushed what I think will fix it to the same branch. Mind pulling it and checking once more?

That gave back a UTC time which seems appropriate.
Reply
Yup, that's what it's supposed to do.

Thanks again!
Reply
Been trying to get this working for a few days now but I keep getting errors after errors LOL, If you guys could help me that would be great. i'm continuously getting this error

C:\Users\Kevin\Downloads\kodi-alexa-master>C:\Python27\Scripts\lambda-deploy.exe deploy
2016-11-18 20:43:15:INFO:botocore.credentials: Found credentials in environment variables.
2016-11-18 20:43:15:INFO:lambda_deploy: Packaging lambda kodi-alexa-master
2016-11-18 20:43:15:WARNING:lambda_deploy: A .env file exists in your Lambda directory - be careful that it does not contain any secrets you don't want uploaded to AWS!
2016-11-18 20:43:15:WARNING:lambda_deploy: Skipping inclusion of of .env file - use LAMBDA_ENV_VARS instead (see documentation for more information)
Collecting requests (from -r C:\Users\Kevin\Downloads\kodi-alexa-master\requirements.txt (line 1))
Using cached requests-2.12.1-py2.py3-none-any.whl
Collecting gunicorn (from -r C:\Users\Kevin\Downloads\kodi-alexa-master\requirements.txt (line 2))
Using cached gunicorn-19.6.0-py2.py3-none-any.whl
Collecting yaep (from -r C:\Users\Kevin\Downloads\kodi-alexa-master\requirements.txt (line 3))
Using cached yaep-0.0.6-py2-none-any.whl
Collecting pycountry (from -r C:\Users\Kevin\Downloads\kodi-alexa-master\requirements.txt (line 4))
Using cached pycountry-16.11.8.tar.gz
Collecting fuzzywuzzy (from -r C:\Users\Kevin\Downloads\kodi-alexa-master\requirements.txt (line 5))
Using cached fuzzywuzzy-0.14.0-py2.py3-none-any.whl
Installing collected packages: requests, gunicorn, yaep, pycountry, fuzzywuzzy
Running setup.py install for pycountry ... done
Successfully installed fuzzywuzzy gunicorn pycountry requests-2.12.1 yaep-0.0.6
You are using pip version 8.1.1, however version 9.0.1 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
Starting new HTTPS connection (1): lambda.us-east-1.amazonaws.com
Adding new kodi-alexa-master lambda
Traceback (most recent call last):
File "c:\python27\lib\runpy.py", line 174, in _run_module_as_main
"__main__", fname, loader, pkg_name)
File "c:\python27\lib\runpy.py", line 72, in _run_code
exec code in run_globals
File "C:\Python27\Scripts\lambda-deploy.exe\__main__.py", line 9, in <module>
File "c:\python27\lib\site-packages\lambda_deploy\lambda_deploy.py", line 376, in main
method()
File "c:\python27\lib\site-packages\lambda_deploy\lambda_deploy.py", line 215, in deploy
Publish=True
File "c:\python27\lib\site-packages\botocore\client.py", line 251, in _api_call
return self._make_api_call(operation_name, kwargs)
File "c:\python27\lib\site-packages\botocore\client.py", line 537, in _make_api_call
raise ClientError(parsed_response, operation_name)
botocore.exceptions.ClientError: An error occurred (InvalidParameterValueException) when calling the CreateFunction operation: The role defined for the function cannot be assumed by Lambda.

Thanks!
Reply
@KevinH21151 Double check that you've got the Role ARN name correct. The reason I say this is I had the same error and realised that somehow the role arn had somehow truncated the last few characters into the .env file.
Reply
(2016-11-18, 17:18)jingai Wrote:
(2016-11-18, 12:06)shukerr Wrote: Now, I have another little annoyance that I'd appreciate some guidance on. I'm a UK user, but not sure that's related.
If I haven't specifically listed a Movie, TV Show or Music in the Custom Slots Values then it simply will not find it.

For TV shows I either get the dull chime from the echo or a comment along the lines of "I can't find the answer you're looking for..."
For music it is trying to play it through Amazon Music & saying "I can't find an album by XYZ n your collection."
In the case of music the artist name is repeated back correctly so Alexa has definitely understood correctly.

Everything I've entered into the custom slot values works perfectly.
I don't mind populating the custom slot values, but my impression was that it should still have a reasonable chance of working regardless.

You definitely don't have to enter them into the slots, except for the DoSearch intent "Alexa, tell Kodi to search for ...". I'll be fixing that soon, but for other commands they use fuzzy matching that should get you the right answer most of the time.

List off some specific commands you're trying to issue. It's possible we simply haven't thought of those phrases.

And what do your server logs say when it doesn't match?

(2016-11-18, 12:06)shukerr Wrote: Lastly, this app to populate the values mentioned earlier in the forum is now offline. https://sleepy-wave-26412.herokuapp.com/

@m0ngr31 hosts that, so I can't say why it's not online.

@jingai
So, I've been doing some more testing in the UK & I think I know what's going on with these custom slot values.
I checked the utterances file to ensure I was only using correct phrases. e.g. "Alexa, ask media centre to listen to music by Dolly Parton"
Still only entities specifically within the custom slot values will work.
I checked the Heroku logs and nothing was being passed to Heroku when the custom slot value did not exist.
I've changed over to AWS Lamda and it's the same. The requests are only passed to Lamda when the specific artist/album etc is present in the custom slot value.
No card is created, but I can see in the history that the request was heard perfectly.

My Alexa account also includes Amazon Music, Spotify & TuneIn Radio. Amazon Music is set as the default service for both music and stations
It's looking fairly likely that Alexa is ignoring the invocation name and passing the request to the default service.

From one of your earlier posts I've just changed the invocation name from "media centre" to "raspberry pi" and am getting some results for media not contained in the custom slot values.
There's a fair few still being routed to the Amazon Music service, but changing the invocation name has definitely made a big difference.

I don't know if it's possible to present a skill as a "music service" as it could then be set as the default.
It's pretty annoying for Alexa to ignore the invocation name and then feed the request to it's own app.
Reply
(2016-11-20, 14:44)shukerr Wrote: My Alexa account also includes Amazon Music, Spotify & TuneIn Radio. Amazon Music is set as the default service for both music and stations
It's looking fairly likely that Alexa is ignoring the invocation name and passing the request to the default service.

From one of your earlier posts I've just changed the invocation name from "media centre" to "raspberry pi" and am getting some results for media not contained in the custom slot values.
There's a fair few still being routed to the Amazon Music service, but changing the invocation name has definitely made a big difference.

I don't know if it's possible to present a skill as a "music service" as it could then be set as the default.
It's pretty annoying for Alexa to ignore the invocation name and then feed the request to it's own app.

Unfortunately, Amazon plays with this all the time it seems, and there's nothing to tell us what they're doing.

I do agree that if we say, "Alexa, ask <skill>" it should be routed to the skill no matter what.. but that's kind of out of our control.

I intend to play with making the skill support the audio player interface. I just haven't yet had time to dive into it.

In the meantime, I've personally found that clicking the "you did the right thing" on the cards where she actually did seems to help. At the moment, she's routing everything correctly to the skill for me, after having clicked a ton of those. Might be placebo, but I suppose it's worth a shot.

Otherwise, outside of making sure the skill itself is behaving correctly, there's not much I can do if she simply flat-out decides not to send the command to the skill Sad
Reply
(2016-11-20, 13:19)shukerr Wrote: @KevinH21151 Double check that you've got the Role ARN name correct. The reason I say this is I had the same error and realised that somehow the role arn had somehow truncated the last few characters into the .env file.

Thanks, now on to the next step! This is actually becoming fun for me haha. Thanks again, have a good night!
Reply
I have encountered another problem and may need some help with this. Sad Once I completed the process, I gave it a test sayiing (Alexa, ask media center to play season 1 episode 1 of Westworld), but it gives a blue light that doesn't go away for a few minutes.

Unexpected Communication Issue
Kodi
Request Identifier: amzn1.echo-api.request.d9e20dbe-03e0-4288-b4a5-14e7085235ef
There was a problem communicating with the requested skill

I also get that in the app
Reply
(2016-11-22, 05:29)KevinH21151 Wrote: I have encountered another problem and may need some help with this. Sad Once I completed the process, I gave it a test sayiing (Alexa, ask media center to play season 1 episode 1 of Westworld), but it gives a blue light that doesn't go away for a few minutes.

Unexpected Communication Issue
Kodi
Request Identifier: amzn1.echo-api.request.d9e20dbe-03e0-4288-b4a5-14e7085235ef
There was a problem communicating with the requested skill

I also get that in the app

Probably was just an outage, but if it's still happening, you'll need to look at your server log.
Reply
(2016-11-22, 14:49)jingai Wrote:
(2016-11-22, 05:29)KevinH21151 Wrote: I have encountered another problem and may need some help with this. Sad Once I completed the process, I gave it a test sayiing (Alexa, ask media center to play season 1 episode 1 of Westworld), but it gives a blue light that doesn't go away for a few minutes.

Unexpected Communication Issue
Kodi
Request Identifier: amzn1.echo-api.request.d9e20dbe-03e0-4288-b4a5-14e7085235ef
There was a problem communicating with the requested skill

I also get that in the app

Probably was just an outage, but if it's still happening, you'll need to look at your server log.

Still happening, not sure what the problem is. Where can I check for the server log?
Reply
  • 1
  • 30
  • 31
  • 32(current)
  • 33
  • 34
  • 176

Logout Mark Read Team Forum Stats Members Help
Kanzi: Amazon Alexa skill for Kodi15