-
-
Notifications
You must be signed in to change notification settings - Fork 67
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: power toggle won't work #339
Comments
ok was able to fix the printer online status repeating every 30 secs. Referencing #326, I used kiauh alpha 6 to reinstall. I manually installed via git. So I'm good there, but "/power" function doesn't work unless I'm at my home computer to turn it on. Thanks RC |
ok rolled back to 1.5.0 and now able to power on printer when its off. so using RP 4 with relay to turn on/off printer mainboard via moonraker. |
@cruzer619 |
|
telegram.log |
@cruzer619 |
telegram.log update: just noticing with debug being on.. the power on dialog is showing up sometimes.. but doesn't power on printer. |
also you could add |
ok thanks will update and try again... but will need some sleep.. will try again in about 5 hours.. thanks. |
telegram.log |
FYI I've started to print my ERCF v2 parts. Won't be able to test 'til the following day. UPDATE: able to test whenever ready. |
What happened and in what context?
After upgrading to latest version of telegram-bot when printer is off but pi is still on. Power toggle no longer works. I've tried to uninstall and reinstall. and same result. Also when first starting the printer. And assuming the service starts. Printer online status notification sends every 30 secs. After I stop and restart service it will stop sometimes.
If needed, paste the relevant bot log contents here.
Current Moonraker telegram bot config
[bot]
server = localhost
power_device = Ender5
light_device = LED1
[progress_notification]
percent = 10
2024-12-09 01:38:35,438 - klippy - ERROR - klippy.py:362 - Server error '503 Klippy Host not connected' for url 'http://localhost/printer/info'
For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/503
2024-12-09 01:38:36,455 - klippy - ERROR - klippy.py:362 - Server error '503 Klippy Host not connected' for url 'http://localhost/printer/info'
For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/503
2024-12-09 01:38:37,467 - websocket_helper - WARNING - websocket_helper.py:312 - Error received from websocket: {'code': 503, 'message': 'Klippy Host not connected'}
2024-12-09 01:38:37,472 - klippy - ERROR - klippy.py:362 - Server error '503 Klippy Host not connected' for url 'http://localhost/printer/info'
For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/503
2024-12-09 01:38:38,487 - klippy - ERROR - klippy.py:362 - Server error '503 Klippy Host not connected' for url 'http://localhost/printer/info'
For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/503
2024-12-09 01:38:39,501 - websocket_helper - WARNING - websocket_helper.py:312 - Error received from websocket: {'code': 503, 'message': 'Klippy Host not connected'}
2024-12-09 01:38:39,505 - klippy - ERROR - klippy.py:362 - Server error '503 Klippy Host not connected' for url 'http://localhost/printer/info'
For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/503
2024-12-09 01:38:40,519 - klippy - ERROR - klippy.py:362 - Server error '503 Klippy Host not connected' for url 'http://localhost/printer/info'
For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/503
2024-12-09 01:38:41,536 - websocket_helper - WARNING - websocket_helper.py:312 - Error received from websocket: {'code': 503, 'message': 'Klippy Host not connected'}
2024-12-09 01:38:41,540 - klippy - ERROR - klippy.py:362 - Server error '503 Klippy Host not connected' for url 'http://localhost/printer/info'
For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/503
2024-12-09 01:38:42,562 - klippy - ERROR - klippy.py:362 - Server error '503 Klippy Host not connected' for url 'http://localhost/printer/info'
For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/503
2024-12-09 01:38:43,599 - klippy - ERROR - klippy.py:362 - Server error '503 Klippy Host not connected' for url 'http://localhost/printer/info'
For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/503
2024-12-09 01:38:44,603 - websocket_helper - WARNING - websocket_helper.py:312 - Error received from websocket: {'code': 503, 'message': 'Klippy Host not connected'}
2024-12-09 01:38:44,622 - klippy - ERROR - klippy.py:362 - Server error '503 Klippy Host not connected' for url 'http://localhost/printer/info'
For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/503
2024-12-09 01:38:45,645 - websocket_helper - WARNING - websocket_helper.py:312 - Error received from websocket: {'code': 503, 'message': 'Klippy Host not connected'}
2024-12-09 01:38:46,267 - klippy - ERROR - klippy.py:362 - Server error '503 Klippy Host not connected' for url 'http://localhost/printer/objects/list'
For more information check: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/503
2024-12-09 01:38:47,435 - websocket_helper - WARNING - websocket_helper.py:312 - Error received from websocket: {'code': 503, 'message': 'Klippy Host not connected'}
trunk
2024-12-09 01:48:15,435 - websocket_helper - WARNING - websocket_helper.py:312 - Error received from websocket: {'code': 503, 'message': 'Klippy Host not connected'}
2024-12-09 01:48:17,435 - websocket_helper - WARNING - websocket_helper.py:312 - Error received from websocket: {'code': 503, 'message': 'Klippy Host not connected'}
2024-12-09 01:48:19,437 - websocket_helper - WARNING - websocket_helper.py:312 - Error received from websocket: {'code': 503, 'message': 'Klippy Host not connected'}
2024-12-09 01:48:21,437 - websocket_helper - WARNING - websocket_helper.py:312 - Error received from websocket: {'code': 503, 'message': 'Klippy Host not connected'}
2024-12-09 01:48:22,413 - main - ERROR - main.py:986 - Exception while handling an update:
Traceback (most recent call last):
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpx/_transports/default.py", line 101, in map_httpcore_exceptions
yield
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpx/_transports/default.py", line 394, in handle_async_request
resp = await self._pool.handle_async_request(req)
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpcore/_async/connection_pool.py", line 256, in handle_async_request
raise exc from None
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpcore/_async/connection_pool.py", line 236, in handle_async_request
response = await connection.handle_async_request(
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpcore/_async/connection.py", line 101, in handle_async_request
raise exc
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpcore/_async/connection.py", line 78, in handle_async_request
stream = await self._connect(request)
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpcore/_async/connection.py", line 124, in _connect
stream = await self._network_backend.connect_tcp(**kwargs)
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpcore/_backends/auto.py", line 31, in connect_tcp
return await self._backend.connect_tcp(
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpcore/_backends/anyio.py", line 122, in connect_tcp
stream._raw_socket.setsockopt(*option) # type: ignore[attr-defined] # pragma: no cover
File "/usr/lib/python3.9/contextlib.py", line 135, in exit
self.gen.throw(type, value, traceback)
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpcore/_exceptions.py", line 14, in map_exceptions
raise to_exc(exc) from exc
httpcore.ConnectTimeout
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/telegram/request/_httpxrequest.py", line 293, in do_request
res = await self._client.request(
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpx/_client.py", line 1540, in request
return await self.send(request, auth=auth, follow_redirects=follow_redirects)
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpx/_client.py", line 1629, in send
response = await self._send_handling_auth(
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpx/_client.py", line 1657, in _send_handling_auth
response = await self._send_handling_redirects(
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpx/_client.py", line 1694, in _send_handling_redirects
response = await self._send_single_request(request)
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpx/_client.py", line 1730, in _send_single_request
response = await transport.handle_async_request(request)
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpx/_transports/default.py", line 394, in handle_async_request
resp = await self._pool.handle_async_request(req)
File "/usr/lib/python3.9/contextlib.py", line 135, in exit
self.gen.throw(type, value, traceback)
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/httpx/_transports/default.py", line 118, in map_httpcore_exceptions
raise mapped_exc(message) from exc
httpx.ConnectTimeout
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/telegram/ext/_application.py", line 1319, in process_update
await coroutine
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/telegram/ext/_handlers/basehandler.py", line 158, in handle_update
return await self.callback(update, context)
File "/home/pi/moonraker-telegram-bot/bot/main.py", line 447, in power
await update.effective_message.get_bot().send_chat_action(chat_id=configWrap.secrets.chat_id, action=ChatAction.TYPING)
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/telegram/ext/_extbot.py", line 2520, in send_chat_action
return await super().send_chat_action(
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/telegram/_bot.py", line 3443, in send_chat_action
return await self._post(
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/telegram/_bot.py", line 617, in _post
return await self._do_post(
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/telegram/ext/_extbot.py", line 351, in _do_post
return await super()._do_post(
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/telegram/_bot.py", line 646, in _do_post
result = await request.post(
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/telegram/request/_baserequest.py", line 202, in post
result = await self._request_wrapper(
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/telegram/request/_baserequest.py", line 334, in _request_wrapper
code, payload = await self.do_request(
File "/home/pi/moonraker-telegram-bot-env/lib/python3.9/site-packages/telegram/request/_httpxrequest.py", line 310, in do_request
raise TimedOut from err
telegram.error.TimedOut: Timed out
2024-12-09 01:48:23,440 - websocket_helper - WARNING - websocket_helper.py:312 - Error received from websocket: {'code': 503, 'message': 'Klippy Host not connected'}
trunk
2024-12-09 01:53:49,434 - websocket_helper - WARNING - websocket_helper.py:312 - Error received from websocket: {'code': 503, 'message': 'Klippy Host not connected'}
If needed, paste the relevant bot journal contents here.
No response
What branch does this occur on?
master
Reports only on latest master or development branches!
The text was updated successfully, but these errors were encountered: