VS Code as an OctoPrint IDE?

Hi Folks,

I've finally decided it time to "dip my toe in the water" and attempt to write a simple plugin to integrate a UPS with OctoPrint (using apcupsd) to park and power off the printer in the event of power failure (overhead power lines + lots of trees = power cuts).

I found and read the Developer Docs but, other than the fact that they seem "a little out of date" I got the distinct impression that I would be re-inventing the wheel (no pun intended) because I already have VS Code and Python installed on my Windows 10 machine to fiddle with Fusion 360 Add-In's, and Platform IO integration for Marlin and a BTT-TFT35-E3-V3.0.

So, before I dig a hole and bury myself, is this a viable option? Is anyone else already doing this or am I wasting my time?

Many thanks for any advice and pointers!

Andy B.

I use vscode as an ide for my plugin. Works great.
Set up a couple of virtualenvs (for python 2.7 and 3) and you're golden.

Thanks for that, one quick question did you go with the VS Code Python extensions or did you use the "standard" Python for Windows installers?

Who says he's using windows at all :wink:

I certainly didn't, but I did mention I was... :grin:

Ummm... he did...

A

You're referring to the wrong post :wink: @cnyper

I'm on a mac, I used the built in 2.7 and installed the 3.7 packages from python).

VS code is configured to recognise my virtualenvs directory, and I use pylint and black for linting and formatting.

Thank you!

Sorry to weigh in on this post, but I am curious about the details of how you manage the plugins with VS Code in this situation?

I am interested in the ability to debug while playing around with (mostly other people's) plugins, and I am also trying to dip my toe in the water here as a very inexperienced dev.

I have successfully gotten VS code to run an octoprint server (remotely on a raspberry pi) - but I am not sure how to manage a plugin in this application. If you have any tips or tricks I would love to hear them!

Thanks!