Junction icon indicating copy to clipboard operation
Junction copied to clipboard

Junction no longer opens unless it is open already

Open Sectimus opened this issue 1 month ago • 9 comments

Junction fails to load any links unless it has been loaded already (manually, without clicking a link)

#fails to open at all
$ junction https://www.example.com
#opens and then prompts for browser
$ junction
$ junction https://www.example.com

I've tried from source, using flatpak and also the aur package, all have the exact same result. This is a recent development and did not always behave this way.

The only thing of note, is without junction already loaded, when this bug occurs, the following GtkSettings warning is printed

$ junction https://www.example.com
>re.sonny.Junction-Message: 10:18:19.855: {
    "XDG_DATA_HOME": "/home/sectimus/.var/app/re.sonny.Junction/data",
    "XDG_DATA_DIRS": "/app/share:/usr/share:/usr/share/runtime/share:/run/host/user-share:/run/host/share:/run/host/usr/share:/var/lib/snapd/desktop:/var/lib/flatpak/exports/share:/home/sectimus/.local/share/flatpak/exports/share",
    "HOST_XDG_DATA_HOME": null,
    "HOST_XDG_DATA_DIRS": null
}
> (re.sonny.Junction:12614): Adwaita-WARNING **: 09:52:47.243: Using GtkSettings:gtk-application-prefer-dark-theme with libadwaita is unsupported. Please use AdwStyleManager:color-scheme instead.

Workaround for now is just to have the junction gui live on my system forever, not a great solution

Image

Junction: version 1.10 programInvocationName /app/bin/re.sonny.Junction argv --gapplication-service cwd /home/sectimus datadir /app/share

Powered by: GJS 1.86.0 libadwaita 1.8.1 GTK 4.20.2 GLib 2.86.0 flatpak 1.16.1

Environment: OS Arch Linux $XDG_DATA_DIRS /app/share:/usr/share:/usr/share/runtime/share:/run/host/user-share:/run/host/share:/run/host/usr/share:/var/lib/snapd/desktop:/var/lib/flatpak/exports/share:/home/sectimus/.local/share/flatpak/exports/share $PATH /app/bin:/usr/bin $FLATPAK_ID re.sonny.Junction $XDG_CURRENT_DESKTOP KDE $XDG_SESSION_TYPE wayland

Sectimus avatar Nov 05 '25 10:11 Sectimus

I'm experiencing the same problem on Arch. Tested with the arch package and with Flatpak.

dimas-cyriaco avatar Nov 05 '25 21:11 dimas-cyriaco

I'm experiencing the same but not on all apps. Clicking a link from Telegram works. Clicking it from Slack does not. My slack installation comes from a deb, and my Junction instalation comes from flatpak.

This command works:

/usr/bin/flatpak run \ --branch=stable \ --arch=x86_64 \ --command=re.sonny.Junction \ --file-forwarding \ re.sonny.Junction https://www.example.com

But I have no clue on how to check Junction logs when clicking a link from Slack.

With Junction opened, it does work from Slack.

EDIT

Logs when clicking in Telegram:

Nov  6 13:59:55 ws dbus-daemon[5124]: [session uid=1000 pid=5124] Activating service name='re.sonny.Junction' requested by ':1.27' (uid=1000 pid=5341 comm="/usr/libexec/xdg-desktop-portal " label="unconfined")
Nov  6 13:59:55 ws systemd[5099]: Started app-flatpak-re.sonny.Junction-120597.scope.
Nov  6 13:59:55 ws re.sonny.Junction[120605]: Failed to create file monitor for /home/user/.var/app/re.sonny.Junction/config/glib-2.0/settings/keyfile: No se pudo encontrar el tipo de monitorización del archivo local predeterminado
Nov  6 13:59:55 ws gjs[120605]: {#012    "XDG_DATA_HOME": "/home/user/.var/app/re.sonny.Junction/data",#012    "XDG_DATA_DIRS": "/app/share:/usr/share:/usr/share/runtime/share:/run/host/user-share:/run/host/share:/run/host/usr/share:/var/lib/snapd/desktop:/var/lib/flatpak/exports/share:/home/user/.local/share/flatpak/exports/share",#012    "HOST_XDG_DATA_HOME": null,#012    "HOST_XDG_DATA_DIRS": null#012}
Nov  6 13:59:55 ws dbus-daemon[5124]: [session uid=1000 pid=5124] Successfully activated service 're.sonny.Junction'
Nov  6 13:59:55 ws re.sonny.Junction[120620]: Set re.sonny.Junction.desktop as the default for x-scheme-handler/https
Nov  6 13:59:55 ws re.sonny.Junction[120623]: Set re.sonny.Junction.desktop as the default for x-scheme-handler/http
Nov  6 13:59:56 ws re.sonny.Junction[120605]: gtk_widget_set_parent: assertion '_gtk_widget_get_parent (widget) == NULL' failed
Nov  6 13:59:58 ws systemd[5099]: app-flatpak-re.sonny.Junction-120597.scope: Consumed 1.287s CPU time.

Logs when clicking in Slack:

Nov  6 14:00:20 ws systemd[5099]: Started Junction.
Nov  6 14:00:20 ws systemd[5099]: Started app-flatpak-re.sonny.Junction-120964.scope.

pmsobrado avatar Nov 06 '25 12:11 pmsobrado

Same issue. Started after recent update, running Arch. If junction is not already running, it starts then crashes silently:

xdg-open "https://github.com"
re.sonny.Junction-Message: 12:58:00.080: {
    "XDG_DATA_HOME": null,
    "XDG_DATA_DIRS": "/usr/local/share:/usr/share:/home/jon/.nix-profile/share:/nix/var/nix/profiles/default/share:/run/host/usr/share:/var/lib/snapd/desktop:/var/lib/flatpak/exports/share:/home/jon/.local/share/flatpak/exports/share",
    "HOST_XDG_DATA_HOME": null,
    "HOST_XDG_DATA_DIRS": null
}

(re.sonny.Junction:1208133): Adwaita-WARNING **: 12:58:00.966: Using GtkSettings:gtk-application-prefer-dark-theme with libadwaita is unsupported. Please use AdwStyleManager:color-scheme instead.

devnullvoid avatar Nov 10 '25 17:11 devnullvoid

This issue occurs on EndeavourOS as well. To resolve this issue temporarily, I have reverted back to an older version of the app using the following command:

sudo flatpak update \
              --commit=9b56ffc1f3d1420c3cb4b3de1cf092b9db944e7f9e7fba75b290e31d9cd1246b \
              re.sonny.Junction


flatpak mask re.sonny.Junction

Sriramgireesh avatar Nov 17 '25 13:11 Sriramgireesh

System: Debian 13 Version: 1.10 (Flathub)

I've noticed that the behavior seems to differ across frameworks. At least in my environment, GTK applications can pop up links normally in the background, while Qt applications must keep the Junction process running in the foreground.

goddaneel avatar Nov 24 '25 03:11 goddaneel

Same issue here

Can reproduce the workaround. (when I first open without arguments (dont close) and then open with arguments it works)

~$ flatpak list
Name                                               Application ID                                         Version                               Branch                   Installation
Sonny Piers                                        re.sonny.Junction                                      1.10                                  stable                   system
~$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 22.04.5 LTS
Release:        22.04
Codename:       jammy
~$ flatpak info --show-runtime re.sonny.Junction
org.gnome.Platform/x86_64/49

Altho I do currently run KDE and I believe this is the only gnome app I am currently using

ruzito avatar Nov 26 '25 11:11 ruzito

Same, the issue still persists.

Pdzly avatar Nov 26 '25 17:11 Pdzly

Was this new version tested at all?

REALERvolker1 avatar Dec 04 '25 18:12 REALERvolker1

Weird but potentially relevant issue: https://bugs.kde.org/show_bug.cgi?id=433681

The same bug happens for me on spectacle. When I screenshot, it can't copy to clipboard unless spectacle was opened manually first, same as this junction bug. So we could be looking at a problem with wayland all together?

this is also the case for yet another bug, where the "export to gwenview" button on spectacle causes a memory leak, it does not when opened manually first

Sectimus avatar Dec 06 '25 21:12 Sectimus

cc: @Sectimus

  1. The issue #205 does not seem as the same issue, as there the app does not start even with no arguments. So the workaround for this issue, doesn't work there.

  2. The issue you posted here (https://bugs.kde.org/show_bug.cgi?id=433681) also does not seem related much. It is a complete malfunction of a feature there. It just does not work on certain setups there. And it seems that the fix there was to use a propper multiplatform library for the functionality. Since this has a workaround, whatever the mechanism that breaks is, it is present in the app under some conditional path. My gut tells me this is either some issue with actual GUI instantiation (if the issue is with GTK or something) or it's just a broken code, plain old bug, that terminates the app for some reason when args are used.

ruzito avatar Dec 15 '25 08:12 ruzito