Skip to content
This repository was archived by the owner on Nov 5, 2025. It is now read-only.
This repository was archived by the owner on Nov 5, 2025. It is now read-only.

[BUG] Python protonvpn-cli: Old user-level installation causes new root installation to raise an error, since it tries to look at the user-level ~/.-pvpn-cli file instead of the root level one #378

Description

@dmentock

I originally installed protonvpn-cli simply with pip in my local environment as a regular user, just to see that it requires sudo priviliges. I then logged in as root and reinstalled protonvpn-cli, but now I get the error

% sudo protonvpn 
Traceback (most recent call last):
  File "/usr/local/bin/protonvpn", line 5, in <module>
    from protonvpn_cli.cli import main
  File "/usr/local/lib/python3.12/dist-packages/protonvpn_cli/cli.py", line 59, in <module>
    from . import connection
  File "/usr/local/lib/python3.12/dist-packages/protonvpn_cli/connection.py", line 15, in <module>
    from .logger import logger
  File "/usr/local/lib/python3.12/dist-packages/protonvpn_cli/logger.py", line 40, in <module>
    logger = get_logger()
             ^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/dist-packages/protonvpn_cli/logger.py", line 20, in get_logger
    os.mkdir(CONFIG_DIR)
PermissionError: [Errno 13] Permission denied: '/home/my_local_user/.pvpn-cli'

I assume that the first installation wrote something to some global file, which is now picked up by the new root installation and causes it to look at the '/home/my_local_user/.pvpn-cli' directory instead of the root home directory. Is there anythinig we can do to ensure it cleanly uninstalls?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions