- Issue created by @dmitriy-komarov
- 🇨🇦Canada gapple
Thanks for the report - I'll really need to look at this one since CSP now has its own library with no JS or CSS files 😰 (though it hasn't caused errors so far 🤞).
It might be sufficient to just add some exception handling when CSP is scanning for all libraries so that it ignores invalid definitions - CSP is kind of a canary because it loads all libraries even if they are unused (which is fine and valid in certain cases)
- 🇨🇦Canada gapple
So CSP's own library is safe, since it has a dependency, and a library must only define one of
css
,js
,drupalSettings
, ordependencies
.There are also currently a few other errors that could occur in library definitions (if
header
is not a boolean value, a remote library does not define a license, or a JavaScript file is given a positive weight), but an unused and incomplete definition is probably the most likely to happen. If CSP skips and logs the exception, it would still be thrown later if any library from the module is actually used and the parsing is attempted again. - Status changed to Fixed
12 months ago 8:18am 8 December 2023 Automatically closed - issue fixed for 2 weeks with no activity.