Page 3 of 19

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Tue Nov 15, 2016 3:11 pm
by norcoscia
gonzalo.dios - I have that item also - I'm not sure it is a faulty item - if you look in your Matplotlib log folder you will likely find a log file with the name none.csv

Not saying your not on to something - but maybe this is always created as a placeholder - in any case, thanks for the idea - I'll delete it and see if that helps.

I hope to get this working OK - since it will be a great plugin

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Tue Nov 15, 2016 3:21 pm
by norcoscia
Well, you might be on to something - I deleted mine and I could add a second CSV engine device - thanks so so much - I wonder were the None item and log files are coming from?

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Tue Nov 15, 2016 4:20 pm
by gonzalo.dios
That's great!

Now, we only need to know where this "None" item come from...

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Tue Nov 15, 2016 5:12 pm
by DaveL17
You all have been busy, and that's great! There's a couple things here and at least one (if not both of them) are my fault.

@norcoscia: The plugin restart that you saw is something that's been happening periodically with that version of the plugin and I think I've recently isolated the cause. It has to do with the way that the plugin is initialized--the details don't matter--but in my tests of the update, the random restarts seem to have stopped. The restarts can be ignored as they don't affect anything important. That fix will be in the next update.

@gonzalo.dios: Thanks for the note on the "None" data element. That was included so that the CSV Engine device would have dummy data available to construct the device configuration dialog the first time it's run. It's existence shouldn't affect the plugin's operation, but it sounds like it might be nonetheless. I will look at that code to (at a minimum) ignore the "None" entry so in the future a None.csv file will not be created. I'll also see about deleting the "None" record from the list after the first data element is saved (rendering the None element unnecessary) and respawn it in the rare circumstance that all the other elements are removed.

You should be able to delete the None element without issue (as you seem to have figured out on your own--sorry about that!) and will amend the instructions to boot.

Thanks to both of you!

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Tue Nov 15, 2016 11:50 pm
by rapamatic
I keep getting the following error message, about a pickle? Any ideas?

Code: Select all
Nov 15, 2016, 11:43:15 PM
   Reloading plugin "Matplotlib 0.2.00"
   Starting plugin "Matplotlib 0.2.00" (pid 33315)
   Matplotlib Error                Error in plugin execution InitializeMain:

Traceback (most recent call last):
  File "plugin.py", line 31, in <module>
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/pyplot.py", line 24, in <module>
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/colorbar.py", line 29, in <module>
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/collections.py", line 23, in <module>
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/backend_bases.py", line 50, in <module>
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/textpath.py", line 11, in <module>
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/font_manager.py", line 1356, in <module>
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/font_manager.py", line 1341, in _rebuild
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/font_manager.py", line 989, in __init__
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/font_manager.py", line 318, in findSystemFonts
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/matplotlib/font_manager.py", line 274, in get_fontconfig_fonts
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 710, in __init__
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 1334, in _execute_child
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/pickle.py", line 1382, in loads
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/pickle.py", line 858, in load
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/pickle.py", line 966, in load_string
ValueError: insecure string pickle

   Stopping plugin "Matplotlib 0.2.00" (pid 33315)
   Stopped plugin "Matplotlib 0.2.00"



Sent from my iPhone using Tapatalk

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Wed Nov 16, 2016 6:54 am
by DaveL17
rapamatic wrote:
I keep getting the following error message, about a pickle? Any ideas?

Had to research that one a bit as I hadn't seen it before. Your install is crashing when we try to import matplotlib.pyplot. Please try the following steps:

(1) From the Indigo Scripting Shell, please try the following command:
Code: Select all
import matplotlib.pyplot as plt
I suspect that it will generate the same error. Please let me know if that's not the case.

(2) Try rebooting the machine running the Indigo Server.

It seems that there can sometimes be issues with Matplotlib dependencies on Macs that don't generate the proper traceback and instead provide an insecure pickle error. My source; https://github.com/matplotlib/matplotlib/issues/5314/

- Issue #26083: Workaround a subprocess bug that raises an incorrect
"ValueError: insecure string pickle" exception instead of the actual
exception on some platforms such as Mac OS X when an exception raised
in the forked child process prior to the exec() was large enough that
it overflowed the internal errpipe_read pipe buffer.


Several users in that thread suggested that a reboot solved their issue. Please let me know how it goes.

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Wed Nov 16, 2016 7:50 am
by rapamatic
You were right on both counts. A simple reboot fixed my pickle.

Thanks!

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Wed Nov 16, 2016 8:02 am
by DaveL17
rapamatic wrote:
You were right on both counts. A simple reboot fixed my pickle.

Thanks!


Good deal. Thanks for letting me know.

#ThingsThatSoundDirtyButAren't


Sent from my iPhone using Tapatalk

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Wed Nov 16, 2016 10:24 am
by Woetjes
Woetjes wrote:
I have the same problem, when I try to create a CSV for the NetAtmo device (temperature or CO2) , I get the same error messages.
I've created a CSV with a variable and value and that's working.


Hi Dave,

I let the variable run for a day or two and now I've added the temperature for the NetAtmo device in it and it's working - great! :)
I also encountered the 'plugin "Matplotlib 0.2.00" (pid 59433) unexpectedly stopped -- restarting in 5 seconds' error but a simple reload of the plugin fixed it.

Thanks for the great plugin!
Wouter

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Wed Nov 16, 2016 10:27 am
by DaveL17
Thanks Wouter. Glad to hear that things have turned around for you.

There are likely many places where the plugin can be improved so please let me know how you get on.


Sent from my iPhone using Tapatalk

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Tue Nov 22, 2016 2:53 pm
by Frakke
Hi All,

Can someone tell me what I'm doing wrong please?
I'm getting this error, see images.

Thanks!

Regards

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Tue Nov 22, 2016 2:55 pm
by DaveL17
Try deleting the .ui part of the device state.


Sent from my iPhone using Tapatalk

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Tue Nov 22, 2016 2:56 pm
by Frakke
DaveL17 wrote:
Try deleting the .ui part of the device state.


Sent from my iPhone using Tapatalk


Hi,

Still this error:
Matplotlib Error Error in plugin execution runConcurrentThread:

Traceback (most recent call last):
File "plugin.py", line 2247, in runConcurrentThread
File "plugin.py", line 615, in refreshTheCSV
ValueError: invalid literal for int() with base 10: 'None'

Matplotlib Error plugin runConcurrentThread function returned or failed (will attempt again in 10 seconds)

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Tue Nov 22, 2016 4:41 pm
by DaveL17
Sorry that you're still having trouble. Please open a scripting shell (Indigo Plugins Menu), execute the following code, and post the results.

Code: Select all
indigo.server.log(unicode(indigo.devices[402734223].states))

Re: Matplotlib Plugin for Indigo 7 - New!

PostPosted: Wed Nov 23, 2016 5:26 am
by DaveL17
@Frakke: Sorry, it was a long day yesterday.

Do you have a CSV Engine data element called 'None' that appears in the drop-down list? If so, please select and delete that element. Hopefully, that will get you going.

Dave