Protonvpn-cli issue

After installing updates this morning via pacman -Syu I get this return when trying to use protonvpn-cli:

[drew@archlabs-drew ~]$ protonvpn-cli c
Traceback (most recent call last):
  File "/usr/bin/protonvpn-cli", line 33, in <module>
    sys.exit(load_entry_point('protonvpn-cli==3.11.0', 'console_scripts', 'protonvpn-cli')())
  File "/usr/lib/python3.10/site-packages/protonvpn_cli/main.py", line 20, in main
    from .cli import ProtonVPNCLI
  File "/usr/lib/python3.10/site-packages/protonvpn_cli/cli.py", line 4, in <module>
    from proton.constants import VERSION as proton_version
ModuleNotFoundError: No module named 'proton'
[drew@archlabs-drew ~]$

What happened?

I believe python just got a big upgrade. Looks like your proton module/script is now broken.

1 Like

Yes, there was a massive python upgrade this morning. Gee thanks.
How to fix what it broke? Or do we wait for someone upstream to correct their error?

I re-installed protonvpn-cli but the issue persists.

Did you rebuild it or just re-install the old package?

See AUR (en) - protonvpn and follow the breadcrumbs.

Disclaimer: I don’t use protonvpn-cli.

I used sudo pacman -R protonvpn-cli to remove the existing installed package.
I then used baph -i protonvpn-cli-ng-git to re-install

Is this fixable? Or should I use Arch Archive to downgrade all packages to yesterday’s version?

Is that the correct package to install?

proton-cli-ng-git was last updated 2020-6-1

protonvpn-cli was last updated 2021-12-7 and is apparently the version maintained by ProtonVPN team.

A comment on the proton-cli-ng-git page:

The new official Linux CLI client is now available. Source code and AUR protonvpn-cli. Please upgrade to this client if possible.

As for this community version, I think it should be maintained here for a while longer as there have still been git changes over the last week. The latest version is 2.2.11. This package is now marked as conflicting with the official protonvpn-cli package.

Looks like you need the protonvpn-cli package; but it’s broken as well - read the comment, same error as yours.. May need to downgrade until it’s fixed.

Yes, I saw that. I installed proton-cli-ng-git thinking/hoping it might fix the issue. It didn’t so I removed it and installed protonvpn-cli again and it still doesn’t work.

I will downgrade protonvpn-cli to the previous version and hope someone fixes the python issue.

You going to have to downgrade all of python?

That is my fear and it’s beyond what I want to undertake. I think I will just install a different VPN app for the time being and wait for enough other people to notice the glitch and cause it to get repaired. I’ve been using the free version of protonvpn-cli so I guess I shouldn’t complain too loudly :slight_smile:

1 Like

In all likely hood it will be fixed in the next 24 hours.

2 Likes

But by then my cover could be blown, man :laughing:

2 Likes

I received this reply from the AUR Comment board:

shuriken commented on 2021-12-13 10:55

For Paru users run this command twice -

pacman -Qoq /usr/lib/python3.9 | paru -S - --rebuild

This will force rebuild of the python packages and will fix all the issues. The reason we run it twice is to update the dependency packages as well.

to verify that there is no package left run -

pacman -Qoq /usr/lib/python3.9

It should say no target specified if all the packages have been rebuilt with python 3.10."

Is there a way to do this with baph or do I need to install Paru?

No idea about baph but you can try building the protonvpn package manually:

pacman -Rns protonvpn
pacman -Syu git
mkdir -p ~/git/aur && cd $_
git clone https://aur.archlinux.org/protonvpn.git
cd protonvpn
makepkg -sri

I’ve never used any AUR helpers so I have no idea how they would interact with a manual build though.

Thanks. I ran those commands successfully but I still get this, which is exactly the same as previous:

[drew@archlabs-drew ~]$ protonvpn-cli c
Traceback (most recent call last):
  File "/usr/bin/protonvpn-cli", line 33, in <module>
    sys.exit(load_entry_point('protonvpn-cli==3.11.0', 'console_scripts', 'protonvpn-cli')())
  File "/usr/lib/python3.10/site-packages/protonvpn_cli/main.py", line 20, in main
    from .cli import ProtonVPNCLI
  File "/usr/lib/python3.10/site-packages/protonvpn_cli/cli.py", line 4, in <module>
    from proton.constants import VERSION as proton_version
ModuleNotFoundError: No module named 'proton'
[drew@archlabs-drew ~]$

Python is upgradedn 3.10. You need to rebuild all packages which depend on pythong 3.9.

$yay -S $(pacman -Qoq /usr/lib/python3.9) --answerclean All

or the following cmd if you use paru,

$pacman -Qoq /usr/lib/python3.9 | paru -S - --rebuild

Did you also rebuild the protonvpn-cli package?

I don’t have yay or paru installed. Can I do this with baph or do I need to install paru?

In AUR, protonvpn is the package with both cli and gui. There is a separate package protonvpn-cli which is the one I rebuilt using your commands because I only want the command line.

It’t up to you. Pretty sure you can use baph. You just need to find the correct options ( I don’t have baph installed).