skip to Main Content

I believe that I installed Anaconda Naviagtor on linux correctly but it is getting stuck on loading applications….

(base) ben@Bens-PC:~$ anaconda-navigator
Traceback (most recent call last):
  File "/home/ben/anaconda3/lib/python3.7/site-packages/anaconda_navigator/widgets/main_window.py", line 541, in setup
    self.post_setup(conda_data=conda_data)
  File "/home/ben/anaconda3/lib/python3.7/site-packages/anaconda_navigator/widgets/main_window.py", line 578, in post_setup
    self.tab_home.setup(conda_data)
  File "/home/ben/anaconda3/lib/python3.7/site-packages/anaconda_navigator/widgets/tabs/home.py", line 169, in setup
    self.set_applications(applications, packages)
  File "/home/ben/anaconda3/lib/python3.7/site-packages/anaconda_navigator/widgets/tabs/home.py", line 204, in set_applications
    apps = self.api.process_apps(applications, prefix=self.current_prefix)
  File "/home/ben/anaconda3/lib/python3.7/site-packages/anaconda_navigator/api/anaconda_api.py", line 848, in process_apps
    app = app(config=self.config, process_api=self._process_api, conda_api=self._conda_api)
  File "/home/ben/anaconda3/lib/python3.7/site-packages/anaconda_navigator/api/external_apps/vscode.py", line 48, in __init__
    **kwargs
  File "/home/ben/anaconda3/lib/python3.7/site-packages/anaconda_navigator/api/external_apps/base.py", line 43, in __init__
    self.init()
  File "/home/ben/anaconda3/lib/python3.7/site-packages/anaconda_navigator/api/external_apps/base.py", line 60, in init
    SUBDIR, INST_EXT, INST_DIR = self._find_linux_install_dir()
  File "/home/ben/anaconda3/lib/python3.7/site-packages/anaconda_navigator/api/external_apps/vscode.py", line 168, in _find_linux_install_dir
    if DISTRO_NAME in ['ubuntu', 'debian']:
UnboundLocalError: local variable 'DISTRO_NAME' referenced before assignment

Any help would be great!

2

Answers


  1. Try

    conda update anaconda-navigator
    
    Login or Signup to reply.
  2. Open and Edit the file:
    "…/anaconda3/lib/python3.7/site-packages/anaconda_navigator/api/external_apps/vscode.py"

    Declare this in line 159.

    DISTRO_NAME = None

    Indent this line with the if statement above it.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search