2011-04-04, 00:36
jitterjames Wrote:With the xbmc nightly build, there doesn't appear to be any indentation on the results that are returned. That is just a clue that something is different, but not necessarily breaking anything. With xbmc 10.1 it comes back all nicely indented.Ah that's a feature I have added since the Dharma release. You can switch it back to the old behaviour with an advanced setting (see http://wiki.xbmc.org/index.php?title=Adv...jsonrpc.3E). The general idea is to minimize the amount of unnecessary data transfered. This is especially useful for devices with very limited RAM like Smartphones etc.
jitterjames Wrote:Now for the true bug... With the nightly, if I call a method that has optional fields, XBMC seems to be returning all fields anyway.Hm seems to be working for me. I ran the exact same request you posted and it returned the following fields for every movie: file, genre, label, movieid, thumbnail, year.
for example with this command:
it returns all fields, not just the defaults + genre + year.Code:{"jsonrpc": "2.0", "method": "VideoLibrary.GetMovies", "params": { "start": 0, "end": 100, "sortorder":"ascending", "fields": ["genre","year"] }, "id": 1}
I just tested it on a nightly build from late March and the very newest one from April 3rd and it works as expected.
jitterjames Wrote:While I'm on the topic, why does this command return the fanart, filename, and thumbnail, even if we don't ask for it? ID and label I can understand, but the rest seems wasteful, especially if I'm asking for a list of all items.That is a very good question and I don't know the answer. "fanart" should already be optional using "fields" but I don't know why "thumbnail" is always returned. Please create a feature request ticket on Trac for this so I don't forget about it.