Join GitHub today
Made it possible to define multiple Octoprint printers #16519
The current Octoprint platform supports only one device. I've removed this limitation by making it possible to define multiple printers during configuration.
Breaking change: the configuration of the Octoprint platform needs to be converted to a list.
Successor of #16508
Example entry for
referenced this pull request
Sep 9, 2018
I added a configuration option for octoprint's port.
The default for this component was, and still is, 80 but Octoprint's default is actually 5000.
As I'm guessing 99% of Octoprint users are actually using Octopie, a pre-installed raspberry pi image, that has a reverse proxy redirecting Octoprint's port to 80, it probably wasn't an issue but I wanted to make sure the Octoprint component could actually connect to a vanilla Octoprint installation if needed.
By the way, I noticed that @w1ll1am23 added support in netdisco for auto-discovering Octoprint servers.
This probably will be better in a subsequent PR, but we can combine this along the auto platform loading to have an integration where the servers will be automatically detected and the user will just need to add the API key in the UI to get a working monitoring of their printer.
I'm reading the documentation for the config flow handlers but as I said it should probably be in a second PR.
It's more clear to the user if we fail component setup that there's a problem with the setup. Since no platforms will have loaded, no entities will be created and never will, so I think we should fail component setup in that case. The user will have to fix the problem and restart home assistant to trigger another setup.