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) Pages:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
|
Amazon Echo skill for Kodi - jouster - 2016-12-12 (2016-12-12, 22:25)jingai Wrote:(2016-12-12, 22:12)jouster Wrote: You say you host it yourself. Do you find this easier? What do you use or recommend for this. I'll have a dig. Thanks Sent from my iPhone RE: Amazon Echo skill for Kodi - Taskmaster - 2016-12-13 I had this working and I changed which Kodi installation I was using and I was updating the Custom Slots on the Echo dev console and something went wrong. The only command that works now through the test interface seems to be "go home" Below is the output when I try "play latest episode Modern Family". I'm hosting myself on a Docker container and I've rebuilt that too, but still having the same trouble. SERVICE REQUEST { "session": { "sessionId": "SessionId.XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX", "application": { "applicationId": "amzn1.ask.skill.XXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX" }, "attributes": {}, "user": { "userId": "amzn1.ask.account.XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX" }, "new": true }, "request": { "type": "IntentRequest", "requestId": "EdwRequestId.XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX", "locale": "en-US", "timestamp": "2016-12-13T05:13:23Z", "intent": { "name": "PlayLatestEpisode", "slots": { "Show": { "name": "Show", "value": "Modern Family" } } } }, "version": "1.0" } SERVICE RESPONSE { "version": "1.0", "response": { "outputSpeech": { "type": "PlainText", "text": "You can ask me whether there are any new shows, to play a movie, tv show, or artist, or control playback of media." }, "card": { "content": "You can ask me whether there are any new shows, to play a movie, tv show, or artist, or control playback of media.", "title": "Help", "type": "Simple" }, "shouldEndSession": true }, "sessionAttributes": {} } I appreciate it if anyone has input what I'm missing? EDIT - My fault (kinda knew that), did a pull but didn't update intents... All set now RE: Amazon Echo skill for Kodi - jouster - 2016-12-13 (2016-12-12, 22:12)jouster Wrote:(2016-12-12, 22:07)jingai Wrote:(2016-12-12, 21:59)jouster Wrote: You say you don't personally use AWS. I am. Now wondering what you personally use. ok so after some very helpful input from @jingai I have managed to have a look at my logs...I have attached a screen grab which I have posted below (hope this is ok) It does indeed point to an error as you can see, an "Application ID verification fail" error Application ID verification failed: ValueError Traceback (most recent call last): File "/var/task/wsgi.py", line 1813, in lambda_handler verify_application_id(appid) File "/var/task/wsgi.py", line 1799, in verify_application_id raise ValueError("Application ID verification failed") ValueError: Application ID verification failed Whilst this doesn't let me fix things on my own, it does explain why nothing is currently working. I know @jingai doesn't personally use Lambda but is anyone else aware what might be going wrong here RE: Amazon Echo skill for Kodi - jingai - 2016-12-13 (2016-12-13, 13:03)jouster Wrote: Application ID verification failed: ValueError You have application ID verification enabled in your .env file but the value in SKILL_APPID doesn't match your application ID. Look at dev console in the same place as the first screenshot in this section of the README. The top part there shows your application ID. You need to copy that into the SKILL_APPID environment variable in .env and re-deploy to Lambda. If you still have trouble connecting to it, check your logs again and see what it's saying. Amazon Echo skill for Kodi - jouster - 2016-12-13 Thanks. Will give that a try Sent from my iPhone RE: Amazon Echo skill for Kodi - Newu_boy - 2016-12-13 Make sure you type your address for kodi in the env file without http:\\ KODI_ADDRESS = mykodiservice.com RE: Amazon Echo skill for Kodi - Newu_boy - 2016-12-13 You might also find you are better off stripping all configuration from AWS and starting from scratch that it might help tidying everything up. also check logs in aws cloudwatch this can also help point where the setup is wrong at the moment. RE: Amazon Echo skill for Kodi - jouster - 2016-12-13 ok so started from screatch and entered the SkillID I added this line into my env file SKILL_APPID = amzn1.ask.skill.*******-052e-4606-b726-4aa2d94108df and removed SKILL_APPID from the end of this line so this is now how the line looks in my ENV file LAMBDA_ENV_VARS = LAMBDA_ENV_VARS = KODI_ADDRESS,KODI_PORT,KODI_USERNAME,KODI_PASSWORD now I've run the test again and i STILL get the end point issue BUT I'm now getting a different error in my log the report is shown below 14:22:26 /var/task/fuzzywuzzy/fuzz.py:35: UserWarning: Using slow pure-python SequenceMatcher. Install python-Levenshtein to remove this warning 14:22:26 warnings.warn('Using slow pure-python SequenceMatcher. Install python-Levenshtein to remove this warning') Can anyone make any suggestions as to what my next step would be RE: Amazon Echo skill for Kodi - jouster - 2016-12-13 so now when I test I'm getting some different results...none of which are working correctly though some test now work but never return the desired result and still half the time the rest either state they are unable to generate request for your skill and therefore have no service response One that does seem to generate a service request is "to play the dark knight" but in the service response box I see "version": "1.0", "response": { "outputSpeech": { "type": "PlainText", "text": "Error parsing results" }, "card": { "content": "Error parsing results", "title": "Playing the movie dark knight", "type": "Simple" }, "shouldEndSession": true Trying to get this to work on my Echo Dot at all just results in a single low tone I've noticed in the logs pretty much every request goes back to the same few lines of code in wsgi.py and generates the following code....this was generated when asking KODI to play a random movie 'result': KeyError Traceback (most recent call last): File "/var/task/wsgi.py", line 1821, in lambda_handler return on_intent(event['request'], event['session']) File "/var/task/wsgi.py", line 1788, in on_intent return one_intent[1](intent_slots) File "/var/task/wsgi.py", line 1257, in alexa_watch_random_movie movies_array = kodi.GetUnwatchedMovies() File "/var/task/kodi.py", line 804, in GetUnwatchedMovies for d in data['result']['movies']: KeyError: 'result' Im definitely making progress but im really not sure how much RE: Amazon Echo skill for Kodi - jingai - 2016-12-13 (2016-12-13, 16:26)jouster Wrote: and removed SKILL_APPID from the end of this line so this is now how the line looks in my ENV file What prompted you to remove it from LAMBDA_ENV_VARS? This will bypass the verification of the appid in the skill. I mean, it will work.. I just don't know why you populated SKILL_APPID and then removed it from LAMBDA_ENV_VARS? (2016-12-13, 16:26)jouster Wrote: 14:22:26 /var/task/fuzzywuzzy/fuzz.py:35: UserWarning: Using slow pure-python SequenceMatcher. Install python-Levenshtein to remove this warning This is not an error. It's a warning, as it says. With Lambda deployments you can't install python-Levenshtein, so it's safe for you to simply ignore it. (2016-12-13, 16:26)jouster Wrote: 'result': KeyError The skill is unable to retrieve a list of movies from your Kodi library. This is due to not being able to establish a connection.. or incorrect username, incorrect password, wrong port number, etc. Please don't truncate your logs. Do block out personal info, but I need to see it in its entirety if I am to help you. RE: Amazon Echo skill for Kodi - jingai - 2016-12-13 Also, is the following how it actually appears in your .env file? Code: LAMBDA_ENV_VARS = LAMBDA_ENV_VARS = KODI_ADDRESS,KODI_PORT,KODI_USERNAME,KODI_PASSWORD Notice the duplicate "LAMBDA_ENV_VARS = ". Amazon Echo skill for Kodi - jouster - 2016-12-13 Yes I've pulled that right from the file. I'll reinstate the skill section now and also remove that strangely unwanted section too. Access wise I'm a little confused still as I can access the remote screen via a machine from outside the house and on any machine from within. Sent from my iPhone RE: Amazon Echo skill for Kodi - jingai - 2016-12-13 (2016-12-13, 17:49)jouster Wrote: Yes I've pulled that right from the file. Heed the text in this section please: Code: You do not need to change the options that already have values. You shouldn't be touching LAMBDA_ENV_VARS at all. (2016-12-13, 17:49)jouster Wrote: Access wise I'm a little confused still as I can access the remote screen via a machine from outside the house and on any machine from within. You being able to access it and the skill being able to access it are two entirely different things. You've got something wrong in your .env file. The error I pointed out above would prevent it from talking to Kodi, for instance. Amazon Echo skill for Kodi - jouster - 2016-12-13 (2016-12-13, 17:53)jingai Wrote:(2016-12-13, 17:49)jouster Wrote: Yes I've pulled that right from the file. Going to start from scratch my env file Thanks for the pointers. Sent from my iPhone Amazon Echo skill for Kodi - jouster - 2016-12-13 Well starting with a fresh env file made all of the difference. It's now working but I'm finding things quite slow depending exactly what I've asked for. It might not help that I have a huge library consisting of 60 TB of data so that might not help. But a massive thanks for help so far @jingai in particular for persevering with me Really appreciate it. Using a hosting method. Is there a way to speed things up? Sent from my iPhone |