Hi guys!
I’m having trouble getting sentry to work with clojurescript source maps and I’m looking for suggestions.
I have an app that’s split into two parts: a small js app compiled with webpack, and a larger cljs app compiled with closure. After uploading the sources and sourcemaps as described here for both js and cljs, the mapping only seems to work with the js.
When I look at the sentry UI stacktrace, it will show lines such as called from /main.out/foo/bar.cljs
. However, at the top of the error report will be a big orange box reading "There were X errors encounters while processing this event"
.
Each error is listed as an HTTP returned 404 response on: https://redacted/main.out/foo/bar.cljs
.
I’m not sure the root of my misunderstanding. I thought closure advanced=true
compiled all sources into a single main.js
file. Yet source maps (locally, at least) only seem to work if the main.out/
file is in the same relative root as the generated main.js
file. I suppose this makes sense because the sourcemap declaration looks something like sources: ["main.out/foo/bar.js"]
. What is unclear is whether or not this main.out/foo/bar.js
now has to be incuded as a pre-uploaded file for sourcemaps to work?
I’m wondering if anyone can shed some light on this topic? Hopefully someone else has used sentry and cljs and can point me in the right direction.