Closed mreitschuster closed 1 year ago
That's interesting, never seen that kind of thing happen before.
Perhaps it is related to your music collection itself?
Looks like there is an incorrectly escapted \u0002 char in some json somewhere.
SyntaxError: Unexpected token \u0002 in JSON at position 47
thank you!
Perhaps it is related to your music collection itself?
that was it.
I removed a significant chunk of my music library, rescanned in navidrome, stumbled upon a (unrelated?) issue and voila: I can now access my NavidromeMusic Library from Sonos. I will now try to narrow down which file it was.
the unrelated issue: I feel special characters in navidrome login might cause an issue with bonob. When I used an autogenerated PW with many special characters I would often get
navidrome-bonob-1 | {"message":{"level":"debug","data":"<?xml version=\"1.0\" encoding=\"utf-8\"?><soap:Envelope xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:tns=\"http://www.sonos.com/Services/1.1\"><soap:Body><soap:Fault><faultcode>Client.LoginUnauthorized</faultcode><faultstring>Failed to authenticate, try Re-Authorising your account in the sonos app</faultstring></soap:Fault></soap:Body></soap:Envelope>"},"level":"debug","service":"bonob","timestamp":"2023-02-05 09:43:06"}
And in Sonos App it would show something like "your trial with bonob is over". As soon as i changed PW to something simple with only letters and numbers I stopped having that issue.
That's interesting. What happens if you include the character '<', '>', '"' or '&' in your password?
I have now finished readding all music to my library and could not reproduce the initial issue
SyntaxError: Unexpected token \u0002 in JSON at position 47
I think the issue with the password is triggered by the € character. A pw with the 4 characters you mentioned works, but as soon as i add € it fails. The exact message in Sonos is Unable to browse music - your bonob trial has expired
. and the log shows:
navidrome-bonob-1 | {"message":{"level":"debug","data":"<?xml version=\"1.0\" encoding=\"utf-8\"?><soap:Envelope xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:tns=\"http://www.sonos.com/Services/1.1\"><soap:Body><soap:Fault><faultcode>Client.LoginUnauthorized</faultcode><faultstring>Failed to authenticate, try Re-Authorising your account in the sonos app</faultstring></soap:Fault></soap:Body></soap:Envelope>"},"level":"debug","service":"bonob","timestamp":"2023-02-05 13:19:16"}
I have a hunch now this might actually be connected to the "unable to browse music/unexpected token in json" issue. Because what happened initially was I get the "trial expired" message, and a while later it would then change into the "unable to browse music" without any config or library change. When I encountered the "unable to browse" error I still had a € in the password.
I will now leave my config as is (with € pw) for an hour or two to see if that really is what happens.
I was not able to reproduce the SyntaxError: Unexpected token \u0002 in JSON at position 47
. Everything is working fine for me now. What I did since it popped up was:
the second is reliably reproducing the Unable to browse music - your bonob trial has expired
issue when I change my pw.
@simojenki Thank you very much for your help and this great tool!
Hi,
I am setting up bonob for the first time. I am using Sonos S1 (old Play5 and Play1) and want to connect to my navidrome.
my docker-compose.yml:
navidrome access via browser works on http://hostname:12345 sonos is accessible via http://192.168.1.235:1400/status/VERSION i get to see the new bonob service in sonos app, add it, authenticate. bonob is shown as a new player in the navidrome interface
But when trying to then see the music I get: "unable to browse music" in the Sonos app and on the cli of the docker I see
I feel the relevant line is
SyntaxError: Unexpected token \u0002 in JSON at position 47
Do you have an indication whether that might be a configuration error on my side or a issue?