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

Starting a systemd service to open the protonvpn causes the application to start with issues. #88

Closed
2 tasks done
maremike opened this issue Dec 31, 2024 · 1 comment
Closed
2 tasks done

Comments

@maremike
Copy link

maremike commented Dec 31, 2024

We are happy to answer your questions about the code or discuss technical ideas.

Please complete the following checklist (by adding [x]):

  • I have searched open and closed issues for duplicates
  • This isn't a feature request
  • [ ] This is not a report about my app not working as expected

PC1: Fedora 41 & Gnome 47
PC2: Debian 12 & KDE Plasma 5.103.0

Im trying to start protonvpn at boot using a systemd service. I got the app to work on my debian machine, but I am struggling with fedora. I used the same scripts for both. The applications start on both OS', but on Fedora I get the error

Something went wrong. An unexpected error occurred
. It says constantly
Loading App...
on the interface and does not show to current servers. When pressing "Quick Connect", the same error (Something went wrong. An unexpected error occurred) reappears. If I enable the service and reboot, the application does not start (not visible in the system tray)

This is the service file:

"/etc/systemd/system/proton-vpn.service" (even if I change from fork to simple nothing changes) [Unit]

Description=ProtonVPN Client
After=network.target

[Service]
Type=fork
ExecStart=/bin/protonvpn-app
Restart=on-failure
EnvironmentFile=/etc/default/protonvpn
User=username
Group=username

[Install]
WantedBy=default.target

The environment file:
"/etc/default/protonvpn" XDG_RUNTIME_DIR=/run/user/1000

DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus

On Fedora I get the following journalctl output:

"journalctl -u proton-vpn.service" Started proton-vpn.service - ProtonVPN Client. Dec 30 22:51:41 apollo protonvpn-app[11557]: 2024-12-30T21:51:41.590836+00:00 | proton.vpn.core.connection:459 | INFO | CONN:STATE_CHANGED | Disconnected (initial state) Dec 30 22:51:41 apollo protonvpn-app[11557]: 2024-12-30T21:51:41.592173+00:00 | proton.vpn.app.gtk.app:57 | INFO | APP:PROCESS_START | self= Dec 30 22:51:41 apollo protonvpn-app[11557]: 2024-12-30T21:51:41.645333+00:00 | proton.vpn.app.gtk.widgets.main.tray_indicator:45 | INFO | AyanaAppIndicator3 not found: Namespa> Dec 30 22:51:41 apollo protonvpn-app[11557]: 2024-12-30T21:51:41.648199+00:00 | proton.vpn.core.refresher.vpn_data_refresher:167 | INFO | APP.VPN_DATA_REFRESHER:ENABLE | VPN da> Dec 30 22:51:41 apollo protonvpn-app[11557]: 2024-12-30T21:51:41.648347+00:00 | proton.vpn.core.refresher.vpn_data_refresher:175 | INFO | Next client config refresh scheduled i> Dec 30 22:51:41 apollo protonvpn-app[11557]: 2024-12-30T21:51:41.648433+00:00 | proton.vpn.core.refresher.vpn_data_refresher:184 | INFO | Next server list refresh scheduled in > Dec 30 22:51:41 apollo protonvpn-app[11557]: 2024-12-30T21:51:41.648981+00:00 | proton.vpn.core.refresher.vpn_data_refresher:193 | INFO | Next certificate refresh scheduled in > Dec 30 22:51:41 apollo protonvpn-app[11557]: 2024-12-30T21:51:41.649072+00:00 | proton.vpn.core.refresher.vpn_data_refresher:202 | INFO | Next feature flags refresh scheduled i> Dec 30 22:51:41 apollo protonvpn-app[11557]: 2024-12-30T21:51:41.649397+00:00 | proton.vpn.session.utils:107 | INFO | API:REQUEST | '/vpn/v1/loads' Dec 30 22:51:41 apollo protonvpn-app[11557]: 2024-12-30T21:51:41.667475+00:00 | dbus.proxies:407 | ERROR | Introspect error on :1.16:/org/freedesktop/login1/seat/auto: dbus.exc> Dec 30 22:51:41 apollo protonvpn-app[11557]: 2024-12-30T21:51:41.667962+00:00 | proton.vpn.app.gtk.utils.exception_handler:257 | CRITICAL | APP:CRASH | Unexpected error. Dec 30 22:51:41 apollo protonvpn-app[11557]: Traceback (most recent call last): Dec 30 22:51:41 apollo protonvpn-app[11557]: File "/usr/lib/python3.13/site-packages/proton/vpn/app/gtk/widgets/vpn/vpn_widget.py", line 183, in _on_refresher_enabled Dec 30 22:51:41 apollo protonvpn-app[11557]: self.display(self._controller.user_tier, self._controller.server_list) Dec 30 22:51:41 apollo protonvpn-app[11557]: ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Dec 30 22:51:41 apollo protonvpn-app[11557]: File "/usr/lib/python3.13/site-packages/proton/vpn/app/gtk/widgets/vpn/vpn_widget.py", line 205, in display Dec 30 22:51:41 apollo protonvpn-app[11557]: self._controller.reconnector.enable() Dec 30 22:51:41 apollo protonvpn-app[11557]: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^ Dec 30 22:51:41 apollo protonvpn-app[11557]: File "/usr/lib/python3.13/site-packages/proton/vpn/app/gtk/services/reconnector/reconnector.py", line 93, in enable Dec 30 22:51:41 apollo protonvpn-app[11557]: self._session_monitor.enable() Dec 30 22:51:41 apollo protonvpn-app[11557]: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^ Dec 30 22:51:41 apollo protonvpn-app[11557]: File "/usr/lib/python3.13/site-packages/proton/vpn/app/gtk/services/reconnector/session_monitor.py", line 61, in enable Dec 30 22:51:41 apollo protonvpn-app[11557]: self._setup() Dec 30 22:51:41 apollo protonvpn-app[11557]: ~~~~~~~~~~~^^ Dec 30 22:51:41 apollo protonvpn-app[11557]: File "/usr/lib/python3.13/site-packages/proton/vpn/app/gtk/services/reconnector/session_monitor.py", line 102, in _setup Dec 30 22:51:41 apollo protonvpn-app[11557]: seat_properties = seat_auto_properties_proxy.GetAll(SEAT_INTERFACE) Dec 30 22:51:41 apollo protonvpn-app[11557]: File "/usr/lib64/python3.13/site-packages/dbus/proxies.py", line 72, in __call__ Dec 30 22:51:41 apollo protonvpn-app[11557]: return self._proxy_method(*args, **keywords) Dec 30 22:51:41 apollo protonvpn-app[11557]: ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^ Dec 30 22:51:41 apollo protonvpn-app[11557]: File "/usr/lib64/python3.13/site-packages/dbus/proxies.py", line 141, in __call__ Dec 30 22:51:41 apollo protonvpn-app[11557]: return self._connection.call_blocking(self._named_service, Dec 30 22:51:41 apollo protonvpn-app[11557]: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^ Dec 30 22:51:41 apollo protonvpn-app[11557]: self._object_path, Dec 30 22:51:41 apollo protonvpn-app[11557]: ^^^^^^^^^^^^^^^^^^ Dec 30 22:51:41 apollo protonvpn-app[11557]: ...<3 lines>... Dec 30 22:51:41 apollo protonvpn-app[11557]: args, Dec 30 22:51:41 apollo protonvpn-app[11557]: ^^^^^ Dec 30 22:51:41 apollo protonvpn-app[11557]: **keywords) Dec 30 22:51:41 apollo protonvpn-app[11557]: ^^^^^^^^^^^ Dec 30 22:51:41 apollo protonvpn-app[11557]: File "/usr/lib64/python3.13/site-packages/dbus/connection.py", line 634, in call_blocking Dec 30 22:51:41 apollo protonvpn-app[11557]: reply_message = self.send_message_with_reply_and_block( Dec 30 22:51:41 apollo protonvpn-app[11557]: message, timeout) Dec 30 22:51:41 apollo protonvpn-app[11557]: dbus.exceptions.DBusException: org.freedesktop.DBus.Error.UnknownObject: Unknown object '/org/freedesktop/login1/seat/auto'. Dec 30 22:51:41 apollo protonvpn-app[11557]: 2024-12-30T21:51:41.677092+00:00 | proton.vpn.app.gtk.services.reconnector.reconnector:174 | INFO | Network connectivity was detect> Dec 30 22:51:43 apollo protonvpn-app[11557]: 2024-12-30T21:51:43.097837+00:00 | proton.vpn.session.utils:111 | INFO | API:RESPONSE | '/vpn/v1/loads' Dec 30 22:51:43 apollo protonvpn-app[11557]: 2024-12-30T21:51:43.309372+00:00 | proton.vpn.core.refresher.server_list_refresher:76 | INFO | Next server list refresh scheduled i> Dec 30 22:51:51 apollo systemd[1]: proton-vpn.service: Deactivated successfully.
What I think is the most interesting here is:
dbus.exceptions.DBusException: org.freedesktop.DBus.Error.UnknownObject: Unknown object '/org/freedesktop/login1/seat/auto'.

I also use portmaster and it boots at startup by default without any issues on both systems. It would be best, if a setting would have been included to boot at startup. Its a simple script (presumably no bugs are caused).
(I posted this already on another issue, but I figured this requires its own issue due to my issue causing a different bug)

@calexandru2018
Copy link
Member

Closing as it is duplicate of #82

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants