• 1
  • 222
  • 223
  • 224
  • 225
  • 226(current)
JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC
(2017-01-07, 10:06)joethefox Wrote: So, can someone explain me when the issues occurHuh

It's because the problem only happens when trying to play multiple songs from a plugin and not from a smartplaylist. With smartplaylists (which the original report a few posts ago mentioned) everything is fine but when trying to add songs from a plugin directory they are returned in a random order and Kodi doesn't know which sorting method to use to sort them appropriately so they are added in a seemingly random order.
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
The issue also occurs with XSP....

Code:
{"jsonrpc":"2.0","method":"Playlist.Add","id":-2067158130,"params":{"playlistid":0,"item":{"directory":"special://profile/playlists/music/Long Tracks.xsp"}}}

{"jsonrpc":"2.0","method":"Player.Open","id":1877953368,"params":{"options":{"shuffled":true},"item":{"playlistid":0,"position":0}}}

You are forcing the shuffled option, of course in that case it works, but you forget the main point of XSP files, they have this setting inside them, an XSP can be shuffled or not, and there's no way to get this param inside the XSP from JSON.

So normally when you play an XSP file it should be ordered in the XSP defined order, specially since you have no way to know what the user configured in it's XSP file to reproduce it.

You can reproduce also with an m3u, create an m3u file with tracks that are not in alphabetical order (Because yes 95% of users have track number first in m3u so the order by luck does match) and see that the tracks are not added in the order of the m3u but in the alphabetical order.

And party mode is a special thing completely different also as it does not use the xsp random param and only load 10 songs at a time in the manageable playlist and reorder after each play meaning a complete different target than playing 2 albums in random order.

So yes iOS users have this issue and some others, they just do not report or explain the issue, but since I do provide some advanced support in a lot of ways I do have a lot more user contact and logs and details than some other remote makers Wink

Anyway I only answer because Yatse was said to have the issue when it's not, I no more really care about Kodi fixing or not, I send users here Wink But I was proven right each time there was argument over JSON not sure some want to try me again Wink (With all due respect of course).

Edit for @Montellese, the issue is that by default Kodi should not add a sort order when expanding playlist / directories as the provider already give the data in the wanted order. (There also a bug on linux with directories on usb drive that add files in reverse order for unknown reason but hard to reproduce so never really reported this one). If you think it should (I don't) then maybe the simplest solution would be to add a param to disable that. But logic says opposite, by default use the provider sort and optionally allow the caller to force a sort.

And edit for @ncarthy (But for @Montellese too as already asked) The problem about JSON api is that we can't pass metadata when adding things to playlist. Or there would be some other workarounds possible (See a Team member requesting that here : http://forum.kodi.tv/showthread.php?tid=300522)
Reply
There is a XSP. Player.Open: Shuffle options true -> then it's shuffled, Shuffle options false -> then it's not shuffled. Don't rely on kodi but offer the option to the users to choose. Simple. Or I'm missing something else?
Reply
(2017-01-07, 14:16)joethefox Wrote: There is a XSP. Player.Open: Shuffle options true -> then it's shuffled, Shuffle options false -> then it's not shuffled. Don't rely on kodi but offer the option to the users to choose. Simple. Or I'm missing something else?

You miss the fact that you are adding an unnecessary step on the remote to ask something that the user have already configured ?
You miss the fact that your solution does not work for m3u as shuffled or not there's no way to get the playlist in the order the user wanted ?

We can talk about our previous endless discussion about JSON versioning if you want. The fact that you think something does not change facts Wink

I know when there's my name some want to argue indefinitely to try to prove I'm wrong, but well I'm still waiting for that last part Wink

I'll now stop to discuss as I'm loosing my time, I've proven my point, you can debate about all possible hacky horrible workaround you can imagine. (One being list the content of the directory with sort none and add each song 1 by 1 to the playlist, but for a large directory this is ugly slow and for addons we can't add meta data).
Reply
sorry I didn't mean to upset you
Reply
I can confirm what Tolriq has said. In my remote control application m3u playlists are also queued in the wrong order when using Playlist.Add

Code:
"{"id":1,"jsonrpc":"2.0","method":"Playlist.Add","params":{"item":{"directory":"special://profile/playlists/music/test.m3u","recursive":true},"playlistid":0}}"
Reply
Hi
Ok, let me try again. About the PVR requests :
1 - There is a way to request and get all Broadcasts from all channels at once ? or i will have to request each channel individually ?
2 - Every time that i need to refresh the EPG i will have to request everything again or i can use a filter to tell, for exemple, that i only want Broadcasts with the "starttime" above some date ?
Regards
Reply
Hi,
How can i get images from Kodi if the login has a password with special characters ? I tried to escape the password, but this seems to not work. If i remove the special character in the password everything works fine.

http://kodi:#2727#@192.168.0.101:8080/image/
http://kodi:%232727%[email protected]:8080/image/

Regards
Clayton
Reply
Hi

Is it possible to get Retroplayer like player type

Code:
{ "id": 1, "jsonrpc": "2.0", "method": "Player.GetActivePlayers" }
thx
Reply
Did we agree that there is an issue with the json rpc interface and smart playlists?

Can we track this as a fairly substantial bug?

It limits many things I would like to do with JSON-RPC.

Where should a bug be filed?
Reply
Hi.

Is it possible to add an actor (cast) to a movie with the SetMovieDetails method?
I'm missing it from the documentation.

Thanks
Enrico
Reply
(2017-01-28, 05:33)Jeremy White Wrote: Did we agree that there is an issue with the json rpc interface and smart playlists?

Can we track this as a fairly substantial bug?

It limits many things I would like to do with JSON-RPC.

Where should a bug be filed?
Has the issue with JSON and .xsp smart playlists been resolved with the v18 release? I am still having difficulties.
Reply
(2019-10-24, 18:40)37KDeep Wrote:
(2017-01-28, 05:33)Jeremy White Wrote: Did we agree that there is an issue with the json rpc interface and smart playlists?

Can we track this as a fairly substantial bug?

It limits many things I would like to do with JSON-RPC.

Where should a bug be filed?
Has the issue with JSON and .xsp smart playlists been resolved with the v18 release? I am still having difficulties. 
What issue.... can you describe the problem?
Image Lunatixz - Kodi / Beta repository
Image PseudoTV - Forum | Website | Youtube | Help?
Reply
(2019-10-25, 01:43)Lunatixz Wrote:
(2019-10-24, 18:40)37KDeep Wrote:
(2017-01-28, 05:33)Jeremy White Wrote: Did we agree that there is an issue with the json rpc interface and smart playlists?

Can we track this as a fairly substantial bug?

It limits many things I would like to do with JSON-RPC.

Where should a bug be filed?
Has the issue with JSON and .xsp smart playlists been resolved with the v18 release? I am still having difficulties.  
What issue.... can you describe the problem? 
I am a little late to the game on the new JSON call and security protocol for Kodi 18. I am up to speed now and my JSON playlist questions have been answered. Thanks.
Reply
  • 1
  • 222
  • 223
  • 224
  • 225
  • 226(current)

Logout Mark Read Team Forum Stats Members Help
JSON-RPC (JSON Remote Procedure Call) interface protocol in development for XBMC8