Cynical Network 3.0- Error

Posted on
Thu Jun 02, 2022 9:39 pm
Korey offline
User avatar
Posts: 751
Joined: Jun 04, 2008
Location: Henderson, NV

Cynical Network 3.0- Error

Hi Perry,

After updating to the 3.0 version from 1.8.0 I'm getting this error:

Code: Select all
 Action Group                    D1 Zone 2 Power ON Serial
   Cynical Network Error           field "text": 'str' object has no attribute 'decode'
   Cynical Network Error           execution of sendText abandoned


Let me know if I can help with more debugging!


Debugging gives this:
Code: Select all
Jun 2, 2022 at 8:25:07 PM
Started plugin "Cynical Network 3.0.0"
   Cynical Network                 debugging enabled
   Action Group                    D1 Zone 2 Power ON Serial  test
   Cynical Network Error           field "text": 'str' object has no attribute 'decode'
   Cynical Network Error           execution of sendText abandoned
   Reloading plugin "Cynical Network 3.0.0" using API v3.0.0
   Stopping plugin "Cynical Network 3.0.0" (pid 1225)
   Cynical Network                 shutdown sensed
   Cynical Network                 D1 Head Phone Level stopping
   Cynical Network                  Anthem D1 Serial configured for 16 input event(s)
   Cynical Network                 D1 RS232 TX Query stopping
   Cynical Network                  Anthem D1 Serial configured for 15 input event(s)
   Cynical Network                 D1 Zone 1 AC3 stopping
   Cynical Network                  Anthem D1 Serial configured for 14 input event(s)
   Cynical Network                 D1 Zone 1 Back Level stopping
   Cynical Network                  Anthem D1 Serial configured for 13 input event(s)
   Cynical Network                 D1 Zone 1 Center Level stopping
   Cynical Network                  Anthem D1 Serial configured for 12 input event(s)
   Cynical Network                 D1 Zone 1 Decoder mode stopping
   Cynical Network                  Anthem D1 Serial configured for 11 input event(s)
   Cynical Network                 D1 Zone 1 Decoder mode copy stopping
   Cynical Network                  Anthem D1 Serial configured for 10 input event(s)
   Cynical Network                 D1 Zone 1 Dolby Digital EX stopping
   Cynical Network                  Anthem D1 Serial configured for 9 input event(s)
   Cynical Network                 D1 Zone 1 Dolby Dynamic Range stopping
   Cynical Network                  Anthem D1 Serial configured for 8 input event(s)
   Cynical Network                 D1 Zone 1 Front Level stopping
   Cynical Network                  Anthem D1 Serial configured for 7 input event(s)
   Cynical Network                 D1 Zone 1 LFE Level stopping
   Cynical Network                  Anthem D1 Serial configured for 6 input event(s)
   Cynical Network                 D1 Zone 1 Power Status stopping
   Cynical Network                  Anthem D1 Serial configured for 5 input event(s)
   Cynical Network                 D1 Zone 1 Processing mode stopping
   Cynical Network                  Anthem D1 Serial configured for 4 input event(s)
   Cynical Network                 D1 Zone 1 Stereo Effects stopping
   Cynical Network                  Anthem D1 Serial configured for 3 input event(s)
   Cynical Network                 D1 Zone 1 Sub Level stopping
   Cynical Network                  Anthem D1 Serial configured for 2 input event(s)
   Cynical Network                 D1 Zone 1 Sub Phase +- stopping
   Cynical Network                  Anthem D1 Serial configured for 1 input event(s)
   Cynical Network                 D1 Zone 1 Surround Level stopping
   Cynical Network                  Anthem D1 Serial configured for 0 input event(s)
   Cynical Network                  Anthem D1 Serial stopping
   Cynical Network                  Anthem D1 Serial is now disconnected
   Stopped plugin "Cynical Network 3.0.0"
   Debugging plugin "Cynical Network 3.0.0" (pid 1430)
   Cynical Network                 API version 3.0
   Cynical Network                 Python version 3.10.2.final.0
   Started plugin "Cynical Network 3.0.0"
   Cynical Network                 mapping device " Anthem D1 Serial" 130542549(outgoing)
   Cynical Network                  Anthem D1 Serial starting
   Cynical Network                  Anthem D1 Serial is now idle
   Cynical Network                  Anthem D1 Serial connecting to 192.168.0.242
   Cynical Network                 mapping event "D1 Head Phone Level" 441078608(recognized)
   Cynical Network                 D1 Head Phone Level starting
   Cynical Network                 mapping event "D1 RS232 TX Query" 472273826(recognized)
   Cynical Network                 D1 RS232 TX Query starting
   Cynical Network                 mapping event "D1 Zone 1 AC3" 1989609126(recognized)
   Cynical Network                 D1 Zone 1 AC3 starting
   Cynical Network                 mapping event "D1 Zone 1 Back Level" 1234489519(recognized)
   Cynical Network                 D1 Zone 1 Back Level starting
   Cynical Network                 mapping event "D1 Zone 1 Center Level" 1406814371(recognized)
   Cynical Network                 D1 Zone 1 Center Level starting
   Cynical Network                 mapping event "D1 Zone 1 Decoder mode" 257519160(recognized)
   Cynical Network                 D1 Zone 1 Decoder mode starting
   Cynical Network                 mapping event "D1 Zone 1 Decoder mode copy" 622140607(recognized)
   Cynical Network                 D1 Zone 1 Decoder mode copy starting
   Cynical Network                 mapping event "D1 Zone 1 Dolby Digital EX" 575617226(recognized)
   Cynical Network                 D1 Zone 1 Dolby Digital EX starting
   Cynical Network                 mapping event "D1 Zone 1 Dolby Dynamic Range" 1514512322(recognized)
   Cynical Network                 D1 Zone 1 Dolby Dynamic Range starting
   Cynical Network                 mapping event "D1 Zone 1 Front Level" 635392700(recognized)
   Cynical Network                 D1 Zone 1 Front Level starting
   Cynical Network                 mapping event "D1 Zone 1 LFE Level" 848781937(recognized)
   Cynical Network                 D1 Zone 1 LFE Level starting
   Cynical Network                 mapping event "D1 Zone 1 Power Status" 1113933348(recognized)
   Cynical Network                 D1 Zone 1 Power Status starting
   Cynical Network                 mapping event "D1 Zone 1 Processing mode" 636008595(recognized)
   Cynical Network                 D1 Zone 1 Processing mode starting
   Cynical Network                 mapping event "D1 Zone 1 Stereo Effects" 434232698(recognized)
   Cynical Network                 D1 Zone 1 Stereo Effects starting
   Cynical Network                 mapping event "D1 Zone 1 Sub Level" 1481829589(recognized)
   Cynical Network                 D1 Zone 1 Sub Level starting
   Cynical Network                 mapping event "D1 Zone 1 Sub Phase +-" 215273260(recognized)
   Cynical Network                 D1 Zone 1 Sub Phase +- starting
   Cynical Network                 mapping event "D1 Zone 1 Surround Level" 1272608085(recognized)
   Cynical Network                 D1 Zone 1 Surround Level starting
   Cynical Network                 plugin starting asyn operation
   Cynical Network                  Anthem D1 Serial is now connected
   Cynical Network                  Anthem D1 Serial configured for 17 input event(s)
   Action Group                    D1 Zone 2 Power ON Serial  test
   Cynical Network Error           field "text": 'str' object has no attribute 'decode'
   Cynical Network Error           execution of sendText abandoned


Debugging on 1.8.0:

Code: Select all
Started plugin "Cynical Network 1.8.0"
   Cynical Network                 mapping device " Anthem D1 Serial" 130542549(outgoing)
   Cynical Network                  Anthem D1 Serial starting
   Cynical Network                  Anthem D1 Serial is now idle
   Cynical Network                  Anthem D1 Serial connecting to 192.168.0.242
   Cynical Network                 mapping event "D1 Head Phone Level" 441078608(recognized)
   Cynical Network                 D1 Head Phone Level starting
   Cynical Network                 mapping event "D1 RS232 TX Query" 472273826(recognized)
   Cynical Network                 D1 RS232 TX Query starting
   Cynical Network                 mapping event "D1 Zone 1 AC3" 1989609126(recognized)
   Cynical Network                 D1 Zone 1 AC3 starting
   Cynical Network                 mapping event "D1 Zone 1 Back Level" 1234489519(recognized)
   Cynical Network                 D1 Zone 1 Back Level starting
   Cynical Network                 mapping event "D1 Zone 1 Center Level" 1406814371(recognized)
   Cynical Network                 D1 Zone 1 Center Level starting
   Cynical Network                 mapping event "D1 Zone 1 Decoder mode" 257519160(recognized)
   Cynical Network                 D1 Zone 1 Decoder mode starting
   Cynical Network                 mapping event "D1 Zone 1 Decoder mode copy" 622140607(recognized)
   Cynical Network                 D1 Zone 1 Decoder mode copy starting
   Cynical Network                 mapping event "D1 Zone 1 Dolby Digital EX" 575617226(recognized)
   Cynical Network                 D1 Zone 1 Dolby Digital EX starting
   Cynical Network                 mapping event "D1 Zone 1 Dolby Dynamic Range" 1514512322(recognized)
   Cynical Network                 D1 Zone 1 Dolby Dynamic Range starting
   Cynical Network                 mapping event "D1 Zone 1 Front Level" 635392700(recognized)
   Cynical Network                 D1 Zone 1 Front Level starting
   Cynical Network                 mapping event "D1 Zone 1 LFE Level" 848781937(recognized)
   Cynical Network                 D1 Zone 1 LFE Level starting
   Cynical Network                 mapping event "D1 Zone 1 Power Status" 1113933348(recognized)
   Cynical Network                 D1 Zone 1 Power Status starting
   Cynical Network                 mapping event "D1 Zone 1 Processing mode" 636008595(recognized)
   Cynical Network                 D1 Zone 1 Processing mode starting
   Cynical Network                 mapping event "D1 Zone 1 Stereo Effects" 434232698(recognized)
   Cynical Network                 D1 Zone 1 Stereo Effects starting
   Cynical Network                 mapping event "D1 Zone 1 Sub Level" 1481829589(recognized)
   Cynical Network                 D1 Zone 1 Sub Level starting
   Cynical Network                 mapping event "D1 Zone 1 Sub Phase +-" 215273260(recognized)
   Cynical Network                 D1 Zone 1 Sub Phase +- starting
   Cynical Network                 mapping event "D1 Zone 1 Surround Level" 1272608085(recognized)
   Cynical Network                 D1 Zone 1 Surround Level starting
   Cynical Network                 plugin starting asyn operation
   Cynical Network                  Anthem D1 Serial is now connected
   Cynical Network                  Anthem D1 Serial configured for 17 input event(s)
   Action Group                    D1 Zone 2 Power ON Serial  test
   Cynical Network                  Anthem D1 Serial unrecognized input ''



This is the command being sent:
Attachments
Screen Shot 2022-06-02 at 8.34.06 PM.png
Screen Shot 2022-06-02 at 8.34.06 PM.png (107.91 KiB) Viewed 546 times

--
Korey

Posted on
Thu Jun 02, 2022 9:51 pm
Korey offline
User avatar
Posts: 751
Joined: Jun 04, 2008
Location: Henderson, NV

Re: Cynical Network 3.0- Error

as well, when trying to save the config for the Global cache unit in 3.0 I get this:

Code: Select all
Jun 2, 2022 at 8:46:09 PM
   Cynical Network Error           in validateIOMConfigUi:
  File ".../Server Plugin/cyin/plug.py", line 392, in validateIOMConfigUi
    return self._ui._check_ui(values)
  File ".../Server Plugin/cyin/configui.py", line 140, in _check_ui
    self._check_fields()
  File ".../Server Plugin/cyin/configui.py", line 187, in _check_fields
    self._ui_values['address'] = getattr(self.iomtype, 'display_address').__func__(self)
AttributeError: 'function' object has no attribute '__func__'


Attempting the same in 1.8.0 works as it should, saves then closes the dialog box.
Attachments
Screen Shot 2022-06-02 at 8.47.23 PM.png
Screen Shot 2022-06-02 at 8.47.23 PM.png (104.79 KiB) Viewed 544 times

--
Korey

Posted on
Tue Jun 14, 2022 1:26 pm
Wizard Sleeve offline
Posts: 40
Joined: Feb 11, 2008
Location: Berkshire, United Kingdom

Re: Cynical Network 3.0- Error

Im also getting this on Cynical Network and on Cache Devices that send serial commands. Same thing about "str" and "Decode". When I look in the command setup dialog box it tells me the same thing highlighted red.

Posted on
Tue Jun 14, 2022 6:50 pm
agame offline
Posts: 505
Joined: Jul 13, 2017
Location: Melbourne, Australia

Re: Cynical Network 3.0- Error

....and on Cynical Security Spy and on Cynical Behaviours.

Posted on
Fri Jul 08, 2022 1:14 am
Perry The Cynic offline
Posts: 813
Joined: Apr 07, 2008

Re: Cynical Network 3.0- Error

Got me there. Another left-over Python 3 string handling oddity (this time, un-escaping \r and such). Fixed.

And yes, the config-UI problem was common to all my plugins. That's also fixed. I think. :-)

Cheers
-- perry

Posted on
Fri Jul 08, 2022 11:28 am
Korey offline
User avatar
Posts: 751
Joined: Jun 04, 2008
Location: Henderson, NV

Re: Cynical Network 3.0- Error

Thanks for the updates Perry!

UI issues resolved :D

Unfortunately I still have a lingering issue with Cynical Network 3.1.1:

Let me know if I can help with debugging.


Code: Select all
   Starting plugin "Cynical Network 3.1.1" (pid 61931)
   Cynical Network                 API version 3.0
   Cynical Network                 Python version 3.10.2.final.0
   Started plugin "Cynical Network 3.1.1"

Jul 8, 2022 at 10:22:53 AM
   Action Group                    D1 Zone 2 Power ON Serial
   Action Group                    D1 Zone 2 Power ? Serial
   Action Group                    D1 Zone 2 Tape Serial
   Cynical Network Error           in sendText: Traceback (most recent call last):
  File ".../Server Plugin/cyin/debugging.py", line 67, in diagnostic_log
    yield
  File ".../Server Plugin/cyin/debugging.py", line 77, in diagnose_call
    return method(*args, **kwargs)
  File "plugin.py", line 125, in sendText
    self.stream.write(action.text + EOL[self.eol][0])
  File ".../Server Plugin/asyn/selectable.py", line 268, in write
    self._wbuf += whatever
TypeError: can't concat str to bytes

   Cynical Network Error           in sendText: Traceback (most recent call last):
  File ".../Server Plugin/cyin/debugging.py", line 67, in diagnostic_log
    yield
  File ".../Server Plugin/cyin/debugging.py", line 77, in diagnose_call
    return method(*args, **kwargs)
  File "plugin.py", line 125, in sendText
    self.stream.write(action.text + EOL[self.eol][0])
  File ".../Server Plugin/asyn/selectable.py", line 268, in write
    self._wbuf += whatever
TypeError: can't concat str to bytes

   Cynical Network Error           in sendText: Traceback (most recent call last):
  File ".../Server Plugin/cyin/debugging.py", line 67, in diagnostic_log
    yield
  File ".../Server Plugin/cyin/debugging.py", line 77, in diagnose_call
    return method(*args, **kwargs)
  File "plugin.py", line 125, in sendText
    self.stream.write(action.text + EOL[self.eol][0])
  File ".../Server Plugin/asyn/selectable.py", line 268, in write
    self._wbuf += whatever
TypeError: can't concat str to bytes

--
Korey

Posted on
Fri Jul 08, 2022 12:47 pm
Perry The Cynic offline
Posts: 813
Joined: Apr 07, 2008

Re: Cynical Network 3.0- Error

Try again. We'll beat this thing into submission eventually...

Cheers
-- perry

Posted on
Fri Jul 08, 2022 1:08 pm
Korey offline
User avatar
Posts: 751
Joined: Jun 04, 2008
Location: Henderson, NV

Re: Cynical Network 3.0- Error

Perry The Cynic wrote:
Try again. We'll beat this thing into submission eventually...

Cheers
-- perry


:D :D

V3.1.2 working as it should!

Thanks Perry!

--
Korey

Posted on
Fri Jul 22, 2022 8:13 pm
Vig offline
Posts: 94
Joined: Oct 06, 2015

Re: Cynical Network 3.0- Error

I am getting the error attached when sending a payload to the connected device using version 3.1.2
Attachments
Screen Shot 2022-07-22 at 10.05.22 PM.png
Screen Shot 2022-07-22 at 10.05.22 PM.png (40.99 KiB) Viewed 243 times

Posted on
Sat Aug 06, 2022 9:51 am
Perry The Cynic offline
Posts: 813
Joined: Apr 07, 2008

Re: Cynical Network 3.0- Error

Fixed in 3.1.3.

Strings in Python 3 are subtle and easy to anger... particularly when they have embedded binary bytes. 8)

Cheers
-- perry

Posted on
Sat Aug 06, 2022 10:04 am
Vig offline
Posts: 94
Joined: Oct 06, 2015

Re: Cynical Network 3.0- Error

Awesome, thanks Perry!

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 2 guests