Feature Requests

Posted on
Wed Feb 19, 2020 10:28 am
DaveL17 offline
User avatar
Posts: 5909
Joined: Aug 20, 2013
Location: Chicago, IL, USA

Re: Feature Requests

I'm back from my morning commitments and have been able to look at this a little bit more deeply. There may indeed be a bug in the GhostXML code -- it looks like the plugin may be appending '_ui' to the hidden states each time it cycles (the user interface states [*.ui] are hidden in the Indigo UI) and, if that's the case, it should be a fairly easy fix.

I'm surprised it's taken this long to surface! I will try to dig into this today.

I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]

Posted on
Wed Feb 19, 2020 10:40 am
Umtauscher offline
User avatar
Posts: 552
Joined: Oct 03, 2014
Location: Cologne, Germany

Re: Feature Requests

Thanks Dave,

if this is the problem, I understand why restarting the plugin fixes it temporarily.
I will gladly wait for a fix.
Cheers
Wilhelm

Posted on
Wed Feb 19, 2020 10:54 am
RogueProeliator offline
User avatar
Posts: 2437
Joined: Nov 13, 2012
Location: Baton Rouge, LA

Re: Feature Requests

I'm back from my morning commitments and have been able to look at this a little bit more deeply. There may indeed be a bug in the GhostXML code -- it looks like the plugin may be appending '_ui' to the hidden states each time it cycles (the user interface states [*.ui] are hidden in the Indigo UI) and, if that's the case, it should be a fairly easy fix.

Well, that will do it and fits with the continuous appending in a loop. Users can always drop the table and the SQL Logger plugin should recreate it if restarted.

Posted on
Wed Feb 19, 2020 1:32 pm
DaveL17 offline
User avatar
Posts: 5909
Joined: Aug 20, 2013
Location: Chicago, IL, USA

Re: Feature Requests

Wilhelm - I haven't been able to recreate the problem you're seeing from the standpoint of the plugin. I've tried:

  • XML and JSON
  • letting the plugin run on its own
  • introducing JSON and XML nodes that include 'ui' and '.ui' where possible
  • stopping and restarting the plugin multiple times
  • cycling device communication (turning comm status on/off/on)
It appears that the trouble state is called 'deviceisonline' which isn't a GhostXML native state (that's 'DeviceIsOnline') so the problem state seems to be external to the plugin. I even tried recreating that state in source data and that didn't cause a problem for me.

I'm sorry, but I just can't seem to replicate the trouble you're having. You may want to try deleting and recreating the device so that the SQL Logger will also be reset for that data and see if the problem persists..

I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]

Posted on
Wed Feb 19, 2020 2:01 pm
Umtauscher offline
User avatar
Posts: 552
Joined: Oct 03, 2014
Location: Cologne, Germany

Re: Feature Requests

Just a thought:
As SQL is not case sensitiv, I don‘t see a difference between DeviceIsOnline an deviceisonline..
When a state is stored in the sql database, this would cause a conflict if both were stored in the same device-table.

Recreating 15 GhostXML devices would cause a great deal of work, because all actiongroups and triggers would become invalid then.
So I will avoid it at the moment.

Posted on
Wed Feb 19, 2020 3:00 pm
DaveL17 offline
User avatar
Posts: 5909
Joined: Aug 20, 2013
Location: Chicago, IL, USA

Re: Feature Requests

I wasn't aware you were having trouble with 15 devices--I assumed it was just the one. I'll add a note to the to-do list to add a trap for instances where the source data contains nodes with the same names as the default device states (IIRC, there are only 4 of those).

My (very limited) understanding is that case sensitivity in SQL is optional. Databases can have this feature enabled/disabled. I'm not sure how Indigo has it configured.

I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]

Posted on
Wed Feb 19, 2020 3:39 pm
Umtauscher offline
User avatar
Posts: 552
Joined: Oct 03, 2014
Location: Cologne, Germany

Re: Feature Requests

As I understand it, at least in Mysql it depends on the character set the table column is defined with, the one containing CI are case insensitive and the ones containing CS are case sensitive.
You are right, there is a default for the database, but you can change that for each table column individually.

If your theory about adding columns with each request, I suppose the plugin has to run for at least 200 circles for a error message to occur.
I suspect the problem to happen, when the SqlLogger Plugin is startet after that.

Posted on
Wed Feb 19, 2020 3:45 pm
Umtauscher offline
User avatar
Posts: 552
Joined: Oct 03, 2014
Location: Cologne, Germany

Re: Feature Requests

I spoke too soon, The character set concerns the data of the columns, not the column names in the table definition.
I think those are always case insensitive.

Posted on
Wed Feb 19, 2020 3:54 pm
DaveL17 offline
User avatar
Posts: 5909
Joined: Aug 20, 2013
Location: Chicago, IL, USA

Re: Feature Requests

If your theory about adding columns with each request, I suppose the plugin has to run for at least 200 circles for a error message to occur.
I suspect the problem to happen, when the SqlLogger Plugin is startet after that.

If that flows through, the state name would need to grow longer in order to eventually create a problem. In my tests, the length of the UI state didn't change. Not saying yours didn't, but as I said above, I wasn't able to recreate it.

I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]

Posted on
Wed Feb 19, 2020 4:15 pm
Umtauscher offline
User avatar
Posts: 552
Joined: Oct 03, 2014
Location: Cologne, Germany

Re: Feature Requests

I have some more findings and now can reproduce the problem:

1. All column names in the sql tables are lowercase
2. every colum in the tables has an additional column named column_ui (That reduces the number of possible custom staes by half, I think 125)
3. With every timeout a GhostXML device encounters, all states in that device are internally duplicated which leads to duplicated columns in the database once you restart the sqllogger plugin.

So after a timeout occurs, if you start the sqlloger again it refreshes the tables for the devices the missing stes are added to the tables. Since the number of states doubles after each timeout, the maximun number of columns i reached pretty fast.

As you can see, when the device is running long enough, the number of columns goes into the thousands.
This is a memory leak in the first place since the memory is eaten up by variables in the long run and secondly crashes the sqllogger as soon as it tries to add all the states to the database tables.
This also happpens with 0.4.36 as well.

Cheers
Wilhelm

Posted on
Wed Feb 19, 2020 4:42 pm
Umtauscher offline
User avatar
Posts: 552
Joined: Oct 03, 2014
Location: Cologne, Germany

Re: Feature Requests

I added a dump of the device's table after the first timeout.
Attachments
898683237.log
(57.78 KiB) Downloaded 37 times

Posted on
Wed Feb 19, 2020 5:50 pm
DaveL17 offline
User avatar
Posts: 5909
Joined: Aug 20, 2013
Location: Chicago, IL, USA

Re: Feature Requests

1. All column names in the sql tables are lowercase

To determine if it's a GhostXML issue, we need to take the SQL Logger out of the equation for the moment.

2. every colum in the tables has an additional column named column_ui (That reduces the number of possible custom staes by half, I think 125)

Yes, the plugin creates two states for each node/attribute. The state value and the state.ui value.

3. With every timeout a GhostXML device encounters, all states in that device are internally duplicated which leads to duplicated columns in the database once you restart the sqllogger plugin.


You're saying that with each GhostXML device timeout, the number of states within the plugin device increases? What would be helpful is data from the GhostXML device itself showing the state names. When the problem occurs, it would be helpful if you would print out a copy of the device dict using this Python code (revised for your device ID):

Code: Select all
dev=indigo.devices[12345678]
indigo.server.log(unicode(dev.states))

I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]

Posted on
Thu Feb 20, 2020 4:08 am
Umtauscher offline
User avatar
Posts: 552
Joined: Oct 03, 2014
Location: Cologne, Germany

Re: Feature Requests

Hi Dave,

Ok, this is the normal dev output
Code: Select all
Interactive Shell               States : (dict)
     deviceIsOnline : true (bool)
     deviceIsOnline.ui : Updated (string)
     deviceLastUpdated : 02/20/2020 at 10:59 (string)
     deviceTimestamp : 1582192757.728893 (real)
     disable_flags : 0 (string)
     disable_flags.ui : 0 (string)
     distribution_enable : True (string)
     distribution_enable.ui : True (string)
     equalizer_high : 9 (string)
     equalizer_high.ui : 9 (string)
     equalizer_low : 0 (string)
     equalizer_low.ui : 0 (string)
     equalizer_mid : -2 (string)
     equalizer_mid.ui : -2 (string)
     equalizer_mode : manual (string)
     equalizer_mode.ui : manual (string)
     input : net_radio (string)
     input.ui : net_radio (string)
     link_audio_quality : uncompressed (string)
     link_audio_quality.ui : uncompressed (string)
     link_control : standard (string)
     link_control.ui : standard (string)
     max_volume : 60 (string)
     max_volume.ui : 60 (string)
     mute : False (string)
     mute.ui : False (string)
     parse_error : false (bool)
     power : standby (string)
     power.ui : standby (string)
     response_code : 0 (string)
     response_code.ui : 0 (string)
     sleep : 0 (string)
     sleep.ui : 0 (string)
     volume : 21 (string)
     volume.ui : 21 (string)
   


and this is during a timeout. (I unplugged the network device)
Code: Select all
Interactive Shell               States : (dict)
     deviceIsOnline : false (bool)
     deviceIsOnline.ui : Error (string)
     deviceIsOnline.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui.ui.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui.ui.ui.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui.ui.ui.ui.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui.ui.ui.ui.ui.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : Processing (string)
     deviceIsOnline.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : Processing (string)
     deviceLastUpdated : 02/20/2020 at 11:01 (string)
     deviceLastUpdated.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui.ui.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui.ui.ui.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui.ui.ui.ui.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceLastUpdated.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 02/19/2020 at 23:03 (string)
     deviceTimestamp : 1582192906.99 (string)
     deviceTimestamp.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui.ui.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui.ui.ui.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui.ui.ui.ui.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui.ui.ui.ui.ui.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 1582149793.1 (string)
     deviceTimestamp.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 1582149793.1 (string)
     disable_flags : 0 (string)
     disable_flags.ui : 0 (string)
     disable_flags.ui.ui : 0 (string)
     disable_flags.ui.ui.ui : 0 (string)
     disable_flags.ui.ui.ui.ui : 0 (string)
     disable_flags.ui.ui.ui.ui.ui : 0 (string)
     disable_flags.ui.ui.ui.ui.ui.ui : 0 (string)
     disable_flags.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     disable_flags.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     disable_flags.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     disable_flags.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     disable_flags.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     disable_flags.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     disable_flags.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     disable_flags.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     disable_flags.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     disable_flags.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     distribution_enable : True (string)
     distribution_enable.ui : True (string)
     distribution_enable.ui.ui : True (string)
     distribution_enable.ui.ui.ui : True (string)
     distribution_enable.ui.ui.ui.ui : True (string)
     distribution_enable.ui.ui.ui.ui.ui : True (string)
     distribution_enable.ui.ui.ui.ui.ui.ui : True (string)
     distribution_enable.ui.ui.ui.ui.ui.ui.ui : True (string)
     distribution_enable.ui.ui.ui.ui.ui.ui.ui.ui : True (string)
     distribution_enable.ui.ui.ui.ui.ui.ui.ui.ui.ui : True (string)
     distribution_enable.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : True (string)
     distribution_enable.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : True (string)
     distribution_enable.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : True (string)
     distribution_enable.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : True (string)
     distribution_enable.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : True (string)
     distribution_enable.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : True (string)
     distribution_enable.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : True (string)
     equalizer_high : 9 (string)
     equalizer_high.ui : 9 (string)
     equalizer_high.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui.ui.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui.ui.ui.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui.ui.ui.ui.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui.ui.ui.ui.ui.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 9 (string)
     equalizer_high.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 9 (string)
     equalizer_low : 0 (string)
     equalizer_low.ui : 0 (string)
     equalizer_low.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui.ui.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     equalizer_low.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : 0 (string)
     equalizer_mid : -2 (string)
     equalizer_mid.ui : -2 (string)
     equalizer_mid.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui.ui.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui.ui.ui.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui.ui.ui.ui.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui.ui.ui.ui.ui.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : -2 (string)
     equalizer_mid.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : -2 (string)
     equalizer_mode : manual (string)
     equalizer_mode.ui : manual (string)
     equalizer_mode.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui.ui.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui.ui.ui.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui.ui.ui.ui.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui.ui.ui.ui.ui.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : manual (string)
     equalizer_mode.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : manual (string)
     input : net_radio (string)
     input.ui : net_radio (string)
     input.ui.ui : net_radio (string)
     input.ui.ui.ui : net_radio (string)
     input.ui.ui.ui.ui : net_radio (string)
     input.ui.ui.ui.ui.ui : net_radio (string)
     input.ui.ui.ui.ui.ui.ui : net_radio (string)
     input.ui.ui.ui.ui.ui.ui.ui : net_radio (string)
     input.ui.ui.ui.ui.ui.ui.ui.ui : net_radio (string)
     input.ui.ui.ui.ui.ui.ui.ui.ui.ui : net_radio (string)
     input.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : net_radio (string)
     input.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : net_radio (string)
     input.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : net_radio (string)
     input.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : net_radio (string)
     input.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : net_radio (string)
     input.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : net_radio (string)
     input.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui.ui : net_radio (string)
     link_audio_quality : uncompressed (string)
     link_audio_quality.ui : uncompressed (string)
   

I cut this, it just repeats for every state.
After the network is online again, the additional states vanish and return to normal.

During that timeout state, the sqllogger enters the additional state columns into the database.
Code: Select all
 SQL Logger                      adding column "deviceisonline_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "devicelastupdated_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "devicetimestamp_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "disable_flags_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "distribution_enable_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "equalizer_high_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "equalizer_low_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "equalizer_mid_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "equalizer_mode_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "input_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "link_audio_quality_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "link_control_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "max_volume_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "mute_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "parse_error_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "power_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "response_code_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "sleep_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "volume_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "deviceisonline_ui_ui_ui" to table device_history_898683237 ("wx030-4")
   SQL Logger                      adding column "devicelastupdated_ui_ui" to table device_history_898683237 ("wx030-4")

Posted on
Thu Feb 20, 2020 6:12 am
DaveL17 offline
User avatar
Posts: 5909
Joined: Aug 20, 2013
Location: Chicago, IL, USA

Re: Feature Requests

Thanks Wilhelm, that's very helpful. Does the plugin write any error messages to the log when this happens? Please check both the Indigo log as well as the private log located at:
Code: Select all
/Library/Application Support/Perceptive Automation/Indigo 7.4/Logs/com.fogbert.indigoplugin.GhostXML/plugin.log

I'll have to take an in-depth look at the timeout and error handling code to see if I can spot anything. This may take some time because I'm unable to duplicate your timeout experience as you know.

I came here to drink milk and kick ass....and I've just finished my milk.

[My Plugins] - [My Forums]

Posted on
Thu Feb 20, 2020 6:35 am
Umtauscher offline
User avatar
Posts: 552
Joined: Oct 03, 2014
Location: Cologne, Germany

Re: Feature Requests

Here is the requested log snippet.
Code: Select all
* Curl_addHandleToPipeline: length: 1
* - Conn 0 (0x7fb04480aa00) send_pipe: 1, recv_pipe: 0
* About to connect() to wx030-4.voyager95.de port 80 (#0)
*   Trying 192.168.1.214...

2020-02-20 13:26:25.536   DEBUG        Plugin.get_the_data                 ReturnCode: -9
2020-02-20 13:26:25.536   WARNING      Plugin.get_the_data                 [wx030-4] curl error * Adding handle: conn: 0x7fb04480aa00 * Adding handle: send: 0 * Adding handle: recv: 0 * Curl_addHandleToPipeline: length: 1 * - Conn 0 (0x7fb04480aa00) send_pipe: 1, recv_pipe: 0 * About to connect() to wx030-4.voyager95.de port 80 (#0) *   Trying 192.168.1.214... . [Return code: -9
2020-02-20 13:26:25.537   DEBUG        Plugin.parse_the_json               [wx030-4] Parse Error: No JSON object could be decoded
2020-02-20 13:26:25.537   DEBUG        Plugin.parse_the_json               [wx030-4] jsonRawData {u'link_control.ui.ui': u'standard', u'equalizer_low.ui': u'0', u'deviceLastUpdated': u'02/20/2020 at 13:26', u'disable_flags.ui.ui': u'0', u'mute': u'False', u'max_volume.ui.ui': u'60', u'equalizer_low.ui.ui.ui': u'0', u'equalizer_mode.ui.ui': u'manual', u'deviceTimestamp': 1582201563.503124, u'input.ui': u'net_radio', u'link_audio_quality.ui.ui': u'uncompressed', u'distribution_enable': u'True', u'disable_flags.ui': u'0', u'response_code.ui': u'0', u'sleep.ui.ui': u'0', u'response_code.ui.ui.ui': u'0', u'mute.ui.ui.ui': u'False', u'parse_error': True, u'equalizer_low.ui.ui': u'0', u'link_audio_quality': u'uncompressed', u'power.ui': u'standby', u'deviceTimestamp.ui.ui': u'1582149793.1', u'deviceIsOnline.ui': u'Processing', u'deviceIsOnline.ui.ui.ui': u'Processing', u'disable_flags': u'0', u'distribution_enable.ui.ui': u'True', u'equalizer_mid': u'-2', u'sleep.ui': u'0', u'equalizer_mode.ui.ui.ui': u'manual', u'disable_flags.ui.ui.ui': u'0', u'volume.ui': u'21', u'equalizer_low': u'0', u'response_code.ui.ui': u'0', u'input': u'net_radio', u'volume.ui.ui': u'21', u'equalizer_high.ui': u'9', u'mute.ui.ui': u'False', u'equalizer_high.ui.ui.ui': u'9', u'deviceTimestamp.ui.ui.ui': u'1582149793.1', u'link_control.ui.ui.ui': u'standard', u'link_audio_quality.ui': u'uncompressed', u'power': u'standby', u'link_control.ui': u'standard', u'parse_error.ui.ui.ui': u'True', u'equalizer_mode.ui': u'manual', u'link_audio_quality.ui.ui.ui': u'uncompressed', u'deviceIsOnline.ui.ui': u'Processing', u'deviceLastUpdated.ui.ui': u'02/19/2020 at 23:03', u'equalizer_mode': u'manual', u'volume.ui.ui.ui': u'21', u'input.ui.ui.ui': u'net_radio', u'equalizer_high.ui.ui': u'9', u'distribution_enable.ui.ui.ui': u'True', u'deviceIsOnline': False, u'power.ui.ui.ui': u'standby', u'link_control': u'standard', u'volume': u'21', u'max_volume': u'60', u'equalizer_high': u'9', u'deviceTimestamp.ui': u'1582149793.1', u'response_code': u'0', u'parse_error.ui.ui': u'True', u'deviceLastUpdated.ui': u'02/19/2020 at 23:03', u'mute.ui': u'False', u'sleep.ui.ui.ui': u'0', u'max_volume.ui': u'60', u'distribution_enable.ui': u'True', u'equalizer_mid.ui.ui.ui': u'-2', u'parse_error.ui': u'True', u'input.ui.ui': u'net_radio', u'equalizer_mid.ui.ui': u'-2', u'sleep': u'0', u'deviceLastUpdated.ui.ui.ui': u'02/19/2020 at 23:03', u'power.ui.ui': u'standby', u'max_volume.ui.ui.ui': u'60', u'equalizer_mid.ui': u'-2'}
2020-02-20 13:26:25.537   WARNING      Plugin.parse_the_json               There was a parse error. Will continue to poll.
2020-02-20 13:26:25.632   DEBUG        Plugin.get_the_data                 HTTPS CURL result: * Adding handle: conn: 0x7fa02b019800
* Adding handle: send: 0
* Adding handle: recv: 0
* Curl_addHandleToPipeline: length: 1
* - Conn 0 (0x7fa02b019800) send_pipe: 1, recv_pipe: 0
* About to connect() to wx030-4.voyager95.de port 80 (#0)
*   Trying 192.168.1.214...
* Failed to connect to 192.168.1.214: No route to host
* couldn't connect to host at wx030-4.voyager95.de:80
* Closing connection 0

2020-02-20 13:26:25.633   DEBUG        Plugin.get_the_data                 ReturnCode: 7
2020-02-20 13:26:25.633   WARNING      Plugin.get_the_data                 [wx030-4] curl error * Adding handle: conn: 0x7fa02b019800 * Adding handle: send: 0 * Adding handle: recv: 0 * Curl_addHandleToPipeline: length: 1 * - Conn 0 (0x7fa02b019800) send_pipe: 1, recv_pipe: 0 * About to connect() to wx030-4.voyager95.de port 80 (#0) *   Trying 192.168.1.214... * Failed to connect to 192.168.1.214: No route to host * couldn't connect to host at wx030-4.voyager95.de:80 * Closing connection 0 . [Return code: 7
2020-02-20 13:26:25.634   DEBUG        Plugin.parse_the_json               [wx030-4] Parse Error: No JSON object could be decoded
2020-02-20 13:26:25.635   DEBUG        Plugin.parse_the_json               [wx030-4] jsonRawData {u'equalizer_low.ui': u'0', u'equalizer_mode.ui.ui': u'manual', u'disable_flags.ui.ui': u'0', u'mute': u'False', u'input.ui': u'net_radio', u'sleep': u'0', u'mute.ui.ui.ui': u'False', u'parse_error': True, u'link_audio_quality': u'uncompressed', u'mute.ui.ui.ui.ui': u'False', u'equalizer_mode.ui.ui.ui': u'manual', u'distribution_enable.ui': u'True', u'input': u'net_radio', u'mute.ui.ui': u'False', u'parse_error.ui.ui': u'True', u'link_audio_quality.ui': u'uncompressed', u'link_audio_quality.ui.ui.ui': u'uncompressed', u'deviceLastUpdated.ui.ui': u'02/19/2020 at 23:03', u'equalizer_high': u'9', u'equalizer_mid.ui.ui.ui': u'-2', u'distribution_enable.ui.ui.ui': u'True', u'link_control': u'standard', u'parse_error.ui': u'True', u'mute.ui': u'False', u'input.ui.ui': u'net_radio', u'distribution_enable': u'True', u'sleep.ui': u'0', u'link_control.ui.ui.ui': u'standard', u'response_code.ui.ui.ui': u'0', u'equalizer_low.ui.ui': u'0', u'response_code.ui.ui.ui.ui': u'0', u'disable_flags.ui.ui.ui.ui': u'0', u'link_audio_quality.ui.ui.ui.ui': u'uncompressed', u'input.ui.ui.ui.ui': u'net_radio', u'disable_flags.ui.ui.ui': u'0', u'equalizer_low': u'0', u'response_code.ui.ui': u'0', u'equalizer_high.ui': u'9', u'equalizer_high.ui.ui.ui': u'9', u'power': u'standby', u'parse_error.ui.ui.ui': u'True', u'equalizer_mode.ui': u'manual', u'link_control.ui': u'standard', u'input.ui.ui.ui': u'net_radio', u'distribution_enable.ui.ui.ui.ui': u'True', u'max_volume': u'60', u'equalizer_mid.ui.ui.ui.ui': u'-2', u'power.ui.ui.ui.ui': u'standby', u'equalizer_mid.ui.ui': u'-2', u'power.ui.ui': u'standby', u'deviceLastUpdated.ui.ui.ui': u'02/19/2020 at 23:03', u'deviceLastUpdated': u'02/20/2020 at 13:26', u'max_volume.ui.ui': u'60', u'link_audio_quality.ui.ui': u'uncompressed', u'disable_flags.ui': u'0', u'response_code.ui': u'0', u'deviceLastUpdated.ui.ui.ui.ui': u'02/19/2020 at 23:03', u'deviceTimestamp.ui.ui': u'1582149793.1', u'deviceIsOnline.ui': u'Processing', u'distribution_enable.ui.ui': u'True', u'equalizer_low.ui.ui.ui.ui': u'0', u'volume.ui.ui': u'21', u'sleep.ui.ui.ui': u'0', u'deviceTimestamp.ui.ui.ui': u'1582149793.1', u'volume': u'21', u'volume.ui.ui.ui': u'21', u'deviceTimestamp': 1582201585.536815, u'power.ui.ui.ui': u'standby', u'response_code': u'0', u'disable_flags': u'0', u'link_control.ui.ui': u'standard', u'volume.ui.ui.ui.ui': u'21', u'parse_error.ui.ui.ui.ui': u'True', u'sleep.ui.ui.ui.ui': u'0', u'equalizer_low.ui.ui.ui': u'0', u'deviceTimestamp.ui.ui.ui.ui': u'1582149793.1', u'equalizer_high.ui.ui.ui.ui': u'9', u'sleep.ui.ui': u'0', u'power.ui': u'standby', u'deviceIsOnline.ui.ui.ui': u'Processing', u'equalizer_mid': u'-2', u'deviceIsOnline.ui.ui.ui.ui': u'Processing', u'equalizer_mode': u'manual', u'link_control.ui.ui.ui.ui': u'standard', u'deviceIsOnline.ui.ui': u'Processing', u'equalizer_mid.ui': u'-2', u'equalizer_high.ui.ui': u'9', u'deviceIsOnline': False, u'max_volume.ui.ui.ui.ui': u'60', u'deviceTimestamp.ui': u'1582149793.1', u'max_volume.ui.ui.ui': u'60', u'equalizer_mode.ui.ui.ui.ui': u'manual', u'deviceLastUpdated.ui': u'02/19/2020 at 23:03', u'max_volume.ui': u'60', u'volume.ui': u'21'}
2020-02-20 13:26:25.635   WARNING      Plugin.parse_the_json               There was a parse error. Will continue to poll.
2020-02-20 13:26:25.732   DEBUG        Plugin.get_the_data                 HTTPS CURL result: * About to connect() to wx030-4.voyager95.de port 80 (#0)
*   Trying 192.168.1.214...
* Failed to connect to 192.168.1.214: Host is down
* couldn't connect to host at wx030-4.voyager95.de:80
* Closing connection 0

2020-02-20 13:26:25.733   DEBUG        Plugin.get_the_data                 ReturnCode: 7
2020-02-20 13:26:25.733   WARNING      Plugin.get_the_data                 [wx030-4] curl error * About to connect() to wx030-4.voyager95.de port 80 (#0) *   Trying 192.168.1.214... * Failed to connect to 192.168.1.214: Host is down * couldn't connect to host at wx030-4.voyager95.de:80 * Closing connection 0 . [Return code: 7
2020-02-20 13:26:25.734   DEBUG        Plugin.parse_the_json               [wx030-4] Parse Error: No JSON object could be decoded
2020-02-20 13:26:25.735   DEBUG        Plugin.parse_the_json               [wx030-4] jsonRawData {u'equalizer_low.ui': u'0', u'equalizer_mode.ui.ui': u'manual', u'disable_flags.ui.ui': u'0', u'mute': u'False', u'input.ui': u'net_radio', u'sleep': u'0', u'mute.ui.ui.ui': u'False', u'parse_error': True, u'link_audio_quality': u'uncompressed', u'deviceIsOnline.ui.ui.ui.ui.ui': u'Processing', u'mute.ui.ui.ui.ui': u'False', u'equalizer_mode.ui.ui.ui': u'manual', u'distribution_enable.ui': u'True', u'input': u'net_radio', u'mute.ui.ui': u'False', u'deviceLastUpdated.ui.ui.ui.ui.ui': u'02/19/2020 at 23:03', u'parse_error.ui.ui': u'True', u'link_audio_quality.ui': u'uncompressed', u'equalizer_high.ui.ui.ui.ui.ui': u'9', u'link_audio_quality.ui.ui.ui': u'uncompressed', u'deviceLastUpdated.ui.ui': u'02/19/2020 at 23:03', u'equalizer_high': u'9', u'equalizer_mid.ui.ui.ui': u'-2', u'distribution_enable.ui.ui.ui': u'True', u'link_control': u'standard', u'parse_error.ui': u'True', u'mute.ui': u'False', u'input.ui.ui': u'net_radio', u'link_audio_quality.ui.ui.ui.ui.ui': u'uncompressed', u'mute.ui.ui.ui.ui.ui': u'False', u'distribution_enable': u'True', u'parse_error.ui.ui.ui.ui.ui': u'True', u'sleep.ui': u'0', u'link_control.ui.ui.ui': u'standard', u'response_code.ui.ui.ui': u'0', u'equalizer_low.ui.ui': u'0', u'deviceTimestamp.ui.ui.ui.ui.ui': u'1582149793.1', u'response_code.ui.ui.ui.ui': u'0', u'disable_flags.ui.ui.ui.ui': u'0', u'link_audio_quality.ui.ui.ui.ui': u'uncompressed', u'input.ui.ui.ui.ui': u'net_radio', u'volume.ui.ui.ui.ui.ui': u'21', u'disable_flags.ui.ui.ui': u'0', u'equalizer_low': u'0', u'response_code.ui.ui': u'0', u'equalizer_high.ui': u'9', u'equalizer_high.ui.ui.ui': u'9', u'power.ui.ui.ui.ui.ui': u'standby', u'power': u'standby', u'parse_error.ui.ui.ui': u'True', u'equalizer_mode.ui': u'manual', u'link_control.ui': u'standard', u'input.ui.ui.ui': u'net_radio', u'disable_flags.ui.ui.ui.ui.ui': u'0', u'deviceIsOnline.ui.ui': u'Processing', u'max_volume': u'60', u'equalizer_mid.ui.ui.ui.ui': u'-2', u'power.ui.ui.ui.ui': u'standby', u'equalizer_mid.ui.ui': u'-2', u'max_volume.ui.ui.ui.ui.ui': u'60', u'deviceLastUpdated.ui.ui.ui': u'02/19/2020 at 23:03', u'deviceLastUpdated': u'02/20/2020 at 13:26', u'max_volume.ui.ui': u'60', u'link_audio_quality.ui.ui': u'uncompressed', u'disable_flags.ui': u'0', u'response_code.ui': u'0', u'deviceLastUpdated.ui.ui.ui.ui': u'02/19/2020 at 23:03', u'equalizer_low.ui.ui.ui.ui.ui': u'0', u'deviceTimestamp.ui.ui': u'1582149793.1', u'deviceIsOnline.ui': u'Processing', u'distribution_enable.ui.ui': u'True', u'equalizer_low.ui.ui.ui.ui': u'0', u'volume.ui.ui': u'21', u'sleep.ui.ui.ui': u'0', u'deviceTimestamp.ui.ui.ui': u'1582149793.1', u'link_control.ui.ui.ui.ui.ui': u'standard', u'volume': u'21', u'equalizer_mid.ui.ui.ui.ui.ui': u'-2', u'volume.ui.ui.ui': u'21', u'deviceTimestamp': 1582201585.633852, u'power.ui.ui.ui': u'standby', u'response_code': u'0', u'sleep.ui.ui.ui.ui.ui': u'0', u'disable_flags': u'0', u'link_control.ui.ui': u'standard', u'volume.ui.ui.ui.ui': u'21', u'parse_error.ui.ui.ui.ui': u'True', u'equalizer_mode.ui.ui.ui.ui.ui': u'manual', u'sleep.ui.ui.ui.ui': u'0', u'equalizer_low.ui.ui.ui': u'0', u'input.ui.ui.ui.ui.ui': u'net_radio', u'deviceTimestamp.ui.ui.ui.ui': u'1582149793.1', u'equalizer_high.ui.ui.ui.ui': u'9', u'response_code.ui.ui.ui.ui.ui': u'0', u'sleep.ui.ui': u'0', u'power.ui': u'standby', u'deviceIsOnline.ui.ui.ui': u'Processing', u'equalizer_mid': u'-2', u'deviceIsOnline.ui.ui.ui.ui': u'Processing', u'equalizer_mode': u'manual', u'distribution_enable.ui.ui.ui.ui.ui': u'True', u'link_control.ui.ui.ui.ui': u'standard', u'distribution_enable.ui.ui.ui.ui': u'True', u'equalizer_mid.ui': u'-2', u'equalizer_high.ui.ui': u'9', u'deviceIsOnline': False, u'max_volume.ui.ui.ui.ui': u'60', u'deviceTimestamp.ui': u'1582149793.1', u'power.ui.ui': u'standby', u'max_volume.ui.ui.ui': u'60', u'equalizer_mode.ui.ui.ui.ui': u'manual', u'deviceLastUpdated.ui': u'02/19/2020 at 23:03', u'max_volume.ui': u'60', u'volume.ui': u'21'}
2020-02-20 13:26:25.735   WARNING      Plugin.parse_the_json               There was a parse error. Will continue to poll.
2020-02-20 13:26:28.172   DEBUG        Plugin.get_the_data                 HTTPS CURL result: * Adding handle: conn: 0x7f9b8a81b400
* Adding handle: send: 0
* Adding handle: recv: 0


to replicate it:
Just disconnect the device GhostXML queries.
You should not have any problems replicating it - or simply unplug the network cable from your Mac until the timeout occurs
Cheers
Wilhelm

Who is online

Users browsing this forum: No registered users and 2 guests

cron