Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stack trace context #127

Open
mgalgs opened this issue Apr 5, 2024 · 4 comments
Open

Stack trace context #127

mgalgs opened this issue Apr 5, 2024 · 4 comments

Comments

@mgalgs
Copy link
Contributor

mgalgs commented Apr 5, 2024

Do I need to do anything to be able to see context (local variables, etc) in my Flutter stack traces? Currently it always says No context to show!

image

This is how I'm initializing Rollbar in my app:

Future<void> main() async {
  WidgetsFlutterBinding.ensureInitialized();

  PackageInfo packageInfo = await PackageInfo.fromPlatform();

  var config = Config(
    accessToken: '...',
    package: '...',
    codeVersion: packageInfo.version,
    handleUncaughtErrors: true,
    includePlatformLogs: true,
  );

  await Firebase.initializeApp(
    options: DefaultFirebaseOptions.currentPlatform,
  );

  await RollbarFlutter.run(config, () => runApp(MyApp()));
}
@DeviceApplocum
Copy link

@mgalgs How do you add the stack trace and request section using this package?

@mgalgs
Copy link
Contributor Author

mgalgs commented Sep 12, 2024

@DeviceApplocum the above code is my entire initialization for rollbar

@DeviceApplocum
Copy link

Hi @mgalgs, how are you handling the API requests? I’m not getting the request URL in Rollbar

@mgalgs
Copy link
Contributor Author

mgalgs commented Sep 13, 2024

Not sure which API requests you're referring to? I have handleUncaughtErrors set to true, so errors are reported automatically. But you can also add explicit logging using the rollbar library as per the docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants