Calling sonos.previous(); should result in the last song being played back.
Current Behavior
When calling the function, the Promise of a Sonos lib function got rejected. Error:
(node:1030) UnhandledPromiseRejectionWarning: Error: upnp: statusCode 500 & upnpErrorCode <s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><s:Body><s:Fault><faultcode>s:Client</faultcode><faultstring>UPnPError</faultstring><detail><UPnPError xmlns="urn:schemas-upnp-org:control-1-0"><errorCode>711</errorCode></UPnPError></detail></s:Fault></s:Body></s:Envelope> at /home/marvin/SonosWebController/node_modules/sonos/lib/services/Service.js:85:23 at processTicksAndRejections (internal/process/task_queues.js:97:5) (node:1030) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag--unhandled-rejections=strict(see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 4)
Possible Solution
Sample code or executed example
This is the code used to call the previous() function: Pastebin
Sorry for the issue, the official Sonos app showed that I could go backwards, but it didn't work. After calling next(); however, I was able to use previous();
394 Expected Behavior
Calling
sonos.previous();
should result in the last song being played back.Current Behavior
When calling the function, the Promise of a Sonos lib function got rejected. Error:
(node:1030) UnhandledPromiseRejectionWarning: Error: upnp: statusCode 500 & upnpErrorCode <s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/" s:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"><s:Body><s:Fault><faultcode>s:Client</faultcode><faultstring>UPnPError</faultstring><detail><UPnPError xmlns="urn:schemas-upnp-org:control-1-0"><errorCode>711</errorCode></UPnPError></detail></s:Fault></s:Body></s:Envelope> at /home/marvin/SonosWebController/node_modules/sonos/lib/services/Service.js:85:23 at processTicksAndRejections (internal/process/task_queues.js:97:5) (node:1030) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag
--unhandled-rejections=strict(see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 4)
Possible Solution
Sample code or executed example
This is the code used to call the previous() function: Pastebin
Versions (and Environment)
Node version: v12.16.1 node-sonos version: 1.13.0 OS: Linux 4.19.97-v7+ armv71 (Raspbian Buster Lite)