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

Spacedrive does not start (ERROR rspc::internal::jsonrpc_exec) #2726

Open
2 tasks done
kimjongbing opened this issue Sep 25, 2024 · 9 comments
Open
2 tasks done

Spacedrive does not start (ERROR rspc::internal::jsonrpc_exec) #2726

kimjongbing opened this issue Sep 25, 2024 · 9 comments
Assignees
Labels
app/desktop kind/bug Something isn't working status/needs-more-info Need more information about issue

Comments

@kimjongbing
Copy link

Check for other issues

  • I've checked for other issues, and none exist.

Issue description

When I launch Spacedrive, it closes immediately. I tried launching through CLI and saw an "authentication required" error.

cleaning localStorage
  2024-09-25T08:38:45.397913Z ERROR rspc::internal::jsonrpc_exec: Error executing operation: ErrResolverError(Error { code: InternalServerError, message: "Authentication required", cause: None })
    at /home/runner/.cargo/git/checkouts/rspc-264254b19e111e45/0018e80/src/internal/jsonrpc_exec.rs:223

It opens and when opening just closes.

Steps to reproduce

  1. Open spacedrive
  2. It will crash

Platform and versions

  • OS: NixOS 24.11.20240916.99dc878 (Vicuna) x86_64
  • Spacedrive: 0.4.2
Development tool versions (optional)
~/.dotfiles/n/s/m/home-manager main• ↑5 ❱ spacedrive
  2024-09-25T08:37:41.650597Z  INFO sd_core: Starting core;, data_directory: /home/nadeko/.local/share/spacedrive
    at core/src/lib.rs:100

  2024-09-25T08:37:41.651111Z  INFO sd_task_system::system: Task system online!, workers_count: 8
    at crates/task-system/src/system.rs:99

  2024-09-25T08:37:41.651702Z  INFO libp2p_swarm: local_peer_id: 12D3KooWLcWCUr5fWGMLrsJTkENqdYizVwLxNkwWf3n2GEef4sDV
    at /home/runner/.cargo/git/checkouts/rust-libp2p-5bf6f5083e224a9a/a005656/swarm/src/lib.rs:368

  2024-09-25T08:37:41.651770Z  INFO sd_core::p2p::manager: Setting quic ipv4 listener;, ipv4_port: None
    at core/src/p2p/manager.rs:219

  2024-09-25T08:37:41.651801Z  INFO sd_core::p2p::manager: Setting quic ipv6 listener;, ipv6_port: None
    at core/src/p2p/manager.rs:242

  2024-09-25T08:37:41.651838Z  INFO sd_core::p2p::manager: Node is now online listening;, remote_identity: oGaqfH9z1QTYren0lqFy9kqDbBN5/CXNrhTyXIp//JQ, peer_id: Libp2pPeerId(PeerId("12D3KooWLcWCUr5fWGMLrsJTkENqdYizVwLxNkwWf3n2GEef4sDV")), addresses: [Listener { id: ListenerId(0), name: "libp2p-quic", addrs: {} }]
    at core/src/p2p/manager.rs:104

  2024-09-25T08:37:41.669081Z  INFO sd_core: Spacedrive online!
    at core/src/lib.rs:225

  2024-09-25T08:37:41.689432Z  INFO sd_desktop::tauri_plugins: Internal server listening on: http://127.0.0.1:33457 http://127.0.0.1:38749 http://127.0.0.1:36911 http://127.0.0.1:34031
    at apps/desktop/src-tauri/src/tauri_plugins.rs:81

cleaning localStorage
  2024-09-25T08:37:41.958078Z ERROR rspc::internal::jsonrpc_exec: Error executing operation: ErrResolverError(Error { code: InternalServerError, message: "Authentication required", cause: None })
    at /home/runner/.cargo/git/checkouts/rspc-264254b19e111e45/0018e80/src/internal/jsonrpc_exec.rs:223

  2024-09-25T08:37:42.002091Z  INFO sd_core::p2p::manager: Updated p2p relay configuration successfully.
    at core/src/p2p/manager.rs:156

Gdk-Message: 18:37:42.084: Error 71 (Protocol error) dispatching to Wayland display.

Stack trace

No response

Additional context

Please let me know if any other information will be useful.

Code of Conduct

  • I agree to follow the Code of Conduct.
@kimjongbing kimjongbing added kind/bug Something isn't working status/needs-triage labels Sep 25, 2024
Copy link

linear bot commented Sep 25, 2024

@fogodev
Copy link
Member

fogodev commented Sep 25, 2024

Actually I think the main cause is the Gdk-Message: 18:37:42.084: Error 71 (Protocol error) dispatching to Wayland display. by the end of your logs

@kimjongbing
Copy link
Author

Actually I think the main cause is the Gdk-Message: 18:37:42.084: Error 71 (Protocol error) dispatching to Wayland display. by the end of your logs

I see. Is there anything I can do to help get more information about this for you?

@fogodev
Copy link
Member

fogodev commented Sep 25, 2024

Yeah, is this from the .deb official package or there are a specific package on NixOS for Spacedrive?

@HeavenVolkoff HeavenVolkoff self-assigned this Sep 26, 2024
@HeavenVolkoff
Copy link
Member

Hey @kimjongbing, a couple of questions:

  • What Desktop Environment are you using?

  • Does your PC have a Nvidia GPU? If so, can you post the output of nvidia-smi here?

  • Can you try executing glxgears and vkgears in the CLI and see if a window like the one bellow pops up for both commands:

You may need to install the package mesa-utils before executing the commands

image

  • if you try to execute env GSK_RENDERER=gl spacedrive, does the app work?

@HeavenVolkoff HeavenVolkoff added app/desktop status/needs-more-info Need more information about issue and removed status/needs-triage labels Sep 26, 2024
@kimjongbing
Copy link
Author

Yeah, is this from the .deb official package or there are a specific package on NixOS for Spacedrive?

Hi, this is from the unstable nixpkgs https://github.com/NixOS/nixpkgs/blob/nixos-unstable/pkgs/by-name/sp/spacedrive/package.nix#L41

What Desktop Environment are you using?

GNOME 46.4
Mutter (Wayland)

Does your PC have a Nvidia GPU? If so, can you post the output of nvidia-smi here?

Thu Sep 26 11:44:18 2024       
+-----------------------------------------------------------------------------------------+
| NVIDIA-SMI 560.35.03              Driver Version: 560.35.03      CUDA Version: 12.6     |
|-----------------------------------------+------------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id          Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |           Memory-Usage | GPU-Util  Compute M. |
|                                         |                        |               MIG M. |
|=========================================+========================+======================|
|   0  NVIDIA GeForce RTX 4070 Ti     Off |   00000000:26:00.0  On |                  N/A |
|  0%   44C    P5              9W /  285W |    1260MiB /  12282MiB |     17%      Default |
|                                         |                        |                  N/A |
+-----------------------------------------+------------------------+----------------------+
|   1  NVIDIA GeForce GTX 1070        Off |   00000000:27:00.0 Off |                  N/A |
|  0%   39C    P8             10W /  200W |       6MiB /   8192MiB |      0%      Default |
|                                         |                        |                  N/A |
+-----------------------------------------+------------------------+----------------------+
                                                                                         
+-----------------------------------------------------------------------------------------+
| Processes:                                                                              |
|  GPU   GI   CI        PID   Type   Process name                              GPU Memory |
|        ID   ID                                                               Usage      |
|=========================================================================================|
|    0   N/A  N/A      2284      G   ...xl-gnome-shell-46.4/bin/gnome-shell        425MiB |
|    0   N/A  N/A      2751      G   ...pb88rd-xwayland-24.1.2/bin/Xwayland         56MiB |
|    0   N/A  N/A      2955      G   GalaxyBudsClient                               19MiB |
|    0   N/A  N/A      3275      G   ...-firefox-130.0/bin/.firefox-wrapped        400MiB |
|    0   N/A  N/A      5668      G   /app/extra/zoom/zoom                           60MiB |
|    0   N/A  N/A      7135      G   ...yOnDemand --variations-seed-version         96MiB |
|    0   N/A  N/A     12011      G   ...8s0wpd6k-gnome-console-46.0/bin/kgx         50MiB |
|    0   N/A  N/A     12278      G   ...7ypq3yiiqi94pb1n-gjs-1.80.2/bin/gjs          3MiB |
|    1   N/A  N/A      2284      G   ...xl-gnome-shell-46.4/bin/gnome-shell          3MiB |
+-----------------------------------------------------------------------------------------+

Can you try executing glxgears and vkgears in the CLI and see if a window like the one bellow pops up for both commands:

Yep, both open up fine.

if you try to execute env GSK_RENDERER=gl spacedrive, does the app work?

No sadly. Here is the output:

❱ env GSK_RENDERER=gl spacedrive
  2024-09-26T01:51:05.125185Z  INFO sd_core: Starting core;, data_directory: /home/nadeko/.local/share/spacedrive
    at core/src/lib.rs:100

  2024-09-26T01:51:05.125729Z  INFO sd_task_system::system: Task system online!, workers_count: 8
    at crates/task-system/src/system.rs:99

  2024-09-26T01:51:05.126265Z  INFO libp2p_swarm: local_peer_id: 12D3KooWLcWCUr5fWGMLrsJTkENqdYizVwLxNkwWf3n2GEef4sDV
    at /home/runner/.cargo/git/checkouts/rust-libp2p-5bf6f5083e224a9a/a005656/swarm/src/lib.rs:368

  2024-09-26T01:51:05.126322Z  INFO sd_core::p2p::manager: Setting quic ipv4 listener;, ipv4_port: None
    at core/src/p2p/manager.rs:219

  2024-09-26T01:51:05.126332Z  INFO sd_core::p2p::manager: Setting quic ipv6 listener;, ipv6_port: None
    at core/src/p2p/manager.rs:242

  2024-09-26T01:51:05.126351Z  INFO sd_core::p2p::manager: Node is now online listening;, remote_identity: oGaqfH9z1QTYren0lqFy9kqDbBN5/CXNrhTyXIp//JQ, peer_id: Libp2pPeerId(PeerId("12D3KooWLcWCUr5fWGMLrsJTkENqdYizVwLxNkwWf3n2GEef4sDV")), addresses: [Listener { id: ListenerId(0), name: "libp2p-quic", addrs: {} }]
    at core/src/p2p/manager.rs:104

  2024-09-26T01:51:05.144203Z  INFO sd_core: Spacedrive online!
    at core/src/lib.rs:225

  2024-09-26T01:51:05.144340Z  INFO sd_desktop::tauri_plugins: Internal server listening on: http://127.0.0.1:41079 http://127.0.0.1:38471 http://127.0.0.1:46067 http://127.0.0.1:38361
    at apps/desktop/src-tauri/src/tauri_plugins.rs:81

cleaning localStorage
  2024-09-26T01:51:05.454381Z ERROR rspc::internal::jsonrpc_exec: Error executing operation: ErrResolverError(Error { code: InternalServerError, message: "Authentication required", cause: None })
    at /home/runner/.cargo/git/checkouts/rspc-264254b19e111e45/0018e80/src/internal/jsonrpc_exec.rs:223

  2024-09-26T01:51:05.544225Z  INFO sd_core::p2p::manager: Updated p2p relay configuration successfully.
    at core/src/p2p/manager.rs:156

Gdk-Message: 11:51:05.603: Error 71 (Protocol error) dispatching to Wayland display.

@HeavenVolkoff
Copy link
Member

There are a lot of recent reports on GTK apps about this issue happening for people with the latest version of the Nvidia drivers and the latest GTK and mesa:
https://bbs.archlinux.org/viewtopic.php?id=299488
https://gitlab.gnome.org/GNOME/gtk/-/issues/7010
https://gitlab.gnome.org/chergert/ptyxis/-/issues/204
https://forums.opensuse.org/t/gdk-message-error-71-protocol-error-dispatching-to-wayland-display/178886
https://discussion.fedoraproject.org/t/gdk-message-error-71-protocol-error-dispatching-to-wayland-display/127927/5

This mesa issue has more information:
https://gitlab.freedesktop.org/mesa/mesa/-/issues/11723

This seems to be either an Nvidia driver bug or a mesa bug. From comments, adding either GSK_RENDERER=gl or GSK_RENDERER=ngl to ~/.config/environment.d/gsk.conf should be a valid work-around while this bug is not fixed upstream.

@kimjongbing
Copy link
Author

There are a lot of recent reports on GTK apps about this issue happening for people with the latest version of the Nvidia drivers and the latest GTK and mesa: https://bbs.archlinux.org/viewtopic.php?id=299488 https://gitlab.gnome.org/GNOME/gtk/-/issues/7010 https://gitlab.gnome.org/chergert/ptyxis/-/issues/204 https://forums.opensuse.org/t/gdk-message-error-71-protocol-error-dispatching-to-wayland-display/178886 https://discussion.fedoraproject.org/t/gdk-message-error-71-protocol-error-dispatching-to-wayland-display/127927/5

This mesa issue has more information: https://gitlab.freedesktop.org/mesa/mesa/-/issues/11723

This seems to be either an Nvidia driver bug or a mesa bug. From comments, adding either GSK_RENDERER=gl or GSK_RENDERER=ngl to ~/.config/environment.d/gsk.conf should be a valid work-around while this bug is not fixed upstream.

Adding these does not seem to work for me

@sofiasmnk
Copy link

I believe I have the same issue. I'm also on NixOS with Spacedrive installed via nixpkgs-unstable, with GNOME and Wayland. And for me as well, running it with GSK_RENDERER=gl does not work.

I tried running it with WAYLAND_DEBUG=1, and this seems to be the part where a problem happens:

1825106.591] {Display Queue} wl_display#1.error(wp_linux_drm_syncobj_surface_v1#47, 2, "Explicit Sync only supported on dmabuf buffers")

In one of the links above, i see someone posted this:

This issue is limited to Intel/Nvidia hybrid graphics systems with the Nidia 560 driver (though I expect the same should happen on AMD/Nvidia, just haven't seen any reports that mention AMD).
I don't own a hybrid system to test so what follows is mostly educated guesses.
Because GSK_RENDERER=gl works, I suspect the issue is limited to Vulkan which is indeed the new default GSK renderer in Gtk4. But please verify that GSK_RENDERER=ngl also works to further isolate this to Vulkan.

And I immediately recognized that because that did happen to me, when I was stupid and plugged my monitor to my motherboard instead of my GPU, making my PC work with hybrid graphics. I had apps that weren't working - mainly the default GNOME apps, if i remember correctly - but then would work with GSK_RENDERER=gl. After I plugged my monitor to my GPU properly, I stopped having any issues, and all those apps work fine now, without needing GSK_RENDERER=gl.

But Spacedrive still isn't working, and running it with GSK_RENDERER=gl also doesn't work, so I believe this is a separate thing, though probably also related to NVIDIA/Wayland issues. (?)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
app/desktop kind/bug Something isn't working status/needs-more-info Need more information about issue
Projects
None yet
Development

No branches or pull requests

4 participants