flameshot-org / flameshot

Powerful yet simple to use screenshot software :desktop_computer: :camera_flash:
https://flameshot.org
GNU General Public License v3.0
24.83k stars 1.59k forks source link

Freezes whole desktop #2627

Open hissssst opened 2 years ago

hissssst commented 2 years ago

Flameshot Version

Flameshot v11.0.0 (-) Compiled with Qt 5.15.3

Installation Type

Linux, MacOS, or Windows Package manager (apt, pacman, eopkg, choco, brew, ...)

Operating System type and version

Nixos

Description

Whole desktop gets frozen. It's not a memory leak, because earlyoom doesn't kill the flameshot

Steps to reproduce

  1. just run it. Any configuration or options will do
  2. During filechooser dialog it gets frozen

Screenshots or screen recordings

No response

System Information

Sway

borgmanJeremy commented 2 years ago

Have you followed the guide for setting up flameshot on sway? Do you have a notification manager like dunst installed and configured?

hissssst commented 2 years ago

Yeah, I have notification manager installed and configured

borgmanJeremy commented 2 years ago

When you say "just run it" what specifically are you doing? @nullobsi merged sway support and I believe it works for them.

hissssst commented 2 years ago

I run flameshot gui. It freezes when I run it from shell in VT in sway or when I run it from bind in sway

hissssst commented 2 years ago

By the way, it happens every time I run it

hissssst commented 2 years ago

I've just tested and this issue occurs even when flameshot started as a service and not

mmahmoudian commented 2 years ago

Do you have a any big rise in IO?

hissssst commented 2 years ago

How do I check it?

mmahmoudian commented 2 years ago

To check IO you can use iotop for example.

hissssst commented 2 years ago

Yeah, but my system gets completely frozen, how do I record this

mmahmoudian commented 2 years ago

If you have IO problem, recording it is not a good idea as almost all screen recording software write to disk while recording, but if you want to give this a try, I can recommend installing peek.

hissssst commented 2 years ago

Yeah, I know that screen recording is not a good idea, perhaps you know some IO usage top which can just append to the tail of file and don't corrupt it when the system is restarted. Any suggestions?

borgmanJeremy commented 2 years ago

Actually a better route would be to run flameshot in a debugger and see where it gets stuck. I strongly suspect this is an issue with your notification daemon or d-bus on your pc.

hissssst commented 2 years ago

What debugger would you suggest? gdb?

borgmanJeremy commented 2 years ago

For a non c++ dev the easiest way to do it would be to build the project from source using QtCreator. Then you can use the graphical version of GDB. Make sure you set the Cmake option "FLAMESHOT_DEBUG_CAPTURE" which will let you alt tab rather than freezing the screen.

If you are an experienced GDB user, yeah you can use it from the CLI.

hissssst commented 2 years ago

I've just reproduced this bug in export/import dialog in flameshot config

hissssst commented 2 years ago

By the way, I don't think I have time to debug this using gdb. But I can share the VM image of my setup upon which you can perform tests

MarkGotLasagna commented 1 year ago

I'd like to help on resolving the same problem by providing the necessary info: I have the same issue.

I'm using arch, with i3wm as WM.

mmahmoudian commented 1 year ago

@MarkGotLasagna what is your Flameshot version, how many monitors do you have, with what configuration, how have you installed Flameshot (pacman, AUR, Flatpak, Snap, AppImage,...) how are you running Flameshot (one-off mode or daemon mode, gui or screen or full), when does it freeze (during starting, when you copy, when you are writing to disk,...)

MarkGotLasagna commented 1 year ago

The whole desktop freezes as I click on any interactive icon within the flameshot gui (can still tty). Using key combinations DOES NOT crash the app (key press combination Ctrl + C: to copy to clipboard, Ctrl + S: save, ecc.).

mmahmoudian commented 1 year ago

@MarkGotLasagna do you mean that even for drawing an arrow it crashes? or is it only for when you copy or save the screenshot?

MarkGotLasagna commented 1 year ago

@MarkGotLasagna do you mean that even for drawing an arrow it crashes? or is it only for when you copy or save the screenshot?

I failed to reproduce the issue. The app works as intended. Last time it freezed, I made sure to restart my device to rule out any possible interference.

Last time I checked, the app freezed only when interacting with circled elements of the UI (the buttons to copy/paste, save, open app to share, ecc.).

hissssst commented 1 year ago

@MarkGotLasagna this issue is not about app crash

MarkGotLasagna commented 1 year ago

@MarkGotLasagna this issue is not about app crash

That's right, the issue is about the app freezing the whole desktop.

I fixed the response.