Download Frodo compatible test version here

  Thread Rating:
  • 3 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
Tolriq Offline
Donor
Posts: 2,334
Joined: Jun 2009
Reputation: 68
Location: France
Post: #46
JSON rpc is a protocol if the data sent does not follow the protocol how do you want the client to understand ?

The specification is very clear about the fact that strings must be UTF-8 encoded, efficient json parsing needs a stream parser that analyse data as it comes, when some data should not be in the middle the parsers have no way to recover from that.

Xbmc should not be able to send data that does not follow the standard but it does if the data in it's database is not UTF-8 witch was possible until recent Frodo builds. (And will be in Frodo if you don't rescrape the bad data when updating from Eden).

This issue will be recurrent during update until all users rescrapes but well it was the chosen path by the Xbmc team.

Yatse 2 : Media Center Remote Control for Touch Screens
Yatse, the Xbmc Remote and Widgets for Android
find quote
jblance Offline
Junior Member
Posts: 30
Joined: Jan 2013
Reputation: 0
Post: #47
(2013-01-11 21:47)Nat! Wrote:  I think the fetching code should be lenient with respect to encoding exceptions. If a tag is malformed in an album list, it shouldn't really abort the whole operation. After all a tag is just a tag.

Yeah - I've made a small change to the Jackson parser, so it just returns a space if the encoding is incorrect (instead of throwing an error)

This allows the remote to 'work' with bad data instead of failing with an error message. It works for me, will see if Tom is prepared to pull to his repo (as he seems to have the most current code)
find quote
Tolriq Offline
Donor
Posts: 2,334
Joined: Jun 2009
Reputation: 68
Location: France
Post: #48
Some of the needed tests to validate such an hack includes badly encoded utf8 just before an escaped " and as the last character of a string and some more I can't remember Smile

Yatse 2 : Media Center Remote Control for Touch Screens
Yatse, the Xbmc Remote and Widgets for Android
find quote
jblance Offline
Junior Member
Posts: 30
Joined: Jan 2013
Reputation: 0
Post: #49
Yeah I only addressed a small portion of the cases, though they seem to be the ones the are reported....

I didn't want to completely break the parser... Blush
find quote
Tolriq Offline
Donor
Posts: 2,334
Joined: Jun 2009
Reputation: 68
Location: France
Post: #50
Lol yes I know but those 2 cases are user cases (I had lots of logs on this UTF8 problem Tongue)

And if your hack make the parser miss the " or the } then you'll completely break things with way more impact on the user Smile

Yatse 2 : Media Center Remote Control for Touch Screens
Yatse, the Xbmc Remote and Widgets for Android
find quote
jblance Offline
Junior Member
Posts: 30
Joined: Jan 2013
Reputation: 0
Post: #51
Ha, yeah I see your point.

The hack is just referenced by _finishstring and _handleUnexpectedValue functions, so hopefully does not mess with any important parsing...

But I could be mistaken....
find quote
freezy Offline
Team-XBMC Android Remote Developer
Posts: 885
Joined: Dec 2006
Reputation: 15
Location: Switzerland
Post: #52
A little status update.

Tombriden and I spent the whole evening together merging his changes into my master. It was a bit bitchy since our branches have diverged quite a bit. The intermediate result can be seen here:

https://github.com/freezy/android-xbmcre...ridenmerge

We'll test it more thoroughly tomorrow and then post a build here.

On this opportunity I would like to thank tthomas48 for his patience and his agreement to basically throw his JSON-RPC integration away in favor of tombriden's branch. Cheers mate, looking forward seeing your commits in this and the next gen version of the remote! Of course, many thanks go also to tombriden. Let's bring this baby home before Frodo final ships!

Cheers,

-freezy.

Running XBMC on my HTPC, tablet, phone and pinball machine.
Always read the XBMC online-manual, FAQ and search the forums before posting. Do NOT e-mail Team-XBMC members asking for support. For troubleshooting and bug reporting, make sure you read this first.
find quote
spthomas Offline
Junior Member
Posts: 1
Joined: Jun 2011
Reputation: 0
Post: #53
Looking forward to it, missing my Android remote. Sad
find quote
theloon Offline
Junior Member
Posts: 4
Joined: Jan 2013
Reputation: 0
Post: #54
Just moved from Eden w/XBMC remote 808 to Frodo w/remote on post #1 and everything I've tested works well! I was one of those that had java exception errors but after port forwarding and updating firmware on my Belkin router all functioned as it should and I am pleased as all heck. Thanks again for the great app!
find quote
freezy Offline
Team-XBMC Android Remote Developer
Posts: 885
Joined: Dec 2006
Reputation: 15
Location: Switzerland
Post: #55
Updated first post with test build.

Running XBMC on my HTPC, tablet, phone and pinball machine.
Always read the XBMC online-manual, FAQ and search the forums before posting. Do NOT e-mail Team-XBMC members asking for support. For troubleshooting and bug reporting, make sure you read this first.
find quote
corpgator Offline
Senior Member
Posts: 119
Joined: Oct 2012
Reputation: 0
Post: #56
How do I enable and use json? I get no option when adding a new host. The app works fine as a remote, but if I try to open movies, music, etc, it just crashes.
find quote
freezy Offline
Team-XBMC Android Remote Developer
Posts: 885
Joined: Dec 2006
Reputation: 15
Location: Switzerland
Post: #57
Did you try uninstalling your previous version?

Running XBMC on my HTPC, tablet, phone and pinball machine.
Always read the XBMC online-manual, FAQ and search the forums before posting. Do NOT e-mail Team-XBMC members asking for support. For troubleshooting and bug reporting, make sure you read this first.
find quote
corpgator Offline
Senior Member
Posts: 119
Joined: Oct 2012
Reputation: 0
Post: #58
No previous version since I wiped and rooted my android before installing this one. Running latest release candidate of frodo.
find quote
theloon Offline
Junior Member
Posts: 4
Joined: Jan 2013
Reputation: 0
Post: #59
Remote works but crashes when opening movies also, theres no option for json, I'm on RC3 Frodo I'll test on Eden later today.
find quote
freezy Offline
Team-XBMC Android Remote Developer
Posts: 885
Joined: Dec 2006
Reputation: 15
Location: Switzerland
Post: #60
I'll need the log then.

Running XBMC on my HTPC, tablet, phone and pinball machine.
Always read the XBMC online-manual, FAQ and search the forums before posting. Do NOT e-mail Team-XBMC members asking for support. For troubleshooting and bug reporting, make sure you read this first.
find quote