Error Catalog
Every error and warning the compiler can emit, with the cause and the fix. Search this page first when scadable verify or scadable compile complains.
Errors fail the build (non-zero exit). Warnings do not, but they print to the console and surface in CompileResult.warnings.
Errors
Device 'X': no connection defined
Device 'X': no connection definedA device class is missing the connection = ... attribute.
Fix: add a connection helper, like connection = modbus_tcp(host="...").
Device 'X': duplicate register address N ('a' and 'b')
Device 'X': duplicate register address N ('a' and 'b')Two registers on the same device share the same address. The runtime cannot decide which one to read first.
Fix: check your register list. The second address is wrong, or you copy-pasted an entry without changing it.
Device 'X': register 'r' uses dtype='Y' which target 'T' doesn't support (allowed: [...])
Device 'X': register 'r' uses dtype='Y' which target 'T' doesn't support (allowed: [...])You wrote dtype="float64" but compiled for a target that does not support it. RTOS, for example, has no FPU.
Fix: pick a supported dtype, or change the compile target. See Modbus for the dtype list.
Device 'X': protocol 'P' is not supported on target 'T' (allowed: [...])
Device 'X': protocol 'P' is not supported on target 'T' (allowed: [...])You used modbus_tcp(...) but compiled for esp32, which does not host a TCP/IP stack at production scale.
Fix: switch the device to modbus_rtu(...) (serial), or compile for linux.
Controller 'X': @on.data in <method> references unknown device 'd'
Controller 'X': @on.data in <method> references unknown device 'd'Your @on.data(SomeDevice) decorator names a device the parser did not find. Either the device file was excluded, or the import path is wrong.
Fix: confirm devices/some_device.py exists, defines a class subclassing Device, and the import in your controller matches.
Controller 'X': @on.change in <method> references unknown field 'd.f'
Controller 'X': @on.change in <method> references unknown field 'd.f'Same shape but for a field reference (@on.change(Device.field)). Either the device is missing or the register name does not match.
Fix: check the spelling against the Register(..., "name") declaration on the device.
Controller 'X': @on.threshold in <method> references unknown field 'd.f'
Controller 'X': @on.threshold in <method> references unknown field 'd.f'Same shape as @on.change.
Controller 'X': @on.device in <method> references unknown device 'd'
Controller 'X': @on.device in <method> references unknown device 'd'Same shape as @on.data.
unknown target 'X'. Known: linux, esp32, rtos
unknown target 'X'. Known: linux, esp32, rtosYou passed --target windows or similar. v0.2.0 ships three targets and validates the spelling.
Fix: pick one of linux, esp32, rtos.
Warnings
target 'esp32' is in preview ...
target 'esp32' is in preview ...You compiled for a non-production target. The validator runs full checks, but the emitter raises TargetNotImplementedError rather than producing an artifact. Informational, not an error.
Device 'X': modbus_tcp host is empty
Device 'X': modbus_tcp host is emptyYou wrote modbus_tcp(host="") or your env-var placeholder (${HOST}) was not set when verifying.
Fix: populate the env var, or hard-code the host.
Device 'X': modbus_rtu port is empty
Device 'X': modbus_rtu port is emptySame shape for modbus_rtu(port="").
Device 'X': BLE mac address is empty
Device 'X': BLE mac address is emptySame shape for ble(mac="").
Device 'X': serial port is empty
Device 'X': serial port is emptySame shape for serial(port="").
Device 'X': RTSP url is empty
Device 'X': RTSP url is emptySame shape for rtsp(url="").
skipped device file devices/X.py — SyntaxError on line N: ...
skipped device file devices/X.py — SyntaxError on line N: ...A file in devices/ did not parse. The compiler surfaces the failure as a warning and continues with the rest of the project.
Fix: read the line number; either fix the syntax or delete the file if it is no longer used.
skipped controller file controllers/X.py — SyntaxError on line N: ...
skipped controller file controllers/X.py — SyntaxError on line N: ...Same shape for controllers.
Reading the output
CLI output, after scadable verify:
-- Result --
errors: 2
warnings: 1
Device 'temp-1': no connection defined
Device 'temp-2': protocol 'modbus_tcp' is not supported on target 'esp32' (allowed: ['gpio', 'i2c', 'modbus_rtu', 'spi'])
target 'esp32' is in preview. DSL accepted; runtime support not yet shipped.Programmatic access:
from scadable.compiler import compile_project
result = compile_project(Path("./myproj"), target="linux")
for err in result.errors:
print("error:", err)
for warn in result.warnings:
print("warn:", warn)Next steps
- scadable verify: catch problems before compile
- scadable compile: turn errors into a build failure
Updated 4 days ago
