Context for developing and debugging Hubitat Elevation apps, drivers, and hub environment — sandbox constraints, lifecycle idioms, capability contracts, plus grounded deploy/log-tail/lint mechanisms.
81
94%
Does it follow best practices?
Impact
27%
Average score across 2 eval scenarios
Advisory
Suggest reviewing before use
These pass the sandbox compiler and then misbehave at runtime. They are the bulk of "it saved fine but does nothing" reports.
subscribe(dev, "motion", "motionHandler"), runIn(300, "checkState"), schedule(cron, "poll") reference the handler by a bare string. A typo or a renamed-but-not-updated handler compiles clean and fails silently at dispatch time.runIn/runOnce/schedule string for the old name. The lint-review skill checks that each such string resolves to a defined method.if (offAfter) is false for both null and 0. Code that means "was a value provided?" but writes if (setting) mistakes a legitimate 0 for unset.if (offAfter != null).required device input is null until selected. lights.on() throws when lights is null.lights?.on()) or mark the input required: true.hubitatQueryString (reserved — holds the JSON of URL query params).state, device, location, settings, log, app).name + namespace in definition must be globally unique on the hub.@Field static variable is shared across all instances of that app/driver and is lost on reboot or code re-save. It is not per-device storage — use state for that (see rules/state-vs-attributes.md), or a ConcurrentHashMap keyed by device id if you genuinely need shared, rebuild-on-boot data.