axis_twist_compensation: Fix AttributeError on klippy connect state (#6881)

Object 'configfile' has no attribute 'error'

Signed-off-by: Maksim Bolgov <maksim8024@gmail.com>
This commit is contained in:
Maksim Bolgov 2025-04-06 04:36:35 +03:00 committed by GitHub
parent 3a9e9a4bef
commit 46ee920b93
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -125,9 +125,8 @@ class Calibrater:
def _handle_connect(self):
self.probe = self.printer.lookup_object('probe', None)
if (self.probe is None):
config = self.printer.lookup_object('configfile')
raise config.error(
if self.probe is None:
raise self.printer.config_error(
"AXIS_TWIST_COMPENSATION requires [probe] to be defined")
self.lift_speed = self.probe.get_probe_params()['lift_speed']
self.probe_x_offset, self.probe_y_offset, _ = \