@Larsen Do you have a reverse proxy in place? In that case you could modify and test the modified CSP and we don’t have to do the back and forth of I change something and you test it once it’s released.
I just upgraded my operative system (finally). I have one issue that after the upgrade it requires me to clear the cache on my Chrome browser. This is a PITA because Chrome does not have the granularity to simply clean cache items for just the one single OH url, so it ends up in me having to re-login to ALL the web sites (e.g. github, this forum, etc.) where the OH upgrade will have caused (therefore) those cached things to also be deleted.
app.ce6be30….js:2 Refused to create a worker from 'blob:http://rapi2:8080/7db4cacc-886d-487f-841b-81ea6eb92bd9' because it violates the following Content Security Policy directive: "default-src 'self' 'unsafe-inline' 'unsafe-eval'". Note that 'worker-src' was not explicitly set, so 'default-src' is used as a fallback.
app.ce6be30….js:2 VIDEOJS: SecurityError: Failed to construct 'Worker': Access to the script at 'blob:http://rapi2:8080/7db4cacc-886d-487f-841b-81ea6eb92bd9' is denied by the document's Content Security Policy.
at new <anonymous> (app.ce6be30….js:2:386027)
at new t (app.ce6be30….js:2:561526)
at i.src (app.ce6be30….js:2:606707)
at Object.handleSource (app.ce6be30….js:2:616608)
at e.setSource (app.ce6be30….js:2:195985)
at t.<anonymous> (app.ce6be30….js:2:318700)
at t.ready (app.ce6be30….js:2:160292)
at i.techCall_ (app.ce6be30….js:2:318498)
at t.<anonymous> (app.ce6be30….js:2:328870)
at t.ready (app.ce6be30….js:2:160292)
app.ce6be30….js:2 Uncaught SecurityError: Failed to construct 'Worker': Access to the script at 'blob:http://rapi2:8080/7db4cacc-886d-487f-841b-81ea6eb92bd9' is denied by the document's Content Security Policy.
at new <anonymous> (app.ce6be30….js:2:386027)
at new t (app.ce6be30….js:2:561526)
at i.src (app.ce6be30….js:2:606707)
at Object.handleSource (app.ce6be30….js:2:616608)
at e.setSource (app.ce6be30….js:2:195985)
at t.<anonymous> (app.ce6be30….js:2:318700)
at t.ready (app.ce6be30….js:2:160292)
at i.techCall_ (app.ce6be30….js:2:318498)
at t.<anonymous> (app.ce6be30….js:2:328870)
at t.ready (app.ce6be30….js:2:160292)
I installed the reverse proxy but I don’t know what to do with it.
Just FYI for anyone else having this problem:
I have fixed this issue and merged the small code change for this yesterday, after @Larsen tested the fix and confirmed it was working.
Cheers, took me a while, but it seems it was an incomplete rule that was borking the start up. Had a couple of tests that I was working on and it seems they borked the runtime when starting. Deleting all of the incomplete rules fixed it.
Maybe because in 4.3 managed JavaScript rules are loaded at startup to avoid the delay during first run.
What was incomplete in that rule? imho this shouldn’t block the whole openhab startup.
An empty dsl rule. The one thing that got me stuck was that there was no hint about what the problem was. I thought I might have an empty configuration somewhere… so it took me quite a bit to find out. But yeah, as soon as I deleted the rule, boom, runtime started.
I am seeing a failure on docker with 4.3.0.M2. 4.3.0.M1 works fine when i downgrade. Did M2 go out yesterday? i have been tracking openhab/openhab:milestone docker images.
SUCCESS: openHAB updated from 4.3.0.M1 to 4.3.0.M2
+ chown -R openhab:openhab /openhab
+ sync
+ '[' -d /etc/cont-init.d ']'
++ wc -l
++ ls '/usr/bin/s6-*'
+ '[' 0 == 0 ']'
++ find /etc/cont-init.d -type f
++ grep -v '~'
++ sort
+ for script in $(find /etc/cont-init.d -type f | grep -v \~ | sort)
+ . /etc/cont-init.d/50-exec-scripts
++ export PATH=/openhab/conf/scripts:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
++ PATH=/openhab/conf/scripts:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
++ apt-get -qq update
++ DEBIAN_FRONTEND=noninteractive
++ apt-get -qq install --no-install-recommends -y curl jq python
E: Package 'python' has no installation candidate
It’s a little hard to tell but it’s this output from a script you’ve minutes to /etc/cont-int.d inside the container? I’m pretty sure this write is not coming from the entrypoint.sh script itself.
The error is probably that “python” is not in the repos of most distris any more. You usually want to install “python3”. “python” installs Python 2 which has been and of life for some years now.
Yes, after posting i had a spark of memory about having a custom script i added possibly years ago at this point ago to openhab for python. Now, i need to work out why i added it, and if i still need it.
All fixed, debian went from 11.9 to 12.7 in the docker container so switched to using python3 package. I have a roku discovery script that uses python. jq and curl were probably for debugging stuff in the past.
This is a minor problem but one that is awkard for average users to deal with. I’m not sure it needs to be fixed but it does need to be documented as a breaking change. Maybe it’s a good candidate for the upgradeTool.
I first noticed this on 4.3 M2 but it may have occurred earlier.
Those of us who use the developer sidebar a long time ago to generate the ~Scratchpad~ script (or any other JS Scripting script that you still have hanging around since OH 3.X) will notice that the script will now fail complaining that application/javascript;version=CMAScript-2021 is not supported (or some such).
There are two ways to fix this:
Copy the contents of the Script, delete the script, recreate it and paste the contents on the clipboard. (Note when I tried this it confused the developer sidebar and I had to restart OH to recreate ~Scratchpad~).
Stop OH and do a find and replace in $OH_USERDATA/jsondb/automation_rules.json
On my overview page I use the feature “Tap Hold” to navigate to a different page:
Action performed when tapping and holding card (or calling contextual menu on desktop)
Tapping and holding on mobile is fine. On desktop (tested in Chrome, Edge) the action works, but the contextual menu is shown in addition. As I remember, this was not in 4.2, but I can’t compare anymore.