jishi / node-sonos-http-api

An HTTP API bridge for Sonos easing automation. Hostable on any node.js capable device, like a raspberry pi or similar.
http://jishi.github.io/node-sonos-http-api/
MIT License
1.85k stars 460 forks source link

Presets aren't grouping all rooms #192

Closed rgraciano closed 8 years ago

rgraciano commented 8 years ago

Hey @jishi - I was getting a lot of reports that presets were only playing in the first room requested with echo-sonos, so I gave it a shot today and found the same behavior in node-sonos-http-api. Maybe it's something with my example configuration?

I'm hitting https://host/preset/rock and seeing the below output. In my example data below, Dining Room is the first room in my "rock" configuration and it is the only room that ends up playing music.

LMK if you need a hand reproducing:

loaded presets { downstairs: { players: [ [Object] ], state: 'PLAYING', favorite: 'Rock', uri: 'x-rincon-stream:RINCON_0000000000001500', playMode: 'SHUFFLE', pauseOthers: true }, rap: { players: [ [Object], [Object], [Object], [Object], [Object] ], state: 'PLAYING', favorite: 'Rap', uri: 'x-rincon-stream:RINCON_0000000000001500', playMode: 'SHUFFLE', pauseOthers: true }, 'pop rap': { players: [ [Object], [Object], [Object], [Object], [Object] ], state: 'PLAYING', favorite: 'Rap (Pop)', uri: 'x-rincon-stream:RINCON_0000000000001500', playMode: 'SHUFFLE', pauseOthers: true }, rock: { players: [ [Object], [Object], [Object], [Object], [Object] ], state: 'PLAYING', favorite: 'Rock', uri: 'x-rincon-stream:RINCON_0000000000001500', playMode: 'SHUFFLE', pauseOthers: true } } info: scanning for players in ip 192.168.1.208 info: subscribing to topology 192.168.1.206 info: using local endpoint 192.168.1.208 Initializing player Dining Room Initializing player Master Bedroom Initializing player KitchenWall Initializing player Living Room Initializing player Kitchen debug: received avtransport pndrradio:3008664044517633916?sn=1 debug: received avtransport debug: received avtransport pndrradio:85124959121616764 debug: received avtransport pndrradio:85124959121616764 debug: received avtransport debug: emitting group-volume debug: emitting group-volume info: applying preset players=[roomName=Dining Room, volume=20, roomName=Living Room, volume=20, roomName=Kitchen, volume=20, roomName=Master Bedroom, volume=30, roomName=KitchenWall, volume=50], state=PLAYING, favorite=Rock, uri=x-rincon-stream:RINCON_0000000000001500, playMode=SHUFFLE, pauseOthers=true info: skipping breakout because already coordinator debug: checking if Living Room needs to be grouped debug: RINCON_B8E9373FABFC01400 RINCON_B8E937794A6F01400 pndrradio:3008664044517633916?sn=1 x-rincon:RINCON_B8E9373FABFC01400 debug: adding to group debug: checking if Kitchen needs to be grouped debug: RINCON_B8E9373FABFC01400 RINCON_B8E9372BAAE201400 x-rincon:RINCON_B8E9373FABFC01400 debug: adding to group debug: checking if Master Bedroom needs to be grouped debug: RINCON_B8E9373FABFC01400 RINCON_B8E9373C905201400 pndrradio:85124959121616764 x-rincon:RINCON_B8E9373FABFC01400 debug: adding to group debug: checking if KitchenWall needs to be grouped debug: RINCON_B8E9373FABFC01400 RINCON_000E58DFE99801400 x-rincon:RINCON_B8E9373FABFC01400 debug: adding to group info: found it title=Rock, uri=pndrradio:85124959121616764, albumArtURI=http://cont-ch1-1.pandora.com/images/public/amz/4/1/9/2/093624972914_500W_497H.jpg, metaData=dc:titleRock/dc:titleupnp:classobject.item.audioItem.audioBroadcast/upnp:classSA_RINCON3_rmgraci@gmail.com debug: emitting group-volume

GregRocket commented 8 years ago

beta.8

OK we are getting somewhere. Rooms grouped properly. Correct Radio Station and music is playing. I've tested a few presets and all seem to be working correctly. I'll run some more tests and let you know if I see problems. :-)

Here is output for one preset 'easy pop radio'

Webpage Response: {"status":"success"}

Console Respone: 2016-05-18T19:44:04.376Z DEBUG pausing Backyard 2016-05-18T19:44:04.379Z DEBUG invoking pause 2016-05-18T19:44:04.386Z DEBUG pausing Master Bedroom 2016-05-18T19:44:04.386Z DEBUG invoking pause 2016-05-18T19:44:04.393Z DEBUG pausing Master Bathroom 2016-05-18T19:44:04.393Z DEBUG invoking pause 2016-05-18T19:44:04.400Z DEBUG pausing Front Yard 2016-05-18T19:44:04.400Z DEBUG invoking pause 2016-05-18T19:44:04.406Z DEBUG pausing Office 2016-05-18T19:44:04.406Z DEBUG invoking pause 2016-05-18T19:44:04.413Z DEBUG pausing Ladies Room 2016-05-18T19:44:04.413Z DEBUG invoking pause 2016-05-18T19:44:04.420Z DEBUG pausing Hall Bathroom 2016-05-18T19:44:04.420Z DEBUG invoking pause 2016-05-18T19:44:04.427Z DEBUG pausing Media Room 2016-05-18T19:44:04.428Z DEBUG invoking pause 2016-05-18T19:44:04.440Z DEBUG setting volume 50 on Ladies Room 2016-05-18T19:44:04.460Z DEBUG setting volume 50 on Media Room 2016-05-18T19:44:04.467Z DEBUG coordinator is Ladies Room 2016-05-18T19:44:04.469Z DEBUG adding Media Room to coordinator Ladies Room 2016-05-18T19:44:04.627Z DEBUG replacing with favorite Easy Pop Radio 2016-05-18T19:44:04.855Z DEBUG found favorites [ '70s Rock Radio', '80s Pop Radio', '80s Rock Radio', '90s Alternative Radio', 'All 80s Radio', 'Beatles Radio', 'Boston Radio', 'Classic Hits Radio', 'Classic Rock Radio', 'Eagles Radio', 'Easy Pop Radio', 'Hard Rock & Metal Radio', 'Today\'s Hits', 'Top Pop Radio' ] 2016-05-18T19:44:04.864Z DEBUG favorite is radiostation 2016-05-18T19:44:04.865Z DEBUG setting AVTransport to x-sonosapi-radio:prime%2fstations%2fA1HQSY4KHHN1OC%2f%23chunk-idTq9z98RAevSM-n22W4_g?sid=201&flags=8300&sn=5 with metadata dc:titleEasy Pop/dc:titleupnp:classobject.item.audioItem.audioBroadcast/upnp:classSA_RINCON51463X#Svc51463-0-Token 2016-05-18T19:44:05.188Z DEBUG invoking play 2016-05-18T19:44:06.343Z DEBUG invoking play

jishi commented 8 years ago

I can actually reproduce the error when I added a Sonos playlist to favorites, so the dump won't be necessary! Thank you for your assistance!

GregRocket commented 8 years ago

Thank you for your hard work. If you need any more assistance just let me know.

jishi commented 8 years ago

@robertw I identified a stupid bug in the beta version, that could probably have been causing the grouping issues you saw. Please try the latest version and see if it works better.

robertw commented 8 years ago

Good Morning No sorry did not fix the problem will send clips and err log on monday as I am on the road and remote is slow many thanks for the heads up thank you!

robertw commented 8 years ago

Good Morning here is the log to go with the pics as you can see if i call house first all works great but when i call office the group stays intact but office breaks out as it should but i would think that the group also should be broken and return to the state of single zones because when you call house again this is what happens it does not regroup the way it was suppose to

I would think if a controller of a group is removed from the group the group should be canceled and all the members of the group should be ungrouped before removing the controller.

housefirst office house2ndtime ttp server listening on port 5005 loaded presets { office: { players: [ [Object] ], pauseOthers: true }, house: { players: [ [Object], [Object], [Object], [Object] ], state: 'STOP', playMode: 'NORMAL', favorite: 'Carlos Radio' }, party: { players: [ [Object], [Object], [Object] ], state: 'STOP', favorite: 'Marvin Gaye Radio', playMode: 'NORMAL', pauseOthers: true }, hparty: { players: [ [Object], [Object], [Object], [Object], [Object], [Object] ], state: 'STOP', favorite: 'Thumbs up', playMode: 'NORMAL', pauseOthers: true } } info: scanning for players in ip 192.168.1.160 info: subscribing to topology 192.168.1.112 info: using local endpoint 192.168.1.160 Initializing player Office Initializing player Family Room Initializing player Isa Sewing Room Initializing player Portable Initializing player Bathroom Initializing player Living Room Initializing player Isa Room Initializing player Master Bedroom Initializing player Patio debug: emitting group-volume debug: emitting group-volume debug: emitting group-volume debug: emitting group-volume info: applying preset players=[roomName=Office, volume=30, roomName=Family Room, volume=30, roomName=Living Room, volume=30, roomName=Patio, volume=40], state=STOP, playMode=NORMAL, favorite=Carlos Radio info: skipping breakout because already coordinator debug: checking if Family Room needs to be grouped debug: Family Room true debug: adding to group Family Room debug: checking if Living Room needs to be grouped debug: Living Room true debug: adding to group Living Room debug: checking if Patio needs to be grouped debug: Patio true debug: adding to group Patio info: found it title=Carlos Radio, uri=x-sonosapi-radio:VqSHD88yF-larfxudjtHFtxI-WKK6xn_Xw8edPEbMHu74j1mBZvOJewgSIxKmsx1?sid=151&flags=8300&sn=8, albumArtURI=http://lh3.googleusercontent.com/saui3RWPdCBf54CW0TTjqYgzla5SeEcBNxwBVPOZA0VDfk7sFrvjyupbOg=s512-p, metaData=dc:titleCarlos Santana/dc:titleupnp:classobject.item.audioItem.audioBroadcast/upnp:classSA_RINCON38663X#Svc38663-0-Token debug: emitting group-volume debug: emitting group-volume debug: emitting group-volume info: applying preset players=[roomName=Office, volume=30], pauseOthers=true debug: ungrouping Office to prepare for grouping debug: emitting group-volume info: applying preset players=[roomName=Office, volume=30, roomName=Family Room, volume=30, roomName=Living Room, volume=30, roomName=Patio, volume=40], state=STOP, playMode=NORMAL, favorite=Carlos Radio info: skipping breakout because already coordinator debug: checking if Family Room needs to be grouped debug: Family Room false debug: checking if Living Room needs to be grouped debug: Living Room false debug: checking if Patio needs to be grouped debug: Patio true debug: adding to group Patio debug: emitting group-volume info: found it title=Carlos Radio, uri=x-sonosapi-radio:VqSHD88yF-larfxudjtHFtxI-WKK6xn_Xw8edPEbMHu74j1mBZvOJewgSIxKmsx1?sid=151&flags=8300&sn=8, albumArtURI=http://lh3.googleusercontent.com/saui3RWPdCBf54CW0TTjqYgzla5SeEcBNxwBVPOZA0VDfk7sFrvjyupbOg=s512-p, metaData=dc:titleCarlos Santana/dc:titleupnp:classobject.item.audioItem.audioBroadcast/upnp:classSA_RINCON38663X#Svc38663-0-Token debug: emitting group-volume debug: emitting group-volume

I hope this is clearer many thank

jishi commented 8 years ago

@robertw This doesn't look like the beta log output. Please run the beta like this:

Windows powershell

$env:NODE_LOG_LEVEL='debug'
node server.js

Linux or OS X

NODE_LOG_LEVEL=debug node server.js

and I do not agree that a group should be exploded if the coordinator leaves. The concept of coordinator should not matter, and it makes more sense to let the rest of the group be as is. This is how it works with the official controller.

robertw commented 8 years ago

will double check i installed from git fresh and rerun I understand but if you go back to regroup it doesn't do it correct so it was just a suggestion that's all

thnak you

On Tue, May 24, 2016 at 8:59 AM, Jimmy Shimizu notifications@github.com wrote:

@robertw https://github.com/robertw This doesn't look like the beta log output. Please run the beta like this:

Windows powershell

$env:NODE_LOG_LEVEL='debug' node server.js

Linux or OS X

NODE_LOG_LEVEL=debug node server.js

and I do not agree that a group should be exploded if the coordinator leaves. The concept of coordinator should not matter, and it makes more sense to let the rest of the group be as is. This is how it works with the official controller.

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/jishi/node-sonos-http-api/issues/192#issuecomment-221260602

Regards

Robert

robertw commented 8 years ago

Well first my bad I did not download the right beta file rebuilt the whole thing and it looks like it is fixed will bang it some more but i think you got it many thanks

as per this came up when ran the preset in the browser

{"status":"error","error":"Error: Internal Server Error\n at ClientRequest. (/home/pi/test/node-sonos-http-api/node_modules/sonos-discovery/lib/helpers/request.js:22:21)\n at ClientRequest.g (events.js:260:16)\n at emitOne (events.js:77:13)\n at ClientRequest.emit (events.js:169:7)\n at HTTPParser.parserOnIncomingClient (_http_client.js:415:21)\n at HTTPParser.parserOnHeadersComplete (_http_common.js:88:23)\n at Socket.socketOnData (_http_client.js:305:20)\n at emitOne (events.js:77:13)\n at Socket.emit (events.js:169:7)\n at readableAddChunk (_stream_readable.js:146:16)\n at Socket.Readable.push (_stream_readable.js:110:10)\n at TCP.onread (net.js:523:20)"}

and here is the log file not sure what the first error meant but it maybe some help or i am missing a lib once again thanks for your hard work and attention to detail

root@raspberrypi:/home/pi/test/node-sonos-http-api# NODE_LOG_LEVEL=debug node server.js no settings file found, will only use default settings { [Error: Cannot find module './settings.json'] code: 'MODULE_NOT_FOUND' } sending M-SEARCH... http server listening on port 5005 Presets: { office: { players: [ { roomName: 'Office', volume: 30 } ], pauseOthers: true }, house: { players: [ { roomName: 'Office', volume: 30 }, { roomName: 'Family Room', volume: 30 }, { roomName: 'Living Room', volume: 30 }, { roomName: 'Patio', volume: 40 } ], state: 'STOP', playMode: 'NORMAL', favorite: 'Carlos Radio' }, party: { players: [ { roomName: 'Office', volume: 30 }, { roomName: 'Family Room', volume: 30 }, { roomName: 'Patio', volume: 40 } ], state: 'STOP', favorite: 'Marvin Gaye Radio', playMode: 'NORMAL', pauseOthers: true }, hparty: { players: [ { roomName: 'Office', volume: 30 }, { roomName: 'Family Room', volume: 30 }, { roomName: 'Living Room', volume: 30 }, { roomName: 'Master Bedroom', volume: 30 }, { roomName: 'Patio', volume: 40 }, { roomName: 'Portable', volume: 50 } ], state: 'PLAYING', favorite: 'Thumbs up', playMode: 'NORMAL', pauseOthers: true } } 2016-05-24T13:31:00.882Z DEBUG No such service x-sonosprog-http:A0DvPDnowsL_90pgFLfKVgNcCbtRzN5yYQ4jO2iHpR-5GBZX2iDfmw.mp3?sid=151&flags=32&sn=8 2016-05-24T13:31:03.312Z DEBUG No such service x-sonosprog-http:A0DvPDnowsKDkffoE9RjeufvtSo4PfHzkmQUafWdEcptLN5y2EdPpg.mp3?sid=151&flags=32&sn=8 2016-05-24T13:31:03.318Z DEBUG No such service 2016-05-24T13:31:03.322Z DEBUG No such service 2016-05-24T13:31:03.325Z DEBUG No such service 2016-05-24T13:31:03.329Z DEBUG No such service 2016-05-24T13:31:03.333Z DEBUG No such service 2016-05-24T13:31:03.337Z DEBUG No such service https://yonomi-tts-proxy.herokuapp.com/tts.mp3?src=Good%20Night%20robisa&hl=en-gb&r=0&f=16khz_16bit_stereo 2016-05-24T13:31:03.798Z DEBUG No such service 2016-05-24T13:31:48.278Z DEBUG coordinator is Office 2016-05-24T13:31:48.286Z DEBUG adding Family Room to coordinator Office 2016-05-24T13:31:48.289Z DEBUG adding Living Room to coordinator Office 2016-05-24T13:31:48.292Z DEBUG adding Patio to coordinator Office 2016-05-24T13:31:48.332Z DEBUG coordinator is Office 2016-05-24T13:31:48.334Z DEBUG adding Family Room to coordinator Office 2016-05-24T13:31:48.337Z DEBUG adding Living Room to coordinator Office 2016-05-24T13:31:48.339Z DEBUG adding Patio to coordinator Office 2016-05-24T13:31:48.982Z DEBUG No such service 2016-05-24T13:31:49.026Z DEBUG setting volume 30 on Office 2016-05-24T13:31:49.420Z DEBUG No such service 2016-05-24T13:31:49.423Z DEBUG No such service 2016-05-24T13:31:49.447Z DEBUG setting volume 30 on Family Room 2016-05-24T13:31:49.609Z DEBUG setting volume 30 on Living Room 2016-05-24T13:31:49.645Z DEBUG setting volume 30 on Office 2016-05-24T13:31:49.661Z DEBUG setting volume 40 on Patio 2016-05-24T13:31:49.693Z DEBUG replacing with favorite Carlos Radio 2016-05-24T13:31:49.731Z DEBUG setting volume 30 on Family Room 2016-05-24T13:31:49.756Z DEBUG setting volume 30 on Living Room 2016-05-24T13:31:50.001Z DEBUG setting volume 40 on Patio 2016-05-24T13:31:50.590Z DEBUG found favorites [ 'Carlos Radio', 'Fourplay Radio', 'Marvin Gaye Radio', 'Thumbs up', 'Timeless Pop-Rock Hits', 'Top Charts', 'Toto', 'Ultimate Party Sing-Alongs' ] 2016-05-24T13:31:50.606Z DEBUG favorite is radiostation 2016-05-24T13:31:50.610Z DEBUG setting AVTransport to x-sonosapi-radio:VqSHD88yF-larfxudjtHFtxI-WKK6xn_Xw8edPEbMHu74j1mBZvOJewgSIxKmsx1?sid=151&flags=8300&sn=8 with metadata <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="100c206cVqSHD88yF-larfxudjtHFtxI-WKK6xn_Xw8edPEbMHu74j1mBZvOJewgSIxKmsx1" parentID="100d2064eTUTsZbO2U4" restricted="true">dc:titleCarlos Santana/dc:titleupnp:classobject.item.audioItem.audioBroadcast/upnp:class<desc id="cdudn" nameSpace="urn:schemas-rinconnetworks-com:metadata-1-0/">SA_RINCON38663X#Svc38663-0-Token 2016-05-24T13:31:50.632Z DEBUG replacing with favorite Carlos Radio 2016-05-24T13:31:52.389Z DEBUG found favorites [ 'Carlos Radio', 'Fourplay Radio', 'Marvin Gaye Radio', 'Thumbs up', 'Timeless Pop-Rock Hits', 'Top Charts', 'Toto', 'Ultimate Party Sing-Alongs' ] 2016-05-24T13:31:52.399Z DEBUG favorite is radiostation 2016-05-24T13:31:52.402Z DEBUG setting AVTransport to x-sonosapi-radio:VqSHD88yF-larfxudjtHFtxI-WKK6xn_Xw8edPEbMHu74j1mBZvOJewgSIxKmsx1?sid=151&flags=8300&sn=8 with metadata <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="100c206cVqSHD88yF-larfxudjtHFtxI-WKK6xn_Xw8edPEbMHu74j1mBZvOJewgSIxKmsx1" parentID="100d2064eTUTsZbO2U4" restricted="true">dc:titleCarlos Santana/dc:titleupnp:classobject.item.audioItem.audioBroadcast/upnp:class<desc id="cdudn" nameSpace="urn:schemas-rinconnetworks-com:metadata-1-0/">SA_RINCON38663X#Svc38663-0-Token 2016-05-24T13:31:52.425Z DEBUG invoking play 2016-05-24T13:31:53.044Z DEBUG No such service 2016-05-24T13:31:53.047Z DEBUG No such service 2016-05-24T13:31:53.078Z DEBUG invoking play 2016-05-24T13:31:54.986Z DEBUG Setting repeat to function repeat() { [native code] } 2016-05-24T13:31:55.025Z DEBUG Setting repeat to function repeat() { [native code] } Error: Internal Server Error at ClientRequest. (/home/pi/test/node-sonos-http-api/node_modules/sonos-discovery/lib/helpers/request.js:22:21) at ClientRequest.g (events.js:260:16) at emitOne (events.js:77:13) at ClientRequest.emit (events.js:169:7) at HTTPParser.parserOnIncomingClient (_http_client.js:415:21) at HTTPParser.parserOnHeadersComplete (_http_common.js:88:23) at Socket.socketOnData (_http_client.js:305:20) at emitOne (events.js:77:13) at Socket.emit (events.js:169:7) at readableAddChunk (_stream_readable.js:146:16) at Socket.Readable.push (_stream_readable.js:110:10) at TCP.onread (net.js:523:20) Error: Internal Server Error at ClientRequest. (/home/pi/test/node-sonos-http-api/node_modules/sonos-discovery/lib/helpers/request.js:22:21) at ClientRequest.g (events.js:260:16) at emitOne (events.js:77:13) at ClientRequest.emit (events.js:169:7) at HTTPParser.parserOnIncomingClient (_http_client.js:415:21) at HTTPParser.parserOnHeadersComplete (_http_common.js:88:23) at Socket.socketOnData (_http_client.js:305:20) at emitOne (events.js:77:13) at Socket.emit (events.js:169:7) at readableAddChunk (_stream_readable.js:146:16) at Socket.Readable.push (_stream_readable.js:110:10) at TCP.onread (net.js:523:20) undefined 2016-05-24T13:31:57.663Z DEBUG No such service x-sonosprog-http:A0DvPDnowsKBldmUBhQsFKgq66Fo2BhFNZVeLFWoweu4HIxGrhkEiw.mp3?sid=151&flags=32&sn=8 2016-05-24T13:31:57.733Z DEBUG No such service x-sonosprog-http:A0DvPDnowsLD89gbpiwPIWpNko1ioU26V9BXVeiO_hSOmdev93SfQw.mp3?sid=151&flags=32&sn=8 2016-05-24T13:32:17.687Z DEBUG pausing Office 2016-05-24T13:32:17.690Z DEBUG invoking pause 2016-05-24T13:32:17.812Z DEBUG pausing Master Bedroom 2016-05-24T13:32:17.815Z DEBUG invoking pause 2016-05-24T13:32:17.883Z DEBUG pausing Bathroom 2016-05-24T13:32:17.885Z DEBUG invoking pause 2016-05-24T13:32:18.274Z DEBUG No such service x-sonosprog-http:A0DvPDnowsKBldmUBhQsFKgq66Fo2BhFNZVeLFWoweu4HIxGrhkEiw.mp3?sid=151&flags=32&sn=8 2016-05-24T13:32:18.293Z DEBUG pausing Isa Sewing Room 2016-05-24T13:32:18.296Z DEBUG invoking pause 2016-05-24T13:32:18.358Z DEBUG No such service x-sonosprog-http:A0DvPDnowsLD89gbpiwPIWpNko1ioU26V9BXVeiO_hSOmdev93SfQw.mp3?sid=151&flags=32&sn=8 2016-05-24T13:32:18.401Z DEBUG pausing Portable 2016-05-24T13:32:18.404Z DEBUG invoking pause 2016-05-24T13:32:18.537Z DEBUG pausing Isa Room 2016-05-24T13:32:18.539Z DEBUG invoking pause 2016-05-24T13:32:18.562Z DEBUG coordinator is Office 2016-05-24T13:32:18.564Z DEBUG breaking out Office 2016-05-24T13:32:20.706Z DEBUG No such service x-sonosprog-http:A0DvPDnowsKBldmUBhQsFKgq66Fo2BhFNZVeLFWoweu4HIxGrhkEiw.mp3?sid=151&flags=32&sn=8 2016-05-24T13:32:20.725Z DEBUG setting volume 30 on Office 2016-05-24T13:32:20.788Z DEBUG No such service x-sonosprog-http:A0DvPDnowsLD89gbpiwPIWpNko1ioU26V9BXVeiO_hSOmdev93SfQw.mp3?sid=151&flags=32&sn=8 2016-05-24T13:32:20.942Z DEBUG invoking play undefined 2016-05-24T13:32:23.461Z DEBUG No such service x-sonosprog-http:_dklxfo-EJNcnf0cRss2DTOzvzz3_AKlflbxOEt8Wsxt-iv4gy-V0YKdsi9cNqzZ.mp3?sid=151&flags=8192&sn=8 2016-05-24T13:32:23.524Z DEBUG No such service x-sonosprog-http:A0DvPDnowsIBnRTPD3ruvfybu5seHwGUlEqLnKNPB8ew6VhORjSuDg.mp3?sid=151&flags=32&sn=8 2016-05-24T13:32:24.143Z DEBUG No such service x-sonosprog-http:_dklxfo-EJNcnf0cRss2DTOzvzz3_AKlflbxOEt8Wsxt-iv4gy-V0YKdsi9cNqzZ.mp3?sid=151&flags=8192&sn=8 2016-05-24T13:32:24.208Z DEBUG No such service x-sonosprog-http:A0DvPDnowsIBnRTPD3ruvfybu5seHwGUlEqLnKNPB8ew6VhORjSuDg.mp3?sid=151&flags=32&sn=8 2016-05-24T13:32:33.247Z DEBUG coordinator is Office 2016-05-24T13:32:33.250Z DEBUG adding Family Room to coordinator Office 2016-05-24T13:32:33.253Z DEBUG adding Living Room to coordinator Office 2016-05-24T13:32:33.255Z DEBUG adding Patio to coordinator Office 2016-05-24T13:32:33.642Z DEBUG No such service 2016-05-24T13:32:33.914Z DEBUG No such service 2016-05-24T13:32:34.011Z DEBUG setting volume 30 on Office 2016-05-24T13:32:34.098Z DEBUG setting volume 30 on Family Room 2016-05-24T13:32:34.231Z DEBUG setting volume 30 on Living Room 2016-05-24T13:32:34.523Z DEBUG setting volume 40 on Patio 2016-05-24T13:32:34.593Z DEBUG replacing with favorite Carlos Radio 2016-05-24T13:32:35.695Z DEBUG found favorites [ 'Carlos Radio', 'Fourplay Radio', 'Marvin Gaye Radio', 'Thumbs up', 'Timeless Pop-Rock Hits', 'Top Charts', 'Toto', 'Ultimate Party Sing-Alongs' ] 2016-05-24T13:32:35.710Z DEBUG favorite is radiostation 2016-05-24T13:32:35.712Z DEBUG setting AVTransport to x-sonosapi-radio:VqSHD88yF-larfxudjtHFtxI-WKK6xn_Xw8edPEbMHu74j1mBZvOJewgSIxKmsx1?sid=151&flags=8300&sn=8 with metadata <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="100c206cVqSHD88yF-larfxudjtHFtxI-WKK6xn_Xw8edPEbMHu74j1mBZvOJewgSIxKmsx1" parentID="100d2064eTUTsZbO2U4" restricted="true">dc:titleCarlos Santana/dc:titleupnp:classobject.item.audioItem.audioBroadcast/upnp:class<desc id="cdudn" nameSpace="urn:schemas-rinconnetworks-com:metadata-1-0/">SA_RINCON38663X#Svc38663-0-Token 2016-05-24T13:32:36.990Z DEBUG No such service 2016-05-24T13:32:37.077Z DEBUG invoking play 2016-05-24T13:32:38.199Z DEBUG Setting repeat to function repeat() { [native code] } Error: Internal Server Error at ClientRequest. (/home/pi/test/node-sonos-http-api/node_modules/sonos-discovery/lib/helpers/request.js:22:21) at ClientRequest.g (events.js:260:16) at emitOne (events.js:77:13) at ClientRequest.emit (events.js:169:7) at HTTPParser.parserOnIncomingClient (_http_client.js:415:21) at HTTPParser.parserOnHeadersComplete (_http_common.js:88:23) at Socket.socketOnData (_http_client.js:305:20) at emitOne (events.js:77:13) at Socket.emit (events.js:169:7) at readableAddChunk (_stream_readable.js:146:16) at Socket.Readable.push (_stream_readable.js:110:10) at TCP.onread (net.js:523:20) undefined 2016-05-24T13:32:38.776Z DEBUG No such service x-sonosprog-http:A0DvPDnowsLDisdiTq1g5l340n5orxxjeSMOU0p90Tx0Nc0q_xoetQ.mp3?sid=151&flags=32&sn=8 2016-05-24T13:32:38.833Z DEBUG No such service x-sonosprog-http:A0DvPDnowsK4UcbXvCpM99-bMIQWRMSCSCtAS9k4FH4p3y5z1xMeiw.mp3?sid=151&flags=32&sn=8 2016-05-24T13:32:40.142Z DEBUG No such service x-sonosprog-http:A0DvPDnowsLDisdiTq1g5l340n5orxxjeSMOU0p90Tx0Nc0q_xoetQ.mp3?sid=151&flags=32&sn=8 2016-05-24T13:32:40.200Z DEBUG No such service x-sonosprog-http:A0DvPDnowsK4UcbXvCpM99-bMIQWRMSCSCtAS9k4FH4p3y5z1xMeiw.mp3?sid=151&flags=32&sn=8 2016-05-24T13:32:46.176Z DEBUG No such service x-sonosprog-http:A0DvPDnowsLDisdiTq1g5l340n5orxxjeSMOU0p90Tx0Nc0q_xoetQ.mp3?sid=151&flags=32&sn=8 2016-05-24T13:32:46.234Z DEBUG No such service x-sonosprog-http:A0DvPDnowsK4UcbXvCpM99-bMIQWRMSCSCtAS9k4FH4p3y5z1xMeiw.mp3?sid=151&flags=32&sn=8 2016-05-24T13:32:55.583Z DEBUG pausing Office 2016-05-24T13:32:55.586Z DEBUG invoking pause 2016-05-24T13:32:55.627Z DEBUG pausing Master Bedroom 2016-05-24T13:32:55.630Z DEBUG invoking pause 2016-05-24T13:32:55.663Z DEBUG pausing Bathroom 2016-05-24T13:32:55.666Z DEBUG invoking pause 2016-05-24T13:32:55.686Z DEBUG pausing Isa Sewing Room 2016-05-24T13:32:55.688Z DEBUG invoking pause 2016-05-24T13:32:55.710Z DEBUG pausing Portable 2016-05-24T13:32:55.713Z DEBUG invoking pause 2016-05-24T13:32:55.760Z DEBUG pausing Isa Room 2016-05-24T13:32:55.762Z DEBUG invoking pause 2016-05-24T13:32:55.785Z DEBUG coordinator is Office 2016-05-24T13:32:55.788Z DEBUG skipping grouping for Family Room because it is already grouped with coordinator 2016-05-24T13:32:55.791Z DEBUG skipping grouping for Patio because it is already grouped with coordinator 2016-05-24T13:32:55.797Z DEBUG ungrouping Living Room to coordinator Office 2016-05-24T13:32:56.420Z DEBUG setting volume 30 on Office 2016-05-24T13:32:56.444Z DEBUG setting volume 30 on Family Room 2016-05-24T13:32:56.469Z DEBUG setting volume 40 on Patio 2016-05-24T13:32:56.684Z DEBUG No such service 2016-05-24T13:32:56.735Z DEBUG replacing with favorite Marvin Gaye Radio 2016-05-24T13:32:57.039Z DEBUG pausing Office 2016-05-24T13:32:57.041Z DEBUG invoking pause 2016-05-24T13:32:58.075Z DEBUG found favorites [ 'Carlos Radio', 'Fourplay Radio', 'Marvin Gaye Radio', 'Thumbs up', 'Timeless Pop-Rock Hits', 'Top Charts', 'Toto', 'Ultimate Party Sing-Alongs' ] 2016-05-24T13:32:58.084Z DEBUG favorite is radiostation 2016-05-24T13:32:58.087Z DEBUG setting AVTransport to x-sonosapi-radio:RtKyvX0yjlwE63fBEJYXBJrY2ycB2glbNc0hDIN-djkY82e3mYYk5Q?sid=151&flags=8300&sn=8 with metadata <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="000c206cRtKyvX0yjlwE63fBEJYXBJrY2ycB2glbNc0hDIN-djkY82e3mYYk5Q" parentID="000520649zyj7a88zQFkfEI0dxkD1uZM5r0FZ3bU03LGs-mSnUNjQV2SJoDOlQ" restricted="true">dc:titleMarvin Gaye Radio/dc:titleupnp:classobject.item.audioItem.audioBroadcast/upnp:class<desc id="cdudn" nameSpace="urn:schemas-rinconnetworks-com:metadata-1-0/">SA_RINCON38663X#Svc38663-0-Token 2016-05-24T13:32:58.103Z DEBUG pausing Master Bedroom 2016-05-24T13:32:58.106Z DEBUG invoking pause 2016-05-24T13:32:58.773Z DEBUG pausing Bathroom 2016-05-24T13:32:58.775Z DEBUG invoking pause 2016-05-24T13:32:58.790Z DEBUG invoking play 2016-05-24T13:32:59.003Z DEBUG No such service 2016-05-24T13:32:59.019Z DEBUG pausing Isa Sewing Room 2016-05-24T13:32:59.022Z DEBUG invoking pause 2016-05-24T13:32:59.110Z DEBUG pausing Portable 2016-05-24T13:32:59.113Z DEBUG invoking pause 2016-05-24T13:32:59.181Z DEBUG pausing Isa Room 2016-05-24T13:32:59.183Z DEBUG invoking pause 2016-05-24T13:32:59.211Z DEBUG coordinator is Office 2016-05-24T13:32:59.213Z DEBUG skipping grouping for Family Room because it is already grouped with coordinator 2016-05-24T13:32:59.216Z DEBUG skipping grouping for Patio because it is already grouped with coordinator 2016-05-24T13:32:59.219Z DEBUG setting volume 30 on Office 2016-05-24T13:32:59.243Z DEBUG setting volume 30 on Family Room 2016-05-24T13:32:59.269Z DEBUG setting volume 40 on Patio 2016-05-24T13:32:59.296Z DEBUG replacing with favorite Marvin Gaye Radio 2016-05-24T13:33:00.241Z DEBUG found favorites [ 'Carlos Radio', 'Fourplay Radio', 'Marvin Gaye Radio', 'Thumbs up', 'Timeless Pop-Rock Hits', 'Top Charts', 'Toto', 'Ultimate Party Sing-Alongs' ] 2016-05-24T13:33:00.250Z DEBUG favorite is radiostation 2016-05-24T13:33:00.254Z DEBUG setting AVTransport to x-sonosapi-radio:RtKyvX0yjlwE63fBEJYXBJrY2ycB2glbNc0hDIN-djkY82e3mYYk5Q?sid=151&flags=8300&sn=8 with metadata <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="000c206cRtKyvX0yjlwE63fBEJYXBJrY2ycB2glbNc0hDIN-djkY82e3mYYk5Q" parentID="000520649zyj7a88zQFkfEI0dxkD1uZM5r0FZ3bU03LGs-mSnUNjQV2SJoDOlQ" restricted="true">dc:titleMarvin Gaye Radio/dc:titleupnp:classobject.item.audioItem.audioBroadcast/upnp:class<desc id="cdudn" nameSpace="urn:schemas-rinconnetworks-com:metadata-1-0/">SA_RINCON38663X#Svc38663-0-Token 2016-05-24T13:33:00.270Z DEBUG Setting repeat to function repeat() { [native code] } 2016-05-24T13:33:01.088Z DEBUG invoking play Error: Internal Server Error at ClientRequest. (/home/pi/test/node-sonos-http-api/node_modules/sonos-discovery/lib/helpers/request.js:22:21) at ClientRequest.g (events.js:260:16) at emitOne (events.js:77:13) at ClientRequest.emit (events.js:169:7) at HTTPParser.parserOnIncomingClient (_http_client.js:415:21) at HTTPParser.parserOnHeadersComplete (_http_common.js:88:23) at Socket.socketOnData (_http_client.js:305:20) at emitOne (events.js:77:13) at Socket.emit (events.js:169:7) at readableAddChunk (_stream_readable.js:146:16) at Socket.Readable.push (_stream_readable.js:110:10) at TCP.onread (net.js:523:20) 2016-05-24T13:33:01.338Z DEBUG No such service 2016-05-24T13:33:02.103Z DEBUG Setting repeat to function repeat() { [native code] } 2016-05-24T13:33:02.562Z DEBUG No such service x-sonosprog-http:A0DvPDnowsJb6ZFzALQggSxjSIMVo7PNHPnjfnDeyb94DtcrGXuhgg.mp3?sid=151&flags=32&sn=8 Error: Internal Server Error at ClientRequest. (/home/pi/test/node-sonos-http-api/node_modules/sonos-discovery/lib/helpers/request.js:22:21) at ClientRequest.g (events.js:260:16) at emitOne (events.js:77:13) at ClientRequest.emit (events.js:169:7) at HTTPParser.parserOnIncomingClient (_http_client.js:415:21) at HTTPParser.parserOnHeadersComplete (_http_common.js:88:23) at Socket.socketOnData (_http_client.js:305:20) at emitOne (events.js:77:13) at Socket.emit (events.js:169:7) at readableAddChunk (_stream_readable.js:146:16) at Socket.Readable.push (_stream_readable.js:110:10) at TCP.onread (net.js:523:20) 2016-05-24T13:33:02.630Z DEBUG No such service x-sonosprog-http:A0DvPDnowsKwRgowmyCG4yK1xnz9y9g5u5Yx8VhDwfZkjpZ7wv6xmQ.mp3?sid=151&flags=32&sn=8 undefined 2016-05-24T13:33:03.797Z DEBUG No such service x-sonosprog-http:A0DvPDnowsJb6ZFzALQggSxjSIMVo7PNHPnjfnDeyb94DtcrGXuhgg.mp3?sid=151&flags=32&sn=8 2016-05-24T13:33:03.854Z DEBUG No such service x-sonosprog-http:A0DvPDnowsKwRgowmyCG4yK1xnz9y9g5u5Yx8VhDwfZkjpZ7wv6xmQ.mp3?sid=151&flags=32&sn=8 2016-05-24T13:33:11.724Z DEBUG coordinator is Office 2016-05-24T13:33:11.727Z DEBUG skipping grouping for Family Room because it is already grouped with coordinator 2016-05-24T13:33:11.729Z DEBUG adding Living Room to coordinator Office 2016-05-24T13:33:11.732Z DEBUG skipping grouping for Patio because it is already grouped with coordinator 2016-05-24T13:33:11.918Z DEBUG setting volume 30 on Office 2016-05-24T13:33:11.963Z DEBUG setting volume 30 on Family Room 2016-05-24T13:33:11.989Z DEBUG setting volume 30 on Living Room 2016-05-24T13:33:12.168Z DEBUG No such service 2016-05-24T13:33:12.183Z DEBUG setting volume 40 on Patio 2016-05-24T13:33:12.461Z DEBUG replacing with favorite Carlos Radio 2016-05-24T13:33:13.373Z DEBUG found favorites [ 'Carlos Radio', 'Fourplay Radio', 'Marvin Gaye Radio', 'Thumbs up', 'Timeless Pop-Rock Hits', 'Top Charts', 'Toto', 'Ultimate Party Sing-Alongs' ] 2016-05-24T13:33:13.382Z DEBUG favorite is radiostation 2016-05-24T13:33:13.385Z DEBUG setting AVTransport to x-sonosapi-radio:VqSHD88yF-larfxudjtHFtxI-WKK6xn_Xw8edPEbMHu74j1mBZvOJewgSIxKmsx1?sid=151&flags=8300&sn=8 with metadata <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="100c206cVqSHD88yF-larfxudjtHFtxI-WKK6xn_Xw8edPEbMHu74j1mBZvOJewgSIxKmsx1" parentID="100d2064eTUTsZbO2U4" restricted="true">dc:titleCarlos Santana/dc:titleupnp:classobject.item.audioItem.audioBroadcast/upnp:class<desc id="cdudn" nameSpace="urn:schemas-rinconnetworks-com:metadata-1-0/">SA_RINCON38663X#Svc38663-0-Token 2016-05-24T13:33:14.468Z DEBUG invoking play 2016-05-24T13:33:15.972Z DEBUG Setting repeat to function repeat() { [native code] } Error: Internal Server Error at ClientRequest. (/home/pi/test/node-sonos-http-api/node_modules/sonos-discovery/lib/helpers/request.js:22:21) at ClientRequest.g (events.js:260:16) at emitOne (events.js:77:13) at ClientRequest.emit (events.js:169:7) at HTTPParser.parserOnIncomingClient (_http_client.js:415:21) at HTTPParser.parserOnHeadersComplete (_http_common.js:88:23) at Socket.socketOnData (_http_client.js:305:20) at emitOne (events.js:77:13) at Socket.emit (events.js:169:7) at readableAddChunk (_stream_readable.js:146:16) at Socket.Readable.push (_stream_readable.js:110:10) at TCP.onread (net.js:523:20) 2016-05-24T13:33:16.431Z DEBUG No such service x-sonosprog-http:A0DvPDnowsJlRDR_c4pq4V0FhoXklN2yXjuKWQN73P6zStL4IZjdwg.mp3?sid=151&flags=32&sn=8 2016-05-24T13:33:16.500Z DEBUG No such service x-sonosprog-http:A0DvPDnowsLoafFcOG0UeEvrwcHJopqtAdFuQHExbc0FWB1jvG7m8w.mp3?sid=151&flags=32&sn=8 undefined 2016-05-24T13:33:17.909Z DEBUG No such service x-sonosprog-http:A0DvPDnowsJlRDR_c4pq4V0FhoXklN2yXjuKWQN73P6zStL4IZjdwg.mp3?sid=151&flags=32&sn=8 2016-05-24T13:33:17.965Z DEBUG No such service x-sonosprog-http:A0DvPDnowsLoafFcOG0UeEvrwcHJopqtAdFuQHExbc0FWB1jvG7m8w.mp3?sid=151&flags=32&sn=8 2016-05-24T13:33:23.987Z DEBUG No such service x-sonosprog-http:A0DvPDnowsJlRDR_c4pq4V0FhoXklN2yXjuKWQN73P6zStL4IZjdwg.mp3?sid=151&flags=32&sn=8 2016-05-24T13:33:24.044Z DEBUG No such service x-sonosprog-http:A0DvPDnowsLoafFcOG0UeEvrwcHJopqtAdFuQHExbc0FWB1jvG7m8w.mp3?sid=151&flags=32&sn=8

On Tue, May 24, 2016 at 9:37 AM, Robert Wyman wymanrobert@gmail.com wrote:

will double check i installed from git fresh and rerun I understand but if you go back to regroup it doesn't do it correct so it was just a suggestion that's all

thnak you

On Tue, May 24, 2016 at 8:59 AM, Jimmy Shimizu notifications@github.com wrote:

@robertw https://github.com/robertw This doesn't look like the beta log output. Please run the beta like this:

Windows powershell

$env:NODE_LOG_LEVEL='debug' node server.js

Linux or OS X

NODE_LOG_LEVEL=debug node server.js

and I do not agree that a group should be exploded if the coordinator leaves. The concept of coordinator should not matter, and it makes more sense to let the rest of the group be as is. This is how it works with the official controller.

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/jishi/node-sonos-http-api/issues/192#issuecomment-221260602

Regards

Robert

Regards

Robert

jishi commented 8 years ago

Yes, your playMode needs to be updated in your presets. It now needs to be an object,

playMode: {
  repeat: false,
  shuffle: false,
  crossfade: false
}
jishi commented 8 years ago

The beta version is now more or less on-par with the old version in functionality, and with vastly improved say commands. I will soon merge that into master, but if anyone could verify that this grouping issue that was originally part of this issue is resolved with the beta version, then I can go ahead and close this ticket.

robertw commented 8 years ago

From what I see grouping seems to be working well I have been testing with 13 zones so from my view point this is closed.

One ask could we get a ungroup function to destroy all groups or selected group by preset name maybe ?

Once again great work Thank you ......

On Tue, May 24, 2016 at 5:30 PM, Jimmy Shimizu notifications@github.com wrote:

The beta version is now more or less on-par with the old version in functionality, and with vastly improved say commands. I will soon merge that into master, but if anyone could verify that this grouping issue that was originally part of this issue is resolved with the beta version, then I can go ahead and close this ticket.

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/jishi/node-sonos-http-api/issues/192#issuecomment-221401915

Regards

Robert

jishi commented 8 years ago

@robertw Please open new issues regarding those features and we'll discuss them there.

@GregRocket You did reproduce the "only started playback in first player when radio favorite was in preset", right? Could you verify that the beta resolves that?

GregRocket commented 8 years ago

@GregRocket You did reproduce the "only started playback in first player when radio favorite was in preset", right? Could you verify that the beta resolves that?

@jishi v1.0.0-beta.12 I've done some extensive testing of Presets. Every preset worked as expected. Radio favorites and Playlist favorites work correctly, grouping and playing.

To me, this issue is resolved.

jishi commented 8 years ago

@GregRocket Great to hear. Thank you everyone!

Solved by beta-version (beta branch)

maddox commented 8 years ago

So this is just generally broken on master?

It should probably be noted in the README, to set the right expectations. This beta branch seems to be a VERY long running branch, maybe it should be mentioned in the README as well, especially if bugs are being fixed there and not backported to master.

maddox commented 8 years ago

Snap! I see beta has been merged! WOOT, congrats!

Time to update some things.