GyulyVGC / sniffnet

Comfortably monitor your Internet traffic 🕵️‍♂️
https://sniffnet.net
Apache License 2.0
18.64k stars 557 forks source link

Sniffnet cannot open the file dialog #503

Closed Digitalone1 closed 7 months ago

Digitalone1 commented 7 months ago

Is there an existing issue for this?

What's the problem?

Sniffnet is not able to open a file dialog to select a destination for the capture file, or the ASN/County database.

How did you install the app?

downloaded one of the provided packages

Operating System

Linux

Additional context

Installed from Arch upstream: https://archlinux.org/packages/extra/x86_64/sniffnet/

GyulyVGC commented 7 months ago

Not a good news.

This has almost for sure to do with rfd.

I tested it on Windows, macOS, and DEB/GNOME and it works smoothly.

Could you verify from their docs that your backend is supported? They recommend to install gtk3 on Arch, but it should only be required for the build and not for normal usage.

GyulyVGC commented 7 months ago

Note that I think their docs aren't updated, since they should use XDG by default since 0.14.

So please refer to the doc section talking about the XDG backend.

Digitalone1 commented 7 months ago

DEB/GNOME and it works smoothly.

Where did it work smoothly? Did you test it in a Wayland environment?

GyulyVGC commented 7 months ago

X11 actually.

IIRC you are on Wayland, but in theory it should work even there.

Digitalone1 commented 7 months ago

I have those installed:

$ pacman -Qs portal
local/libportal 0.7.1-2
    GIO-style async APIs for most Flatpak portals
local/libportal-gtk3 0.7.1-2
    GIO-style async APIs for most Flatpak portals - GTK 3 backend
local/libportal-gtk4 0.7.1-2
    GIO-style async APIs for most Flatpak portals - GTK 4 backend
local/xdg-desktop-portal 1.18.3-1
    Desktop integration portals for sandboxed apps
local/xdg-desktop-portal-gnome 46.0-1 (gnome)
    A backend implementation for xdg-desktop-portal for the GNOME desktop environment
local/xdg-desktop-portal-gtk 1.15.1-1
    A backend implementation for xdg-desktop-portal using GTK
GyulyVGC commented 7 months ago

Can you open Sniffnet from a terminal and see if there's any output when you try to open the file dialog?

Digitalone1 commented 7 months ago

Can you open Sniffnet from a terminal and see if there's any output when you try to open the file dialog?

No, there's no output.

I added the custom databases in the text config. Are the followings compatible?

They're shown in red color. Maybe not supported?

image

GyulyVGC commented 7 months ago

GeoLite databases are supported, but you have to select the MMDB file format (which is also the only one that the file dialog will allow to select for those two fields).

Digitalone1 commented 7 months ago

Never mind, I don't have those formats.

Is there maybe any particular thing to do for dialogs to work? I mean, maybe specifying where portal files are located...

Here I don't see any portal package as dependency.

As reported here, the app is built with:

cargo fetch --locked --target "$(rustc -vV | sed -n 's/host: //p')"
cargo build --frozen --release
cargo test --frozen
GyulyVGC commented 7 months ago

Honestly I don't know. Maybe it's better to ask @PolyMeilex or open an issue in the rfd repo.

PolyMeilex commented 7 months ago

Perhaps try to install zenity it is used in case portal backend fails.

Digitalone1 commented 7 months ago

Perhaps try to install zenity it is used in case portal backend fails.

Yes, it's working. Thanks.

But I suppose the issue still exists since the portal fails...

GyulyVGC commented 7 months ago

I'm happy you found a workaround. Thanks @PolyMeilex for the help.

Closing the issue here since it's been partially solved and it's not directly related with Sniffnet.

Digitalone1 commented 7 months ago

@orhun I suggest to add xdg-desktop-portal and zenity as sniffnet package dependency.

orhun commented 7 months ago

Done o7 thanks for the ping! 🐻