flameshot icon indicating copy to clipboard operation
flameshot copied to clipboard

Flameshot won't save screenshots on NixOS; No such file or directory

Open Anakinjh opened this issue 9 months ago • 4 comments

Flameshot Version

Flameshot 12.1.0

Installation Type

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

Operating System type and version

NixOS 24.11 (Vicuna)

Description

I am trying to configure flameshot so that when I use a keybind (meta shift S) it will spawn the gui so i can take a screenshot. I need it to be through a bind, because my game won't let go of the cursor, but using the bind works. However when i copy to clipboard it seems there is an issue with copying full screen images to the clipboard, and none with small selections. When I attempt to save the image, I receive a "no such file or directory error", and when I try to paste full screen images from my clipboard into something like Discord, I get a "failed to upload" error, and the preview image is blank. Below are images of the errors, there seems to be no issue with small images, but large selections are not working as expected.

Steps to reproduce

Installing the "Flameshot" package in configuration.nix as a user package Starting Flameshot with Rofi to add it into the systray (1/2a) Using the bind "Meta Shift S" to lazy.spawn "flameshot gui", defined in my qtile configuration (2/2a) Manually clicking the Flameshot icon active in the systray to access the selection gui Selecting my full screen once the gui spawns, dragging from top left to bottom right (1/2b) Saving Image to clipboard with "Control C" and attempting to paste into Discord with "Control V" (2/2b) Saving image to ~/Pictures/Screenshots with "Control S"

Screenshots or screen recordings

Image

Image

Image

System Information

NixOS 24.11 (Vicuna) I honestly am not sure how to provide monitor configuration or what is relevant Qtile on Xorg

Anakinjh avatar Mar 21 '25 20:03 Anakinjh

Can you provide your flameshot config. In normal linux distro it is in ~/.config/flameshot/flameshot.ini.

Have you confirmed that the ~/Pictures/Screenshots exists as a folder?

I honestly am not sure how to provide monitor configuration or what is relevant

Considering that your are on Xorg, you can find relevant info here: https://flameshot.org/docs/guide/issue-reporting/

there seems to be no issue with small images, but large selections are not working as expected.

By "small" do you mean not fullscreen screenshots? Also does the issue persist when you do flameshot gui and then use Ctrl+a to select all the screen?

mmahmoudian avatar Mar 22 '25 10:03 mmahmoudian

[anakin@nixos:~/.config/flameshot]$ cat flameshot.ini [General] drawColor=#8bca84

System: Host: nixos Kernel: 6.6.83 arch: x86_64 bits: 64 Desktop: N/A Distro: NixOS 24.11 (Vicuna) Graphics: Message: Required tool lspci not installed. Check --recommends Display: x11 server: X.org v: 1.21.1.16 driver: N/A resolution: 2560x1440~60Hz API: OpenGL Message: Unable to show GL data. glxinfo is missing.

A restart seems to have fixed the issue I initially had. I turned my pc on today and the issue had resolved inself, even though I restarted flameshot a handful of times yesterday trying to fix it. However now when I attempted to screenshot the information above it failed to allow me to chose a selection area. Hitting escape closed the gui, but then clicking anywhere on my screen immediately pulled the gui for flameshot back up rather than doing what it should have, such as selecting a textbox in my browser or select a new tab in Discord with my mouse.

Additionally, I'm not sure if this was directly flameshot or not, but I was experiencing an inability to interact with any window in my window manager more than once without changing workspaces:

Typing a command into the terminal, such as flameshot --version caused no issue, but then attempting to highlight the text with my mouse to copy would make it so that I couldn't then select my browser window to paste it. I would first have to swap to a different workspace, back to the one with the browser, select the text box, back to a unrelated workspace, then back again to the browser workspace to paste. A reboot seems to have fixed this issue but it didn't start until after I attempted to use flameshot to take a screenshot of the above information. I didn't know control A selected the full screen yesterday when I submitted the issue, but it seems to work properly at the moment.

The issues i had yesterday seem to have resolved themselves now, and so for the issue with whatever was terrorizing my window manager seems to have also disappeared on a reboot, but I am adding it here because it only began after attempting to use the utility

Update:

Restarted my machine again, and now the fullscreen selection is back to improperly copying the image to my clipboard, and failing to paste it into Discord properly. However small area selections still appear to work as they should

Anakinjh avatar Mar 22 '25 10:03 Anakinjh

Is it only an issue in discord? Can you paste elsewhere?

borgmanJeremy avatar May 11 '25 00:05 borgmanJeremy

@Anakinjh We had some reports previously that users had issues pasting in electron-based and chromium-based software. Considering that you are on Nix, can you try pasting in the following software:

  1. a browser (e.g., Chrome, Firefox)
  2. Inkscape
    nix-shell -p inkscape
    
  3. kolourpaint
    nix-shell -p kdePackages.kolourpaint
    

mmahmoudian avatar May 11 '25 09:05 mmahmoudian