-
-
Notifications
You must be signed in to change notification settings - Fork 457
Description
Expected Behavior
OH starts without spamming the logs with errors.
Current Behavior
Long before OH reaches start level 40 and apparently before the automation add-ons are loaded and activated ScriptEngineManagerImpl spams the logs with the following error:
2025-08-20 09:04:51.218 [INFO ] [org.openhab.core.Activator ] - Starting openHAB 5.0.1 (Release Build)
2025-08-20 09:04:52.239 [INFO ] [.core.internal.i18n.I18nProviderImpl] - Time zone set to 'America/Denver'.
2025-08-20 09:04:52.246 [INFO ] [.core.internal.i18n.I18nProviderImpl] - Location set to '39.051660101889716,-104.81540679931642'.
2025-08-20 09:04:52.249 [INFO ] [.core.internal.i18n.I18nProviderImpl] - Locale set to 'en_US'.
2025-08-20 09:04:52.250 [INFO ] [.core.internal.i18n.I18nProviderImpl] - Measurement system set to 'US'.
2025-08-20 09:04:55.307 [WARN ] [.transport.servlet.ServletController] - Can't find the request for http://argus:8080/rest/events's Observer
2025-08-20 09:04:55.310 [WARN ] [.transport.servlet.ServletController] - Can't find the request for http://argus:8080/rest/events's Observer
2025-08-20 09:04:55.313 [WARN ] [.transport.servlet.ServletController] - Can't find the request for http://argus:8080/rest/events/states's Observer
2025-08-20 09:04:56.369 [WARN ] [.transport.servlet.ServletController] - Can't find the request for http://argus:8080/rest/events's Observer
2025-08-20 09:04:56.369 [WARN ] [.transport.servlet.ServletController] - Can't find the request for http://argus:8080/rest/events's Observer
2025-08-20 09:04:56.369 [WARN ] [.transport.servlet.ServletController] - Can't find the request for http://argus:8080/rest/events/states's Observer
2025-08-20 09:05:06.992 [INFO ] [.core.model.lsp.internal.ModelServer] - Started Language Server Protocol (LSP) service on port 5007
2025-08-20 09:05:07.682 [ERROR] [ipt.internal.ScriptEngineManagerImpl] - ScriptEngine for language 'application/javascript' could not be found for identifier: 3ab8b6e3-648e-42b1-9559-68d7e11bcbca
2025-08-20 09:05:07.691 [ERROR] [ipt.internal.ScriptEngineManagerImpl] - ScriptEngine for language 'application/javascript' could not be found for identifier: f34e46ca-afd0-4a62-a42c-5ce76d1f8c8b
2025-08-20 09:05:07.694 [ERROR] [ipt.internal.ScriptEngineManagerImpl] - ScriptEngine for language 'application/javascript' could not be found for identifier: 031deca4-65a1-4a13-ad62-ad99d330eed5
...
In this startup, start level 40 was reached at 9:05:42.
It appears that there is one log entry for each Script Action and Script Condition defined in the JSONDB.
Once start level 40 is reached, startup happens normally and all rules are functional and operating as expected.
Possible Solution
Assess why ScriptEngineManagerImpl is being invoked before the automation add-ons are available and, if possible, log out an identifier that is meaningful to the end user (something including the rule ID perhaps). If this error ever occurs legitimately the user won't have an easy way to identify which rule is the problem.
Steps to Reproduce (for Bugs)
- Install and run OH 5.0.1 or later
- Have at least one managed rule defined with a script action or script condition that depends on an automation add-on (e.g. JS Scripting)
- Restart OH once you are sure that all bundles are installed and active after the cache was cleared.
- Observe the logs immediately after the LSP starts.
Context
It's freaking out a bunch of users but ultimately does not have an impact on the operation of OH. All rules appear to run as expected once OH reaches the appropriate start levels.
See the release discussion thread and https://community.openhab.org/t/oh-5-0-0-to-oh5-1-0-snaphot-error-scriptengine-for-language-application-javascript-could-not-be-found-for-identifier/165496/27
Your Environment
- Version used: 5.0.1
- Environment name and version (e.g. Chrome 111, Java 17, Node.js 18.15, ...): Official Docker Debian image
- Operating System and version (desktop or mobile, Windows 11, Raspbian Bullseye, ...):Ubuntu 24.04