We tried to integrate sentry.io in our ionic3 app, anything is working fine expecting on production releases, the error logged to sentry is the production code and not mapped with our upploaded sourcemap.
We created our production build for android in this way:
ionic cordova build android --prod --release
Using app-scripts 3.0.0 the sourcemap should be under the new .sourcemaps
folder, so we upload the files for release in this way:
sentry-cli releases -o blabla -p blabla files 0.0.10 upload-sourcemaps --url-prefix / .sourcemaps
We configure Raven like this:
Raven
.config(
'xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx',
{
release: '0.0.10',
dataCallback: data => {
if (data.culprit) {
data.culprit = data.culprit.substring(data.culprit.lastIndexOf('/'));
}
var stacktrace = data.stacktrace ||
data.exception &&
data.exception.values[0].stacktrace;
if (stacktrace) {
stacktrace.frames.forEach(function (frame) {
frame.filename = frame.filename.substring(frame.filename.lastIndexOf('/'));
});
}
}
}
)
.install();
But at the end we are always running on error notification without sourcemap, like this:
Can anyone help?