Octoprint Sensors Read Unavailable when printer is off
See original GitHub issueThe problem
Before OctoPrint was an Integration you could set the tool and the bed this way even if the printer was off you would not receive an “Entity is currently unavailable”
Please can this be fixed.
What version of Home Assistant Core has the issue?
core-2021.11.2
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant OS
Integration causing the issue
No response
Link to integration documentation on our website
https://www.home-assistant.io/integrations/octoprint/
Example YAML snippet
octoprint:
host: 192.168.0.XX
api_key: XXXXXXXXX
name: Ender 3V2
number_of_tools: 1
bed: 1
Anything in the logs that might be useful for us?
No response
Additional information
When it was YAML configured number of tools and bed could be configured as well as the name of the printer
Issue Analytics
- State:
- Created 2 years ago
- Reactions:3
- Comments:15 (3 by maintainers)
Top Results From Across the Web
OctoPrint integration stopped working after 2021.11
OctoPrint is running, “printing” should be “off,” not unavailable. At the very least it always used to be before 2021.11.
Read more >Logs polluted when Octoprint instance is not on - Reddit
And since the octoprint is mostly off, my logs on home assistant is full of these errors that it can't update the sensors;...
Read more >Printer is connected, State is Operational, successfully ...
I tried disconnecting and reconnecting to my printer. I've even backed out of the Octoprint server entirely, rebooted pi, restarted Octopi ...
Read more >Yearly - OctoPrint Community Forum
Enclosure: temperature sensors etc. on Raspberry Pi 4 · Plugins. 2, 77, October 22, 2022. Octoprint server crashes during print - 503 service...
Read more >Software problems when connecting the PI camera - Webcams
PI Camera with ribbon no Picture in Octoprint Camera plugged into ribbon connector, leagecy mode must be off, sudo apt-get install ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@rfleming71: There is a confusion between the state of Octoprint and that of the printer.
Case 1: Printer = off ; Octoprint = reachable Case 2: Octoprint = unreachable
In case 1, we expect sensors to pass on the values from Octoprint. That is “-” and “0” (“Printed: -” ; “Bed temp: 0.0ºC”) and “State: Offline” for the printer itself. The printer is offline, the UI stays pretty 🤗 Awesome, right? 🎉
In case 2, marking printer sensors as unavailable shows “Unavailable” all over the dashboard (3 times in my case). This makes for a poor user experience 😢 Plus, it freaks us out the first time we see this because all sensors are red in the Entities list (unavailable, restored). 😱 😱 😱 What’s wrong with my configuration?!? You get the feeling 😉
I took a quick look at the sensors from the integration. They are all focused on the printer and the print job. How about adding a sensor that would reflect the reachability of Octoprint’s server? Something like “server_current_state” ? States could be “reachable, unreachable, unavailable”. Unavailable would be for when there’s an error with the integration (like all other integrations), “unreachable” for when the integration works but there’s no response from Octoprint, and “reachable” for, well… when we’re riding on awesomeness and everything works 💪🏻 🎉
Thoughts?
I’m finding this an issue myself.
If the OctoPrint server is online and available but the printer is off, I would much rather have the current state as “Offline” or “Disconnected” instead of “Unavailable”. It does not look nice and is quite confusing since “Unavailable” usually implies that the server is offline, which it is not.