Closed ghost closed 2 years ago
@chathu-novade The screenshot is about the source maps of the Dart SDK itself and not your App's code. Do you see your App's code symbolicated? that should work OOTB.
This is what the stack looks like. Can not see the anything related to app code.
The hidden source section of the screenshot looks like the following.
source: https://domain.tld/hostedtoolcache/Flutter/3.0.5/macos/flutter/.pub-cache/hosted/pub.dartlang.org/sentry-6.9.1/lib/src/sentry_client.dart
I don't follow, the screenshot below has the symbolicated stack trace, it's not minified, what's the problem you are having? can you please update the issue description with more details?
@marandaneto I can not see any stack trace related my my dart code in the flutter project. It show only minified:e4b and exception but not the line of dart code.
@chathu-novade can you provide the code snippet of the Sentry SDK init?
Can you provide the full config of the sentry
plugin?
Can you provide the command line you are using to build your Flutter app?
Can you provide a link to an issue on sentry.io so I can have a look?
Sentry SDK init
await SentryFlutter.init(
(options) {
options
..environment = env.toStr()
..release = sentryRelease // from String.fromEnvironment('SENTRY_RELEASE')
..dsn = dsn;
},
// Init your App.
appRunner: () => runApp(const _App()),
);
Sentry plugin config
sentry:
upload_source_maps: true
Flutter build command
flutter build web --dart-define=SENTRY_RELEASE=$(SENTRY_RELEASE) --dart-define=AMPLITUDE_API_KEY=$(AMPLITUDE_API_KEY) -t lib/web/main.staging.dart --web-renderer canvaskit --source-maps --dart-define=BROWSER_IMAGE_DECODING_ENABLED=false
@chathu-novade release
and dist
should match when initing the SDK and uploading source maps.
I see that you don't set the dist
at least, do they match?
Can you provide a link to an Sentry's issue?
@chathu-novade you probably need --release
in your build command line as well.
dist
is default so it get build in build/web
which also the default of this plugin.
@marandaneto
https:
//sentry.io/organizations/novade/issues/
3543519896/
?project=1770595
The flutter mobile builds works well Issue is with the web build
@chathu-novade I don't see any problem with your errors, its symbolicated correctly.
The issue title is minified:e2b
because of https://docs.sentry.io/platforms/flutter/troubleshooting/#known-limitations
See runtimeType
.
You are likely calling captureException
with an object that is not an exception and its stringified, so there's no problem with symbolication.
Can you clarify the problem?
@chathu-novade you probably need
--release
in your build command line as well.
--release Build a release version of your app (default mode).
@marandaneto In that error there are errors which says source code not found.
@chathu-novade that's already answered here https://github.com/getsentry/sentry-dart-plugin/issues/38#issuecomment-1231230647 If you don't see any frame from your own App, the reason is here https://github.com/getsentry/sentry-dart-plugin/issues/38#issuecomment-1231659696 So I guess that's all from my side unless you provide more context around my questions.
About
The issue title is
minified:e2b
because of https://docs.sentry.io/platforms/flutter/troubleshooting/#known-limitations SeeruntimeType
.
Does this applicable to the web too?
web Obfuscation is not supported for web apps, but a web app can be minified, which is similar. When you build a release version of a Flutter web app, it is automatically minified. For more information, see Build and release a web app.
Please raise an issue on https://github.com/getsentry/sentry-dart and provide a minimal reproducible example (this is required), it's unclear what's the problem here since the linked event just works, without more context, we can't help.
https
://sentry.io/organizations/novade/issues/
3510915187/events/
bcaba367a7e74e92b0f7258900827d9a/
Check this issue and expand the stackstrace. We can not see which file threw the exception and not usable stack trace.
Environment
Flutter SDK version
"flutterSdkVersion": "3.0.5"
sentry_dart_plugin version:
sentry_dart_plugin: ^1.0.0-beta.1
Steps to Reproduce