Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
    Jimmy Shimizu
    @jishi
    @John-Jood the output doesn't give me any good reason why it is exiting. You need to run it with NODE_LOG_LEVEL=trace npm start and give me the last part of the log just before the crash.
    John-Jood
    @John-Jood

    @jishi here it is :

    code
    2020-11-29T10:35:29.469Z DEBUG resuming all players
    2020-11-29T10:35:34.517Z DEBUG invoking play
    2020-11-29T10:35:34.518Z TRACE http://192.168.0.44:1400/MediaRenderer/AVTransport/Control urn:schemas-upnp-org:service:AVTransport:1#Play <s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><s:Body><u:Play xmlns:u="urn:schemas-upnp-org:service:AVTransport:1"><InstanceID>0</InstanceID><Speed>1</Speed></u:Play></s:Body></s:Envelope>
    2020-11-29T10:35:34.574Z TRACE status code: 200
    2020-11-29T10:35:34.959Z TRACE <Event xmlns="urn:schemas-upnp-org:metadata-1-0/AVT/" xmlns:r="urn:schemas-rinconnetworks-com:metadata-1-0/"><InstanceID val="0"><TransportState val="PLAYING"/><CurrentPlayMode val="REPEAT_ALL"/><CurrentCrossfadeMode val="0"/><NumberOfTracks val="1"/><CurrentTrack val="1"/><CurrentSection val="0"/><CurrentTrackURI val="x-sonos-spotify:spotify:track:02kDW379Yfd5PzW5A6vuGt?sid=9&flags=0&sn=1"/><CurrentTrackDuration val="0:03:15"/><CurrentTrackMetaData val="<DIDL-Lite xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:upnp="urn:schemas-upnp-org:metadata-1-0/upnp/" xmlns:r="urn:schemas-rinconnetworks-com:metadata-1-0/" xmlns="urn:schemas-upnp-org:metadata-1-0/DIDL-Lite/"><item id="-1" parentID="-1"><res duration="0:03:15">x-sonos-spotify:spotify:track:02kDW379Yfd5PzW5A6vuGt?sid=9&amp;flags=0&amp;sn=1</res><upnp:albumArtURI>https://i.scdn.co/image/ab67616d0000b273d46a8fffbe6c8630784f04da</upnp:albumArtURI><upnp:class>object.item.audioItem.musicTrack</upnp:class><dc:title>Lemonade</dc:title><dc:creator>Internet Money</dc:creator><upnp:album>Lemonade (feat. Gunna, Don Toliver &amp; NAV)</upnp:album></item></DIDL-Lite>"/><r:NextTrackURI val=""/><r:NextTrackMetaData val="<DIDL-Lite xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:upnp="urn:schemas-upnp-org:metadata-1-0/upnp/" xmlns:r="urn:schemas-rinconnetworks-com:metadata-1-0/" xmlns="urn:schemas-upnp-org:metadata-1-0/DIDL-Lite/"><item id="-1" parentID="-1"><res></res><upnp:albumArtURI></upnp:albumArtURI><upnp:class>object.item.audioItem.musicTrack</upnp:class><dc:title>Goosebumps</dc:title><dc:creator>HVME</dc:creator><upnp:album>Goosebumps</upnp:album></item></DIDL-Lite>"/><r:EnqueuedTransportURI val=""/><r:EnqueuedTransportURIMetaData val="<DIDL-Lite xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:upnp="urn:schemas-upnp-org:metadata-1-0/upnp/" xmlns:r="urn:schemas-rinconnetworks-com:metadata-1-0/" xmlns="urn:schemas-upnp-org:metadata-1-0/DIDL-Lite/"><item id="" parentID="-1" restricted="true"><dc:title>Hits du Moment</dc:title><upnp:class>object.container.playlistContainer</upnp:class><desc id="cdudn" nameSpace="urn:schemas-rinconnetworks-com:metadata-1-0/">SA_RINCON2311_X_#Svc2311-0-Token</desc><upnp:albumArtURI></upnp:albumArtURI></item></DIDL-Lite>"/><PlaybackStorageMedium val="NETWORK"/><AVTransportURI val="x-rincon-queue:RINCON_7828CAE6616E01400#vli"/><AVTransportURIMetaData val="<DIDL-Lite xmlns:dc="http://purl.org/dc/elements/1.1/&quot; xmlns:upnp="urn:schemas-upnp-org:metadata-1-0/upnp/" xmlns:r="urn:schemas-rinconnetworks-com:metadata-1-0/" xmlns="urn:schemas-upnp-org:metadata-1-0/DIDL-Lite/"><item id="spotify" parentID="0" restricted="false"><dc:title>Spotify</dc:title><upnp:class>object.item.audioItem.linein</upnp:class><res protocolInfo="x-sonos-vli::audio:">x-sonos-vli:RINCON_7828CAE6616E01400:2,spotify:ab7bc1d44ce416fc45f0721593b4656b</res><v

    cookie="10" group=""></vli></item></DIDL-Lite>"/><CurrentTransportActions val="Set, Stop, Pause, Play, X_DLNA_SeekTime, Next, Previous"/><r:CurrentValidPlayModes val="SHUFFLE,REPEAT,REPEATONE"/><r:MuseSessions val=""/><r:DirectControlClientID val="spotify.connect.adapter"/><r:DirectControlIsSuspended val="0"/><r:DirectControlAccountID val=""/></InstanceID></Event>
    2020-11-29T10:35:34.992Z DEBUG Updated playback state in notification handler
    2020-11-29T10:35:35.010Z DEBUG No such service x-sonos-spotify:spotify:track:02kDW379Yfd5PzW5A6vuGt?sid=9&flags=0&sn=1
    /home/pi/node-sonos-http-api/node_modules/sonos-discovery/lib/models/Player.js:99
    track.duration = parseTime((item.res.$attrs || item.res).duration);
    ^

    TypeError: Cannot read property '$attrs' of undefined
    at EventEmitter.<anonymous> (/home/pi/node-sonos-http-api/node_modules/sonos-discovery/lib/models/Player.js:99:44)
    at EventEmitter.emit (events.js:315:20)
    at EventEmitter.emit (domain.js:485:12)
    at SAXStream.onCloseTag (/home/pi/node-sonos-http-api/node_modules/xml-flow/lib/xml-flow.js:131:15)
    at SAXStream.emit (events.js:315:20)
    at SAXStream.EventEmitter.emit (domain.js:485:12)
    at SAXParser.me._parser.<computed> [as onclosetag] (/home/pi/node-sonos-http-api/node_modules/sax/lib/sax.js:258:17)
    at emit (/home/pi/node-sonos-http-api/node_modules/sax/lib/sax.js:640:35)
    at emitNode (/home/pi/node-sonos-http-api/node_modules/sax/lib/sax.js:645:5)
    at closeTag (/home/pi/node-sonos-http-api/node_modules/sax/lib/sax.js:905:7)
    at SAXParser.write (/home/pi/node-sonos-http-api/node_modules/sax/lib/sax.js:1449:13)
    at SAXStream.write (/home/pi/node-sonos-http-api/node_modules/sax/lib/sax.js:239:18)
    at Readable.ondata (_stream_readable.js:707:22)
    at Readable.emit (events.js:315:20)
    at Readable.EventEmitter.emit (domain.js:485:12)
    at addChunk (_stream_readable.js:296:12)
    at readableAddChunk (_stream_readable.js:272:9)
    at Readable.push (_stream_readable.js:213:10)
    at Immediate.<anonymous> (/home/pi/node-sonos-http-api/node_modules/sonos-discovery/lib/helpers/streamer.js:12:18)
    at processImmediate (internal/timers.js:456:21)
    at process.topLevelDomainCallback (domain.js:137:15)
    npm ERR! code ELIFECYCLE
    npm ERR! errno 1
    npm ERR! sonos-http-api@1.6.0 start: node server.js
    npm ERR! Exit status 1
    npm ERR!
    npm ERR! Failed at the sonos-http-api@1.6.0 start script.
    npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

    npm ERR! A complete log of this run can be found in:
    npm ERR! /home/pi/.npm/_logs/2020-11-29T10_35_35_075Z-debug.log

    Jimmy Shimizu
    @jishi
    @John-Jood you are running an outdated version, try running the latest master. That sounds like a familiar bug that should have been fixed. Don't forget to reinstall the dependencies after upgrading.
    John-Jood
    @John-Jood
    @jishi You are right. I got a custom fork of Node-Sonos-http-api on Chris Campbell's Qrocodile. I'm afraid it could be outdated. Did you have any feedback on it ?
    John-Jood
    @John-Jood
    (i confirm i made a fresh installation from the last version and it works :/)
    Jimmy Shimizu
    @jishi
    Most of the work is done in the underlying library, so you should be fine with referencing the latest sonos-discovery in package.json, here https://github.com/jishi/node-sonos-http-api/blob/master/package.json#L25
    And then run npm install again
    John-Jood
    @John-Jood
    @jishi It works ! Thanks a lot for your help !
    j
    @jasonthefirst_twitter
    Hey @jishi i know you dont have a move, but... my move has sort of disappeared? When i call for its state i get a response, but it’s wrong. And when i try to do anything else via the api, it times out. Any thoughts?
    Jimmy Shimizu
    @jishi
    @jasonthefirst_twitter does it frequently change IP? I'm assuming you can still control it via the sonos app. The api might not handle IP changes fully seamlessly, and those should be rare (since otherwise sonos in itself will be sad), if you have any means of logging the IP used by the move over time, that would help. In the meantime, a restart of the api should probably suffice.
    j
    @jasonthefirst_twitter
    Yeah app still works. Ive tried restarting with no luck. Ill try giving the Move a static IP, maybe that will help.
    Yeah i think that did the trick. Weird! Sorry ro bother you, love love love your work!
    Jimmy Shimizu
    @jishi
    Super strange, but glad it got sorted out.
    bayratt
    @bayratt
    @John-Jood I am also trying to run Chris Campbell's Qrocodile project, and having issues playing from Spotify (many of the commands work fine, but not all). Did you modify anything else besides the line in the package file mentioned above?
    John-Jood
    @John-Jood
    @bayratt For the moment i only tested "play/pause" command (which works) and didn't have the time to test the other ones. I'll keep you posted if i face any issues
    j
    @jasonthefirst_twitter
    Hey @jishi perhaps I spoke too soon. Now the Move is fine, but a couple of my other speakers (One SLs) are behaving weirdly. Seems like it's just timing out when I make a request to two of my six rooms. The error looks like this: {"status":"error","error":"connect ETIMEDOUT 192.168.1.22:1400","stack":"Error: connect ETIMEDOUT 192.168.1.22:1400\n at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1141:16)"}
    Ive restarted the API and the machine on which it's running... nothing changes. Any advice would be appreciated!
    j
    @jasonthefirst_twitter
    ok wtf seems like re-booting the speakers themselves might fix it? I'm so confused. :/
    ok turns out the restart fixed one speaker. the other still times out. ¯_(ツ)_/¯
    j
    @jasonthefirst_twitter
    so sorry to spam the chat, but I finally sorted a weird permissions issue and installed the freshest version of node, and that seems to have solved it (for now). fingers crossed!
    Jimmy Shimizu
    @jishi
    @John-Jood I think you should really keep track of the ip-addresses that your sonos gear use, to see if they are constantly changing. Also compare the ips that are timing out with the assigned ips of the players.
    John-Jood
    @John-Jood
    @jishi Are u sure this message wath for me ?
    j
    @jasonthefirst_twitter
    it was for me. And I will keep an eye on it; I'd been running it as a launch agent but now I've got it running in terminal so I can see the errors more clearly
    and right now, as I'm doing nothing but having the api listen, it's basically cycling through my speakers with this error: WARN resubscribing to sid null failed
    Error: connect ETIMEDOUT 192.168.1.20:1400
    the IP address stays the same for a few timeouts, then it seems to pick a new one
    Jimmy Shimizu
    @jishi
    @jasonthefirst_twitter but does any of your players actually have 192.168.1.20?
    j
    @jasonthefirst_twitter
    Yeah it did, I had made the IP static. But then I took that off, it was assigned a new one, and the API kept calling the old IP. restarted the API, and now I'm getting a new error: Got status 500 when invoking /MediaRenderer/AVTransport/Control","stack":"Error: Got status 500 when invoking /MediaRenderer/AVTransport/Control\n at Object.invoke (/home/pi/node-sonos-http-api/node_modules/sonos-discovery/lib/helpers/soap.js:99:10)\n at Player.play (/home/pi/node-sonos-http-api/node_modules/sonos-discovery/lib/models/Player.js:446:15)\n at promise.then (/home/pi/node-sonos-http-api/node_modules/sonos-discovery/lib/prototypes/SonosSystem/applyPreset.js:153:46)\n at processTicksAndRejections (internal/process/task_queues.js:86:5)"}
    idk man, things were working smoothly for so long and then things got weird. maybe around the time I added a sub to the system? tho not sure how that would mess things up. do you generally suggest ppl put all the speakers on static IP, or does that not usually make a difference?
    Jimmy Shimizu
    @jishi
    @jasonthefirst_twitter it normally doesn't make a difference, and a healthy network shouldn't change ip-addresses at all if the devices are constantly powered on. I don't see how a sub would affect anything. I would be surprised if the system works flawlessly outside of this api...
    j
    @jasonthefirst_twitter
    it mostly does. Every once in a while a speaker will be missing from the Sonos app or AirPlay, but pretty infrequently. Have you noticed any difference if the system is wired?
    acab
    @wasfret_twitter
    Hello all! I am having an issue with setting up macOS say command- I have inserted {"macSay": {
    "Voice" : "Joana"
    }
    };
    sorry, early send- I have inserted that following the 'var settings' section, but I am not sure if that is the correct place to put it, as it isn't changing from the default google voice
    Luke Nukem
    @lukenukemmp3_twitter
    hello there, i am trying to use this wonderful thing on a raspberry with Homebridge. i am able to download, install and start the service, but as soon as i close the terminal, the service is shutdown. how can i avoid this? thank you in advance
    lnguyenh
    @lnguyenh
    @lukenukemmp3_twitter there are many different ways, one of them is to have it run as a service. Google "systemd service" for example.
    Jimmy Shimizu
    @jishi
    Easiest might be to use pm2, it has options to install the systemd service and keep track of which node.js apps that you have started.
    @wasfret_twitter did you put that in settings.json? Also, voice is lower case, and Joana might not be a valid voice name on macos
    Luke Nukem
    @lukenukemmp3_twitter
    @lnguyenh thank you very much! but there is another issue. I dont use homebridge in its native form, but a HOOBS-Installation instead. Everytime i reboot the system, the directory "/node-sonos-http-api-master" is automatically deleted, so there is no .js to start. Sorry for the massive noobness.
    acab
    @wasfret_twitter
    @jishi I did, I will try messing with the case. thanks!
    Owain Williams
    @OwainWilliams
    Hi, is it just me or has Spotify removed the URI lookup? I can't seem to get it to work anymore
    http://192.168.0.32:5005/Study/spotify/play/6agCM9GJcebduMddgFmgsO this returns a success message but nothing actually plays or shows in my queue
    1 reply
    John-Jood
    @John-Jood
    @jishi Hi Jishi, i've got an issue while trying to read Playlists on Spotify with http://192.168.0.41:5005/salon/spotify/now/spotify:playlist:3xN6J0LCyVj8k1gVCguWRH or even http://192.168.0.41:5005/salon/spotify/now/spotify:user:spotify:playlist:3xN6J0LCyVj8k1gVCguWRH
    Can you please help me with this issue ?
    John-Jood
    @John-Jood
    I face the following issue :
    {"status":"error","error":"Got status 500 when invoking /MediaRenderer/AVTransport/Control","stack":"Error: Got status 500 when invoking /MediaRenderer/AVTransport/Control\n at Object.invoke (/home/pi/Developer/node-sonos-http-api/node_modules/sonos-discovery/lib/helpers/soap.js:99:10)\n at Player.trackSeek (/home/pi/Developer/node-sonos-http-api/node_modules/sonos-discovery/lib/models/Player.js:552:15)\n at /home/pi/Developer/node-sonos-http-api/lib/actions/spotify.js:38:56\n at processTicksAndRejections (internal/process/task_queues.js:93:5)"}
    acab
    @wasfret_twitter
    hello! I'm having trouble getting the node to load my settings.json file
    should I delete the settings.js file? everything starts up fine but it isn't accepting my macSay addition or my spotify keys for search
    I'm running this on a mac, I should mention. my settings.json file reads like this-
    and it is in the root directory of the server
    acab
    @wasfret_twitter
    nevermind! had made a couple of syntax errors! got it up and running
    Owain Williams
    @OwainWilliams
    Is this room actually used anymore?
    John-Jood
    @John-Jood
    Yes i had the opportunity to get some help from @jishi a couple of days aga