Problem after upgrade
#1
I just upgraded to the latest stable build. After I upgraded a Python script I was running no longer works,

f = urllib.urlopen('http://192.168.1.83/jsonrpc?request={"jsonrpc":"2.0","method":"Player.GetProperties","params":{"playerid":0,"properties":["speed","percentage","totaltime","time"]},"id":1}')
result = f.read()

I do not get any returned data now.

Is this a know issue or did some thing change?
Reply
#2
Was able to confirm, works fine on 14 but not on 15
Reply
#3
let me move it to JSON section
Read/follow the forum rules.
For troubleshooting and bug reporting, read this first
Interested in seeing some YouTube videos about Kodi? Go here and subscribe
Reply
#4
Bump, has any one looked into fixing this?
Reply
#5
Did you try URL encoding the JSON-RPC request i.e. the value of the "request" GET parameter?
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not e-mail Team Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#6
Sorry, but I don't know what your asking. I am doing this Python and not sure if this is the best way to do it.

FYI, I am not a developer, I am just writing a small Python script that I run in EventGhost to send playing info to iRule.
Reply
#7
bump
Reply
#8
Try https://docs.python.org/2/library/urllib....urlencode to encode the JSON-RPC request part of your URL i.e.
Code:
{"jsonrpc":"2.0","method":"Player.GetProperties","params":{"playerid":0,"properties":["speed","percentage","totaltime","time"]}
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not e-mail Team Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#9
(2015-10-08, 21:34)[email protected] Wrote: FYI, I am not a developer, I am just writing a small Python script that I run in EventGhost to send playing info to iRule.
As you are using EventGhost have you tried my XBMC2 plugin? (It's included in EG) it supports sending JSON-RPC to Kodi/XBMC should make it a bit easier.

jonib
XBMC2, EventGhost plugin. Image
Reply
#10
(2015-10-18, 02:09)jonib Wrote:
(2015-10-08, 21:34)[email protected] Wrote: FYI, I am not a developer, I am just writing a small Python script that I run in EventGhost to send playing info to iRule.
As you are using EventGhost have you tried my XBMC2 plugin? (It's included in EG) it supports sending JSON-RPC to Kodi/XBMC should make it a bit easier.

jonib
I played around with your plugin, and yes I am able to control KODI, but your comand to retrieve info comes back with errors,

XBMC2: GetCurrentlyPlayingFilename
Error in Action: "XBMC2: GetCurrentlyPlayingFilename"
Traceback (most recent call last) (1700):
File "C:\Program Files (x86)\EventGhost\eg\Classes\ActionBase.py", line 170, in CallWrapper
return self(*args)
File "C:\Program Files (x86)\EventGhost\plugins\XBMCRepeat\__init__.py", line 796, in __call__
if (responce['result']['picture']): Method = 'Picture'
TypeError: list indices must be integers, not str

[/color]
Reply
#11
(2015-10-20, 05:10)[email protected] Wrote: I played around with your plugin, and yes I am able to control KODI, but your comand to retrieve info comes back with errors,
That commands been broken for a long time I need to fix it or remove it next release.
You need to use the "XBMC2\Experimental\JSONRPC" command to retrieve information from Kodi.

jonib
XBMC2, EventGhost plugin. Image
Reply

Logout Mark Read Team Forum Stats Members Help
Problem after upgrade0