Agree with @h1teshtr1path1answer, it’s a CSP conflict that you can resolve by adapting your security rules to allow copying to clipboard. I guess you inherited a stronger policy - defined by HTTP headers - with a recent update of your frontend canister.
The fact that is deprecated is unlikely the root cause of the issue.
Just sharing if interesting, this is e.g. the newer Web API to copy text to clipboard: