Obviously it’s impossible for us (Shopify) to say exactly what’s throwing that issue, so bringing it up with Sentry is the right call there. But I would say it’s likely to do with the way we sandbox extensions. They aren’t able to interact directly with the page, and that may be what Sentry is trying to do (accessing the DOM directly for example) and when that isn’t possible it’s throwing errors.
Just some insight, I don’t think there’s anything we can do about this at the moment.
Don’t suppose you can enlighten me on whether there are any restrictions/changes/etc to how reportError (Window: reportError() method - Web APIs | MDN) might be affected by your sandboxing?
It looks like reportError is still accessible from within your sandbox - have I interpreted that correctly? So I can still call it without any restrictions, in the same way I can call console.log?
The thing that’s puzzling me is I understood “native code” to mean “browser code”, and so if reportError is the function that’s throwing, wouldn’t that suggest a browser bug rather than a Sentry or Shopify issue?
That’s exactly it, everything will be reported and logged within the worker itself. Maybe you can catch and report a bit more of a trace with that if you want to debug yourself, it’s a good idea.
I don’t personally know any restrictions imposed by reportError since it is meant specifically for workers, but it’s not an area I’m very familiar with the more subtle nuances of.