Sonos Python 3 Beta

Posted on
Mon Jun 19, 2023 11:35 am
matt (support) offline
Site Admin
User avatar
Posts: 21429
Joined: Jan 27, 2003
Location: Texas

Re: Sonos Python 3 Beta

Based on this it looks like an incompatibility between older versions of pyOpenSSL and newer version of cryptography.

Try upgrading your pyOpenSSL package to 22.1.0 (or even 23.0.0).

Image

Posted on
Mon Jun 19, 2023 12:36 pm
ryanbuckner offline
Posts: 1081
Joined: Oct 08, 2011
Location: Northern Virginia

Re: Sonos Python 3 Beta

After upgrade the error seems to have gone away: Plugin has forgotten my Pandora credentials, but that's a different issue. Thanks!

Code: Select all
Jun 19, 2023 at 2:34:21 PM
   Reloading plugin "Sonos 2023.0.12" using API v3.1
   Starting plugin "Sonos 2023.0.12" (pid 18901)
   Started plugin "Sonos 2023.0.12"
   Sonos                           Loaded Sonos Favorites... [9]
   Sonos                           Loaded Playlists... [7]
   Sonos                           Loaded RadioTime Favorite Stations... [0]
   Sonos Error                     'User not yet authenticated' in module 'pandora.py', method 'check_authentication'
   Failing statement [line 12]: 'raise ValueError("User not yet authenticated")'
   Sonos                           Serving HTTP Streamer on 127.0.0.1 [0.0.0.0], port 8888
   Sonos Error                     [Mon Jun 19 14:34:25 2023] SiriusXM SessionID communications error
   Sonos                           [Mon Jun 19 14:34:25 2023] Processed plugin preferences.
   Sonos                           Loaded Apple Voices.. [48]
   Sonos                           SSDP Listener Started...
   Sonos                           Adding ZonePlayer: 192.168.1.239, RINCON_542A1B8620EE01400, SONOS - Basement Beam
   Sonos                           Adding ZonePlayer: 192.168.1.243, RINCON_7828CA1451B601400, SONOS - Dining Room Speaker
   Sonos                           Adding ZonePlayer: 192.168.1.191, RINCON_5CAAFD5A966601400, SONOS - Family Room Speaker
   Sonos                           Adding ZonePlayer: 192.168.1.188, RINCON_7828CAABC54401400, SONOS - Kitchen Speaker
   Sonos                           Adding ZonePlayer: 192.168.1.193, RINCON_5CAAFDE8718C01400, SONOS - Patio Speakers
   Sonos                           SoCo Reactor Ignition...
   Sonos                           LineIn: RINCON_5CAAFDE8718C01400, Audio Component:Patio
   Sonos                           Loaded Playlists... [7]
   Sonos                           Loaded Playlists... [7]
   Sonos                           Loaded Playlists... [7]



Posted on
Mon Jun 19, 2023 6:48 pm
mclass offline
Posts: 317
Joined: May 13, 2015
Location: Melbourne, Australia

Re: Sonos Python 3 Beta

Thanks for your efforts in taking on the Sonos plugin!

Having installed the latest version on second (unrelated) Indigo system, I am receiving the same error as experienced on the first system when loading and using the plugin. Both systems are running on mac minis running OSX 10.13.6 (High Sierra). Otherwise there are no issues experienced with the new upgraded plugin.

Code: Select all
   Sonos Error                     'HTTP Error 403: Forbidden' in module 'request.py', method 'http_error_default'
   Failing statement [line 643]: 'raise HTTPError(req.full_url, code, msg, hdrs, fp)'


Any suggestions?

mclass

Posted on
Tue Jun 20, 2023 4:50 am
shapa offline
Posts: 483
Joined: Sep 08, 2014
Location: Swindon

Re: Sonos Python 3 Beta

Everything works fine for me (so far); no errors, and all actions / etc., are working.

Posted on
Tue Jun 20, 2023 4:52 am
autolog offline
Posts: 3991
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: Sonos Python 3 Beta

shapa wrote:
Everything works fine for me (so far); no errors, and all actions / etc., are working.

Thanks for the report. :)

Posted on
Tue Jun 20, 2023 4:54 am
autolog offline
Posts: 3991
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: Sonos Python 3 Beta

mclass wrote:
Thanks for your efforts in taking on the Sonos plugin!

Having installed the latest version on second (unrelated) Indigo system, I am receiving the same error as experienced on the first system when loading and using the plugin. Both systems are running on mac minis running OSX 10.13.6 (High Sierra). Otherwise there are no issues experienced with the new upgraded plugin.

Code: Select all
   Sonos Error                     'HTTP Error 403: Forbidden' in module 'request.py', method 'http_error_default'
   Failing statement [line 643]: 'raise HTTPError(req.full_url, code, msg, hdrs, fp)'

I will have to look at putting in some additional error trapping logic so that we can determine what the issue is.

Posted on
Tue Jun 20, 2023 4:56 am
autolog offline
Posts: 3991
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: Sonos Python 3 Beta

ryanbuckner wrote:
... Plugin has forgotten my Pandora credentials, but that's a different issue....

Have you re-added your Pandora credentials and it is now OK or is there still an issue?

Posted on
Tue Jun 20, 2023 7:42 am
ryanbuckner offline
Posts: 1081
Joined: Oct 08, 2011
Location: Northern Virginia

Re: Sonos Python 3 Beta

autolog wrote:
ryanbuckner wrote:
... Plugin has forgotten my Pandora credentials, but that's a different issue....

Have you re-added your Pandora credentials and it is now OK or is there still an issue?


The credentials were actually still in the configure screen so the error is strange. If I go back into the configure screen after reload and simply hit save, the credentials are applied.

Posted on
Tue Jun 20, 2023 8:03 am
autolog offline
Posts: 3991
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: Sonos Python 3 Beta

ryanbuckner wrote:
The credentials were actually still in the configure screen so the error is strange. If I go back into the configure screen after reload and simply hit save, the credentials are applied.

So just to confirm, is this a one-off or does it repeat every time you restart the plugin and you have to edit and save the credentials?

Posted on
Tue Jun 20, 2023 8:44 am
ryanbuckner offline
Posts: 1081
Joined: Oct 08, 2011
Location: Northern Virginia

Re: Sonos Python 3 Beta

It appears to happen each time

Posted on
Tue Jun 20, 2023 11:34 am
autolog offline
Posts: 3991
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: Sonos Python 3 Beta

ryanbuckner wrote:
It appears to happen each time

I have just pushed version 2023.0.14 to Github which will hopefully fix the Pandora issue: Updated Package Requirements + Pandora fix?
Be aware that the package requirements have been updated and will require some updates. They should now all be listed in one go to avoid having to do multiple plugin reloads.

Let me know if this works for you (as I haven't got Pandora and can't test it) and then if OK, I will put out an announcement for the update. :)

Posted on
Tue Jun 20, 2023 12:04 pm
ryanbuckner offline
Posts: 1081
Joined: Oct 08, 2011
Location: Northern Virginia

Re: Sonos Python 3 Beta

In installed the upgrade and got the same error. Note I did not receive instruction in the log to update any packages.

Code: Select all
Jun 20, 2023 at 2:00:30 PM
   Stopping plugin Sonos (pid 18901)
   Sonos                           SoCo Reactor Landing...
   Stopped plugin Sonos
   Upgrading plugin Sonos to newer version 2023.0.14 (previous version moved to trash)
   Loading plugin "Sonos 2023.0.14" using API v3.1
   Starting plugin "Sonos 2023.0.14" (pid 28267)
   Sonos                           Loaded Sonos Favorites... [9]
   Sonos                           Loaded Playlists... [8]
   Sonos                           Loaded RadioTime Favorite Stations... [0]
   Sonos Error                     'User not yet authenticated' in module 'pandora.py', method 'check_authentication'
   Failing statement [line 12]: 'raise ValueError("User not yet authenticated")'
   Sonos                           Serving HTTP Streamer on 192.168.1.6 [0.0.0.0], port 8888
   Sonos Error                     [Tue Jun 20 14:00:38 2023] SiriusXM SessionID communications error
   Sonos                           [Tue Jun 20 14:00:38 2023] Processed plugin preferences.
   Started plugin "Sonos 2023.0.14"
   Sonos                           [Tue Jun 20 14:00:38 2023] Processed plugin preferences.
   Sonos                           Loaded Apple Voices.. [48]
   Sonos                           SSDP Listener Started...
   Sonos                           Adding ZonePlayer: 192.168.1.239, RINCON_542A1B8620EE01400, SONOS - Basement Beam
   Sonos                           Adding ZonePlayer: 192.168.1.243, RINCON_7828CA1451B601400, SONOS - Dining Room Speaker
   Sonos                           Adding ZonePlayer: 192.168.1.191, RINCON_5CAAFD5A966601400, SONOS - Family Room Speaker
   Sonos                           Adding ZonePlayer: 192.168.1.188, RINCON_7828CAABC54401400, SONOS - Kitchen Speaker
   Sonos                           Adding ZonePlayer: 192.168.1.193, RINCON_5CAAFDE8718C01400, SONOS - Patio Speakers
   Sonos                           SoCo Reactor Ignition...
   Sonos                           LineIn: RINCON_5CAAFDE8718C01400, Audio Component:Patio
   Sonos                           Loaded Playlists... [8]



If I go into plugin preferences and hit save, I get this , and Pandora works

Code: Select all
   Sonos                           [Tue Jun 20 14:05:15 2023] Processed plugin preferences.

Posted on
Tue Jun 20, 2023 2:07 pm
autolog offline
Posts: 3991
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: Sonos Python 3 Beta

Thanks for the Pandora feedback.
I'll have another go at this tomorrow and let you know when the next version is ready for testing.

Checking back on the list of packages and versions that you previously posted, I can see you all up-to-date.
So that's why you didn't get any update messages; a sort of negative test. :D

Posted on
Wed Jun 21, 2023 6:33 am
ryanbuckner offline
Posts: 1081
Joined: Oct 08, 2011
Location: Northern Virginia

Re: Sonos Python 3 Beta

Awesome. Thanks for all you're doing.

Posted on
Mon Jun 26, 2023 5:20 am
ryanbuckner offline
Posts: 1081
Joined: Oct 08, 2011
Location: Northern Virginia

Re: Sonos Python 3 Beta

I just added 3 more speakers. An Arc and two Sonos One SLs. I added the SLs as surround sound and the Sonos App grouped them. Similar to my other grouped speakers, the plugin does not appears to like grouped speakers:

Code: Select all
 Started plugin "Sonos 2023.0.14"
   Sonos                           [Mon Jun 26 07:17:35 2023] Processed plugin preferences.
   Sonos                           Loaded Apple Voices.. [48]
   Sonos                           SSDP Listener Started...
   Sonos                           Adding ZonePlayer: 192.168.1.239, RINCON_542A1B8620EE01400, SONOS - Basement Beam
   Sonos                           Adding ZonePlayer: 192.168.1.243, RINCON_7828CA1451B601400, SONOS - Dining Room Speaker
   Sonos                           Adding ZonePlayer: 192.168.1.191, RINCON_5CAAFD5A966601400, SONOS - Family Room Speaker
   Sonos                           Adding ZonePlayer: 192.168.1.217, RINCON_C4387573DED201400, SONOS - Family Room TV Surround (LS)
   Sonos                           Adding ZonePlayer: 192.168.1.216, RINCON_C4387573DEB801400, SONOS - Family Room TV Surround (RS)
   Sonos                           Adding ZonePlayer: 192.168.1.188, RINCON_7828CAABC54401400, SONOS - Kitchen Speaker
   Sonos                           Adding ZonePlayer: 192.168.1.218, RINCON_38420BE2FE7D01400, SONOS - Living Room TV Arc
   Sonos                           Adding ZonePlayer: 192.168.1.193, RINCON_5CAAFDE8718C01400, SONOS - Patio Speakers
   Sonos                           SoCo Reactor Ignition...
   Sonos Error                     UPNP Error: 500
   Sonos Error                     Offending Command -> zoneIP: 192.168.1.217, soapRoot: /MediaServer, soapBranch: /ContentDirectory, soapAction: Browse
   Sonos Error                     Error Response:
   Sonos Error                     Q_Save - ZP type is '<class 'str'>', value is ''
   Sonos Error                     copyStateFromMaster - Unable to split Group Name:
   Sonos                           LineIn: RINCON_5CAAFDE8718C01400, Audio Component:Patio
   Sonos Error                     copyStateFromMaster - Unable to split Group Name:
   Sonos                           Loaded Playlists... [8]
   Received INSTEON                "1st Floor Bathroom Light" on
   Sonos Error                     SOAPSend Error: ("Connection broken: ConnectionResetError(54, 'Connection reset by peer')", ConnectionResetError(54, 'Connection reset by peer'))
   Sonos Error                     'local variable 'response' referenced before assignment' in module 'Sonos.py', method 'SOAPSend'
   Failing statement [line 936]: 'res_bytes = response.text.encode("utf-8")'
   Sonos Error                     Q_Save - ZP type is '<class 'str'>', value is ''
   Sonos Error                     SOAPSend Error: ("Connection broken: ConnectionResetError(54, 'Connection reset by peer')", ConnectionResetError(54, 'Connection reset by peer'))
   Sonos Error                     'local variable 'response' referenced before assignment' in module 'Sonos.py', method 'SOAPSend'
   Failing statement [line 936]: 'res_bytes = response.text.encode("utf-8")'
   Sonos Error                     Q_Save - ZP type is '<class 'str'>', value is ''
   Sonos Error                     copyStateFromMaster - Unable to split Group Name:
   Sonos Error                     copyStateFromMaster - Unable to split Group Name:
   Sonos                           LineIn: Removed: RINCON_5CAAFDE8718C01400, Audio Component:Patio
   Sonos                           LineIn: RINCON_5CAAFDE8718C01400, Audio Component:Patio
   Sonos                           Loaded Playlists... [8]
   Sonos Error                     copyStateFromMaster - Unable to split Group Name:
   Sonos                           Loaded Playlists... [8]
   Sonos Error                     UPNP Error: 500
   Sonos Error                     Offending Command -> zoneIP: 192.168.1.217, soapRoot: /MediaServer, soapBranch: /ContentDirectory, soapAction: Browse
   Sonos Error                     Error Response:
   Sonos Error                     Q_Save - ZP type is '<class 'str'>', value is ''
   Sonos Error                     UPNP Error: 500
   Sonos Error                     Offending Command -> zoneIP: 192.168.1.216, soapRoot: /MediaServer, soapBranch: /ContentDirectory, soapAction: Browse
   Sonos Error                     Error Response:
   Sonos Error                     Q_Save - ZP type is '<class 'str'>', value is ''
   Sonos Error                     copyStateFromMaster - Unable to split Group Name:
   Sonos Error                     copyStateFromMaster - Unable to split Group Name:
   Sonos Error                     UPNP Error: 500
   Sonos Error                     Offending Command -> zoneIP: 192.168.1.216, soapRoot: /MediaServer, soapBranch: /ContentDirectory, soapAction: Browse
   Sonos Error                     Error Response:
   Sonos Error                     Q_Save - ZP type is '<class 'str'>', value is ''
   Sonos Error                     SOAPSend Error: ('Connection aborted.', ConnectionResetError(54, 'Connection reset by peer'))
   Sonos Error                     'local variable 'response' referenced before assignment' in module 'Sonos.py', method 'SOAPSend'
   Failing statement [line 936]: 'res_bytes = response.text.encode("utf-8")'
   Sonos Error                     Q_Save - ZP type is '<class 'str'>', value is ''
   Sonos Error                     copyStateFromMaster - Unable to split Group Name:
   Sonos Error                     copyStateFromMaster - Unable to split Group Name:


Page 5 of 15 1, 2, 3, 4, 5, 6, 7, 8 ... 15

Who is online

Users browsing this forum: No registered users and 1 guest