Skip to content
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] Autotune crashes Klipper when Moonraker Timelapse is enabled #180

Open
voidtrance opened this issue Jun 19, 2024 · 0 comments
Open

Comments

@voidtrance
Copy link

I tried enabling Moonraker Timelapse and Klipper started crashing.

Internal error on command:"UPDATE_DELAYED_GCODE"
Traceback (most recent call last):
  File "/home/pi/klipper/klippy/gcode.py", line 211, in _process_commands
    handler(gcmd)
  File "/home/pi/klipper/klippy/gcode.py", line 137, in <lambda>
    func = lambda params: origfunc(self._get_extended_params(params))
  File "/home/pi/klipper/klippy/gcode.py", line 147, in <lambda>
    handler = lambda gcmd: self._cmd_mux(cmd, gcmd)
  File "/home/pi/klipper/klippy/gcode.py", line 315, in _cmd_mux
    values[key_param](gcmd)
  File "/home/pi/klipper/klippy/extras/delayed_gcode.py", line 52, in cmd_UPDATE_DELAYED_GCODE
    self.reactor.update_timer(self.timer_handler, waketime)
  File "/home/pi/klipper/klippy/reactor.py", line 121, in update_timer
    timer_handler.waketime = waketime
AttributeError: 'NoneType' object has no attribute 'waketime'

To debug this, I trimmed down my config to just the HW definitions and commented out the [autotune] sections. With this config everything worked. Then, I re-enabled only the autotune sections and I started getting the crash above.

klippy.log
moonraker.log

From the little debugging that I have done, what seems to be happening is that the Moonraker klippy:ready handler is calling the HYPERLAPSE ACTION=STOP macro. That macro ends up calling UPDATE_DELAYED_GCODE. However, the delayed_gcode extension has not fully initialized (it's klippy:ready handler has not been called yet).

There is at least another similar issue (#153) that seems to be causing a similar issue with the filament_motion_sensor extension.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant