-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
[Groovy] Default preset does not include OnOffType #17247
Labels
bug
An unexpected problem or unintended behavior of an add-on
Comments
dilyanpalauzov
added
the
bug
An unexpected problem or unintended behavior of an add-on
label
Aug 13, 2024
Are you aware of the last version that worked? Maybe @wborn can comment as most groovyscripting PR’s are his. I’m also interested in how this mechanism is setup, to provide future support |
No, this is the first version I tried (OH 4.2.1). |
wborn
added a commit
to wborn/openhab-addons
that referenced
this issue
Sep 7, 2024
This allows for removing many imports from scripts which results in less code. Fixes openhab#17247 Signed-off-by: Wouter Born <github@maindrain.net>
wborn
added a commit
to wborn/openhab-addons
that referenced
this issue
Sep 7, 2024
This allows for removing many imports from scripts which results in less code. Fixes openhab#17247 Signed-off-by: Wouter Born <github@maindrain.net>
I don't think it ever worked but I figured out a way for importing these additional classes in scripts with #17383. |
digitaldan
pushed a commit
to digitaldan/openhab-addons
that referenced
this issue
Sep 24, 2024
This allows for removing many imports from scripts which results in less code. Fixes openhab#17247 Signed-off-by: Wouter Born <github@maindrain.net>
pgfeller
pushed a commit
to pgfeller/openhab-addons
that referenced
this issue
Sep 29, 2024
This allows for removing many imports from scripts which results in less code. Fixes openhab#17247 Signed-off-by: Wouter Born <github@maindrain.net> Signed-off-by: Patrik Gfeller <patrik.gfeller@proton.me>
joni1993
pushed a commit
to joni1993/openhab-addons
that referenced
this issue
Oct 15, 2024
This allows for removing many imports from scripts which results in less code. Fixes openhab#17247 Signed-off-by: Wouter Born <github@maindrain.net>
matchews
pushed a commit
to matchews/openhab-addons
that referenced
this issue
Oct 18, 2024
This allows for removing many imports from scripts which results in less code. Fixes openhab#17247 Signed-off-by: Wouter Born <github@maindrain.net>
cipianpascu
pushed a commit
to cipianpascu/openhab-addons
that referenced
this issue
Jan 2, 2025
This allows for removing many imports from scripts which results in less code. Fixes openhab#17247 Signed-off-by: Wouter Born <github@maindrain.net> Signed-off-by: Ciprian Pascu <contact@ciprianpascu.ro>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
https://www.openhab.org/docs/configuration/jsr223.html#default-preset-importpreset-not-required says that the OnOffType is available in Groovy, as part of the Default preset.
I create a file in openhab/automation/jsr223/onoff.groovy with content:
Loading it fails:
If I change onoff.groovy to:
there is no error on loading.
So in OpenHAB 4.2.1 the Default preset for Groovy does not include OnOffType, contrary to the statement at https://www.openhab.org/docs/configuration/jsr223.html#default-preset-importpreset-not-required.
The text was updated successfully, but these errors were encountered: