Kodi Community Forum
Release Kanzi: Amazon Alexa skill for Kodi - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Supplementary Tools for Kodi (https://forum.kodi.tv/forumdisplay.php?fid=116)
+--- Thread: Release Kanzi: Amazon Alexa skill for Kodi (/showthread.php?tid=254502)



RE: Amazon Echo skill for Kodi - jingai - 2017-08-10

New release -- changes:

v2.8.0 (08/09/2017)
  • Add ability to play a random TV show.
  • Add ability to play a random music video.
  • Add ability to specify genre when opening library views.
  • Add ability to open (show on-screen) recently added items.
  • Add ability to open (show on-screen) library views.
  • Fix play of recommended music video.

As usual, see UPGRADING.md if you're upgrading from a previous version. Of particular note is two new Slots you must generate.


RE: Amazon Echo skill for Kodi - 8osman - 2017-08-11

(2017-08-08, 14:45)2manyhobbies Wrote:
Quote:Thanks for the help, however when I click into the cloudwatch managment console and select logs there is no "lambda function to select". I get a welcome page with a quickstart guide, (definitely no links to a lambda function on the page). It makes no sense compared to the comments I see here?

I wonder if I've got some basic settings wrong with the aws setup, however as far as I can see it all setup perfectly in accordance with the github instructions.

Under your AWS Console, Click services at the top left, under Management tools click on cloudwatch. Click LOGS on the left side of your screen. Now it should show your log groups with you kodi-alexa app. If you don't see it, I would re-do the AWS part of the process.

Eventually found the logs, the issue is that in the GITHUB instructions it says to use eu-west1 for location when based in europe. However if you are in the uk it uses eu-west2.

Now that I've worked out I have to login to Ireland location it works.....might be worth putting a note in the instructions to make sure that the console server in the address bar is the same as selected when installing the aws service access within python. Sounds obvious but isn't unless you know to look for it.

Thanks, for your help, now I can access the logs properly I can start to piece together why it's not working.


RE: Amazon Echo skill for Kodi - steve55792 - 2017-08-12

I was wondering, I got the alexa and kodi, I think, but when i tried asking alexa to ask kodi to play a movie, alexa responded with: there was a problem with requested skills response. What can i do to fix it?
Thank you
steve


RE: Amazon Echo skill for Kodi - jingai - 2017-08-12

@steve55792, assuming you're hosting the skill on AWS, the first thing you need to do is check the logs on cloudwatch as described in this post and do the following at the command prompt on your computer in the directory where you cloned the repository:

Code:
zappa tail dev

There should be something in those logs indicating what the problem is.


RE: Amazon Echo skill for Kodi - foreveradevil - 2017-08-12

Apologies in advance if that has been answered, if so can someone please point me to the thread number to read.

I have kodi on a windows 10 pc and want to use this to integrate Alexa...i have looked at the instructions on the git and created the user in AWS console...then it goes on to use commands to install various bits that are not for windows, they appear to be linux based commands....can anyone help?

Whats the best way to get alexa controlling kodi on windows 10 pc?

sorry again if i am just being a noob

rob


RE: Amazon Echo skill for Kodi - jingai - 2017-08-12

@foreveradevil, you execute them from a command prompt (command.com/cmd.exe/whatever-it-is-now-in-windows).


RE: Amazon Echo skill for Kodi - shyyour - 2017-08-12

Please i need some help.

I followed the official documentation using heroku and i get the error message "there was a problem with the requested skills response" when i ask alexa to ask "media center" to play a rasndom move.

I copied the logs from the heroku app server below. Please can someone help me

Thanks

2017-08-12T19:11:50.796579+00:00 app[web.1]: Welcome to Kodi.
2017-08-12T19:12:00.773263+00:00 app[web.1]: Sending request to http://jsonrpc from device amzn1.ask.device.AG4HLWOPENKDUMIPSSB7Z6BPQS4MNYAV5SIIPVBPDKHCEX6ENWHSJVBQKV5UV4EKIH6ENLLGDPRJMP752LPTN56MVADF4EROHK6LOHATLLWQ5CZUPLSNWKZNJHJQFCTJHM5TA7FPXXCLY626ANP65QLGFNQA
2017-08-12T19:12:00.793609+00:00 app[web.1]: [2017-08-12 19:12:00,792] ERROR in app: Exception on / [POST]
2017-08-12T19:12:00.793611+00:00 app[web.1]: Traceback (most recent call last):
2017-08-12T19:12:00.793612+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site-packages/flask/app.py", line 1982, in wsgi_app
2017-08-12T19:12:00.793613+00:00 app[web.1]: response = self.full_dispatch_request()
2017-08-12T19:12:00.793614+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site-packages/flask/app.py", line 1614, in full_dispatch_request
2017-08-12T19:12:00.793614+00:00 app[web.1]: rv = self.handle_user_exception(e)
2017-08-12T19:12:00.793615+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site-packages/flask/app.py", line 1517, in handle_user_exception
2017-08-12T19:12:00.793615+00:00 app[web.1]: reraise(exc_type, exc_value, tb)
2017-08-12T19:12:00.793616+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site-packages/flask/app.py", line 1612, in full_dispatch_request
2017-08-12T19:12:00.793616+00:00 app[web.1]: rv = self.dispatch_request()
2017-08-12T19:12:00.793617+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site-packages/flask/app.py", line 1598, in dispatch_request
2017-08-12T19:12:00.793617+00:00 app[web.1]: return self.view_functions[rule.endpoint](**req.view_args)
2017-08-12T19:12:00.793618+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site-packages/flask_ask/core.py", line 629, in _flask_view_func
2017-08-12T19:12:00.793619+00:00 app[web.1]: result = self._map_intent_to_view_func(self.request.intent)()
2017-08-12T19:12:00.793619+00:00 app[web.1]: File "/app/alexa.py", line 2539, in alexa_what_new_movies
2017-08-12T19:12:00.793619+00:00 app[web.1]: new_movies = kodi.GetUnwatchedMovies()
2017-08-12T19:12:00.793620+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site-packages/kodi_voice/kodi.py", line 1344, in GetUnwatchedMovies
2017-08-12T19:12:00.793621+00:00 app[web.1]: data = self.SendCommand(RPCString("VideoLibrary.GetMovies", {"limits":{"end"Confusedelf.max_unwatched_movies}, "filter":{"field":"playcount", "operator":"lessthan", "value":"1"}, "sort":{"method":"dateadded", "order":"descending"}, "properties":["title", "playcount", "dateadded"]}))
2017-08-12T19:12:00.793622+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site-packages/kodi_voice/kodi.py", line 313, in SendCommand
2017-08-12T19:12:00.793622+00:00 app[web.1]: r = requests.post(url, data=command, auth=(self.username, self.password), timeout=timeout)
2017-08-12T19:12:00.793623+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site-packages/requests/api.py", line 112, in post
2017-08-12T19:12:00.793623+00:00 app[web.1]: return request('post', url, data=data, json=json, **kwargs)
2017-08-12T19:12:00.793624+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site-packages/requests/api.py", line 58, in request
2017-08-12T19:12:00.793624+00:00 app[web.1]: return session.request(method=method, url=url, **kwargs)
2017-08-12T19:12:00.793625+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site-packages/requests/sessions.py", line 508, in request
2017-08-12T19:12:00.793625+00:00 app[web.1]: resp = self.send(prep, **send_kwargs)
2017-08-12T19:12:00.793626+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site-packages/requests/sessions.py", line 618, in send
2017-08-12T19:12:00.793626+00:00 app[web.1]: r = adapter.send(request, **kwargs)
2017-08-12T19:12:00.793626+00:00 app[web.1]: File "/app/.heroku/python/lib/python2.7/site-packages/requests/adapters.py", line 508, in send
2017-08-12T19:12:00.793627+00:00 app[web.1]: raise ConnectionError(e, request=request)
2017-08-12T19:12:00.793628+00:00 app[web.1]: ConnectionError: HTTPConnectionPool(host='http', port=80): Max retries exceeded with url: //jsonrpc (Caused by NewConnectionError('<urllib3.connection.HTTPConnection object at 0x7fc46d11a050>: Failed to establish a new connection: [Errno -2] Name or service not known',))
2017-08-12T19:12:00.798838+00:00 heroku[router]: at=info method=POST path="/" host=shyyour.herokuapp.com request_id=8040b1b5-265a-4ec7-8aea-4d1fb1798817 fwd="72.21.217.176" dyno=web.1 connect=1ms service=50ms status=500 bytes=456 protocol=https
2017-08-12T19:12:00.970256+00:00 heroku[router]: at=info method=POST path="/" host=shyyour.herokuapp.com request_id=87da8bf5-1af7-4e8c-98b8-fbb53b8d3449 fwd="72.21.217.176" dyno=web.1 connect=0ms service=26ms status=200 bytes=161 protocol=https


RE: Amazon Echo skill for Kodi - jingai - 2017-08-12

Specify the url in kodi.config without slashes or HTTP


RE: Amazon Echo skill for Kodi - shyyour - 2017-08-12

(2017-08-12, 21:31)jingai Wrote: Specify the url in kodi.config without slashes or HTTP

I dont have a kodi.config file, or rarther dont know where it is.


RE: Amazon Echo skill for Kodi - steve55792 - 2017-08-12

i can not get zappa tail dev bcause in the command prompt it says: it's not recognized as a internal external command operable program or batch file.


RE: Amazon Echo skill for Kodi - shyyour - 2017-08-12

Im using heroku


RE: Amazon Echo skill for Kodi - steve55792 - 2017-08-12

would that work with alexa issues: there was a problem with requested skills response.


RE: Amazon Echo skill for Kodi - jingai - 2017-08-12

(2017-08-12, 23:02)shyyour Wrote:
(2017-08-12, 21:31)jingai Wrote: Specify the url in kodi.config without slashes or HTTP

I dont have a kodi.config file, or rarther dont know where it is.

The description for the KODI_ADDRESS field in the Heroku setup is wrong -- it's supposed to be an address, i.e., a fully-qualified domain name or IP address, like myhost.dyndns.org or 229.101.84.5.

In other words, not a URL, and it should not contain any slashes or anything either.

I've fixed the description of the field upstream.


RE: Amazon Echo skill for Kodi - jingai - 2017-08-12

(2017-08-12, 23:06)steve55792 Wrote: i can not get zappa tail dev bcause in the command prompt it says: it's not recognized as a internal external command operable program or batch file.

How did you deploy via zappa if the command doesn't exist...? Are you using AWS? Or Heroku?


RE: Amazon Echo skill for Kodi - steve55792 - 2017-08-12

I'm using AWS