Should pip be upgraded?

You are using pip version 9.0.3, however version 19.0.3 is available.

You should consider upgrading via the 'pip install --upgrade pip' command.

Should I do this?


1 Like

There's an issue regarding this, btw.

@OutsourcedGuru Thanks for the issue pointer. I just added my two-cents worth.

How's your plugin coming along? I've seen you on the forums and git issue pages, and am very glad to see you getting into plugin development!

@FormerLurker Check it out! Feedback welcome!

Nice! Very nice for your first plugin in fact. Better than my first attempt.

I do have one bit of feedback. I nonticed that you seem to be using windows IO redirection in your system commands, so I looked the code a bit. I see that you are using os.system to execute the command. I believe this is similar to subprocess.popen when shell=true. This can be a security risk. It would be better to pass arguments into your script, then use those arguments within your scripts if you need them. This prevents one from executing arbitrary commands.

You might consider switching to subprocess.popen (with shell=false). You can get any errors or standard output within python using stdout and stderr like so:

subprocess.Popen(args, stdout=subprocess.PIPE, stderr=subprocess.PIPE)

Sarge might work too, but I haven't used that yet.

Once again, nice work!

1 Like

I seem to recall demoting my calls to self._logger.debug() calls when I'm ready to go to production rather than just commenting them out. If an enduser later has troubles you could have them change the OctoPrint logging level and provide you more feedback from a distance. You just want to not log sensitive data, though.