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

[BUG] Screenshots path is empty. Sceenshots won't work #264

Open
imerzi opened this issue Nov 22, 2023 · 7 comments
Open

[BUG] Screenshots path is empty. Sceenshots won't work #264

imerzi opened this issue Nov 22, 2023 · 7 comments
Assignees
Labels
New issue New issue which has not been checked yet

Comments

@imerzi
Copy link

imerzi commented Nov 22, 2023

Describe the bug

I got a warning and the stack trace from Catcher that screenshot path is empty after initialize catcher in SilentReportMode and ConsoleHandler when my app is starting.

I don't want to have any screenshot saved is this possible to disable screenshots ?

it's not the same comportment in PageReportMode and ConsoleHandler, no page report and any stacktrace linked to the screenshot path is empty

Is this intended ?

To Reproduce

  // config used when Catcher detects that applications run in debug mode
  final CatcherOptions debugOptions = CatcherOptions(
    SilentReportMode(),
    <ReportHandler>[
      ConsoleHandler(),
    ],
  );

  // config used when Catcher detects that application runs in release mode
  final ReportMode reportMode = dotenv.get('APP_ENV') != 'prod' ? DialogReportMode() : SilentReportMode();
  final CatcherOptions releaseOptions = CatcherOptions(
    reportMode,
    <ReportHandler>[
      SentryHandler(
        SentryClient(SentryOptions(dsn: dotenv.get('SENTRY_DSN'))),
      ),
    ],
  );

  // [Catcher] include runApp to inflate the given widget
  Catcher(
    navigatorKey: GlobalKey<NavigatorState>(),
    rootWidget: LocalizedApp(
      delegate,
      const ProviderScope(
        child: MainApp(),
      ),
    ),
    debugConfig: debugOptions,
    releaseConfig: releaseOptions,
    ensureInitialized: true,
  );

Screenshots
image

Flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.16.0, on Linux Mint 21.2 6.2.0-36-generic, locale fr_FR.UTF-8)
[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
[✓] Chrome - develop for the web
[✓] Linux toolchain - develop for Linux desktop
[✓] Android Studio (version 2022.3)
[✓] Connected device (3 available)
[✓] Network resources

Catcher version

  • Version: 0.8.0

Smartphone (please complete the following information):

  • Device: Android Emulator
  • OS: Android 13
@imerzi imerzi added the New issue New issue which has not been checked yet label Nov 22, 2023
@imerzi
Copy link
Author

imerzi commented Dec 7, 2023

bump

@ThexXTURBOXx
Copy link
Contributor

This is fixed in catcher_2

@imerzi
Copy link
Author

imerzi commented Dec 13, 2023

I will give it a try thanks

@AnhTH260101
Copy link

AnhTH260101 commented Jun 12, 2024

This is fixed in catcher_2

I try using catcher 2 but it not working
I/flutter (20975): [2024-06-12 16:37:53.889222 | Catcher | WARNING] Screenshots path is empty. Screenshots won't work.
I/flutter (20975): [2024-06-12 16:37:53.899660 | Catcher | FINE] Catcher configured successfully.
I/flutter (20975): [2024-06-12 16:37:54.133965 | Catcher | INFO] Setup localization lazily!
I/flutter (20975): [2024-06-12 16:37:54.133965 | Catcher | INFO] Setup localization lazily!
I/flutter (20975): null
I/flutter (20975): null
I/flutter (20975): [2024-06-12 16:37:54.169400 | Catcher | WARNING] Couldn't use report mode because you didn't provide navigator key. Add navigator key to use this report mode.
I/flutter (20975): [2024-06-12 16:37:54.169400 | Catcher | WARNING] Couldn't use report mode because you didn't provide navigator key. Add navigator key to use this report mode.

@ThexXTURBOXx
Copy link
Contributor

ThexXTURBOXx commented Jun 12, 2024

Couldn't use report mode because you didn't provide navigator key. Add navigator key to use this report mode.

@AnhTH260101

Edit: Also your issue is different. This issue (#264) is about a crash related to the screenshot manager (which is fixed in catcher_2). Your logs do not indicate any crash, just an invalid configuration. Read through the setup instructions again.

@AnhTH260101
Copy link

AnhTH260101 commented Jun 12, 2024

Couldn't use report mode because you didn't provide navigator key. Add navigator key to use this report mode.

@AnhTH260101

Edit: Also your issue is different. This issue (#264) is about a crash related to the screenshot manager (which is fixed in catcher_2). Your logs do not indicate any crash, just an invalid configuration. Read through the setup instructions again.

i don't think the configuration is wrong because it was working 2.
but when i using catcher_2 log show similar.
I/flutter (26468): [2024-06-12 17:00:05.811426 | Catcher 2 | WARNING] Screenshots path is empty. Screenshots won't work.
I/flutter (26468): [2024-06-12 17:00:05.853630 | Catcher 2 | FINE] Catcher 2 configured successfully.
I/flutter (26468): [2024-06-12 17:00:06.075874 | Catcher 2 | INFO] Setup localization lazily!
I/flutter (26468): [2024-06-12 17:00:06.075874 | Catcher 2 | INFO] Setup localization lazily!
I/flutter (26468): [2024-06-12 17:00:06.120980 | Catcher 2 | WARNING] Couldn't use report mode because you didn't provide navigator key. Add navigator key to use this report mode.
I/flutter (26468): [2024-06-12 17:00:06.120980 | Catcher 2 | WARNING] Couldn't use report mode because you didn't provide navigator key. Add navigator key to use this report mode.

@ThexXTURBOXx
Copy link
Contributor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
New issue New issue which has not been checked yet
Projects
None yet
Development

No branches or pull requests

4 participants