I am working on pop!OS using Mozilla Firefox.
When I open developer options console and try to make changes to the webpage(specifically changing the seasonal photo on google.com to that of a cat from pixabay.com) it doesn’t work. But then there is this error I keep seeing anytime I open developer options on a webpage.
Content-Security-Policy: (Report-Only policy) The page’s settings would block an event handler (script-src-attr) from being executed because it violates the following directive: “script-src ‘nonce-MhEN2Yr7TKzGZSuX-cGEHw’ ‘strict-dynamic’ ‘report-sample’ ‘unsafe-eval’ ‘unsafe-inline’ https: http:”
Source: _rtf(this)
and…
Content-Security-Policy: (Report-Only policy) The page’s settings would block a script (script-src-elem) at
https://www.gstatic.com/_/mss/boq-identity/_/js/k=boq-identity.IdentityRotateCookiesHttp.en_US.whKIJEZ_mPQ.es5.O/am=DAY/d=1/rs=AOaEmlGK7LdK0XwTFbJAAAPAYXm_ieQaeg/m=hfcrfrom being executed because it violates the following directive: “script-src ‘unsafe-inline’ ‘unsafe-eval’ blob: data:”
Error showing when console is opened

DOM remain the-same after JavaScript code was instructed to change the holidays picture

But, when I go manually into the HTML I am able to make changes (used the inspector tool to select the image and changed the ‘src’ to that of the cat image.)
image showing the google.com seasonal picture changed to a cat picture

I tried this on chromium and everything was working as should. That is, I was able to edit the DOM manually and with JavaScript from the console. Until I logged into my gMail, the another similar error was shown at the top.
Error from chromium developer tools console

But the primary problem is why Firefox gives me that error.
I did some search myself and got things about csp, I played with that a bit from about:config but didn’t help either.
I went through the developer tools and played around to see if it was about anything that was checked or unchecked but no positive results
(p.s. I am new to using developer tools and only following a tutorial).
I uninstalled Firefox and installed it again, still the error messages at the top of the console were still there. I installed flatpak version of Firefox the-same problem was still there. I restarted my PC and still.
NOTE: I am running my javascript code in the live console(developer options, click the console tab and typed it in there)


