Python version help

Hi everyone. I have a question about Python version in Clear Linux. I am still a Linux amateur.

I am farming Chia cryptocurrency and the various forks of Chia. Some are compatible with python 3.10 and then I have some that only work with Python 3.8.

So, I have the latest Clear Linux version. Should I revert back to the last version that used Python 3.8, or how can I install python 3.8. Can the forks be installed by specifying the Python version?

Please elaborate clearly, since I have very basic Linux knowledge.

Thanks

Hi @cmhservices ,

Please check my previous answer

sudo swupd bundle-add conda

Thanks @Businux for the help. I watched the video and a few others. I am unable to create any environments showed in the tutorials I have watched. I keep getting an error:

conda create ==name py38
WARNING: A directory already exists at the target location ‘/usr’
but it is not a conda environment.
Continue creating environment (y/[n])? y

>>>>>>>>>>>>>>>>>>>>>> ERROR REPORT <<<<<<<<<<<<<<<<<<<<<<

Traceback (most recent call last):
  File "/usr/lib/python3.10/site-packages/conda/exceptions.py", line 1080, in __call__
    return func(*args, **kwargs)
  File "/usr/lib/python3.10/site-packages/conda/cli/main.py", line 84, in _main
    exit_code = do_call(args, p)
  File "/usr/lib/python3.10/site-packages/conda/cli/conda_argparse.py", line 83, in do_call
    return getattr(module, func_name)(args, parser)
  File "/usr/lib/python3.10/site-packages/conda/cli/main_create.py", line 41, in execute
    install(args, parser, 'create')
  File "/usr/lib/python3.10/site-packages/conda/cli/install.py", line 116, in install
    if context.use_only_tar_bz2:
  File "/usr/lib/python3.10/site-packages/conda/base/context.py", line 746, in use_only_tar_bz2
    import conda_package_handling.api
ModuleNotFoundError: No module named 'conda_package_handling'

$ /usr/bin/conda create ==name py38

environment variables:
CIO_TEST=
CONDA_DEFAULT_ENV=base
CONDA_EXE=/usr/bin/conda
CONDA_PREFIX=/usr
CONDA_PROMPT_MODIFIER=(base)
CONDA_PYTHON_EXE=/usr/bin/python
CONDA_ROOT=/usr
CONDA_SHLVL=1
CURL_CA_BUNDLE=
JAVA_INCLUDE_PATH=/usr/lib/jvm/java-1.18.0/include
LA_PATH=/usr/lib64/
MPI_PATH=/usr/lib64/
PATH=/usr/bin:/usr/bin:/usr/condabin:/usr/bin/haswell:/usr/local/bin:/usr/b
in:/opt/3rd-party/bin:/home/cmhservices/Chia/forktools:/home/cmhservic
es/Chia/forktools
PYTHONIOENCODING=utf-8:surrogateescape
REQUESTS_CA_BUNDLE=
SSL_CERT_FILE=
WINDOWPATH=2

 active environment : base
active env location : /usr
        shell level : 1
   user config file : /home/cmhservices/.condarc

populated config files :
conda version : 4.11.0
conda-build version : not installed
python version : 3.10.6.final.0
virtual packages : __linux=5.19.1=0
__glibc=2.36=0
__unix=0=0
__archspec=1=x86_64
base environment : /usr (read only)
conda av data dir : /usr/etc/conda
conda av metadata url : None
channel URLs : main/linux-64
main/noarch
r/linux-64
r/noarch
package cache : /usr/pkgs
/home/cmhservices/.conda/pkgs
envs directories : /home/cmhservices/.conda/envs
/usr/envs
platform : linux-64
user-agent : conda/4.11.0 requests/2.28.1 CPython/3.10.6 Linux/5.19.1-1175.native clear-linux-os/36820 glibc/2.36
UID:GID : 1000:1000
netrc file : None
offline mode : False

An unexpected error has occurred. Conda has prepared the above report.

If submitted, this report will be used by core maintainers to improve
future releases of conda.
Would you like conda to send this report to the core maintainers?

Thanks for the help @rfkspada . I am unable to create any environments with Conda. I keep getting an error with every single command:

conda create ==name py38
WARNING: A directory already exists at the target location ‘/usr’
but it is not a conda environment.
Continue creating environment (y/[n])? y

>>>>>>>>>>>>>>>>>>>>>> ERROR REPORT <<<<<<<<<<<<<<<<<<<<<<

Traceback (most recent call last):
  File "/usr/lib/python3.10/site-packages/conda/exceptions.py", line 1080, in __call__
    return func(*args, **kwargs)
  File "/usr/lib/python3.10/site-packages/conda/cli/main.py", line 84, in _main
    exit_code = do_call(args, p)
  File "/usr/lib/python3.10/site-packages/conda/cli/conda_argparse.py", line 83, in do_call
    return getattr(module, func_name)(args, parser)
  File "/usr/lib/python3.10/site-packages/conda/cli/main_create.py", line 41, in execute
    install(args, parser, 'create')
  File "/usr/lib/python3.10/site-packages/conda/cli/install.py", line 116, in install
    if context.use_only_tar_bz2:
  File "/usr/lib/python3.10/site-packages/conda/base/context.py", line 746, in use_only_tar_bz2
    import conda_package_handling.api
ModuleNotFoundError: No module named 'conda_package_handling'

$ /usr/bin/conda create ==name py38

environment variables:
CIO_TEST=
CONDA_DEFAULT_ENV=base
CONDA_EXE=/usr/bin/conda
CONDA_PREFIX=/usr
CONDA_PROMPT_MODIFIER=(base)
CONDA_PYTHON_EXE=/usr/bin/python
CONDA_ROOT=/usr
CONDA_SHLVL=1
CURL_CA_BUNDLE=
JAVA_INCLUDE_PATH=/usr/lib/jvm/java-1.18.0/include
LA_PATH=/usr/lib64/
MPI_PATH=/usr/lib64/
PATH=/usr/bin:/usr/bin:/usr/condabin:/usr/bin/haswell:/usr/local/bin:/usr/b
in:/opt/3rd-party/bin:/home/cmhservices/Chia/forktools:/home/cmhservic
es/Chia/forktools
PYTHONIOENCODING=utf-8:surrogateescape
REQUESTS_CA_BUNDLE=
SSL_CERT_FILE=
WINDOWPATH=2

 active environment : base
active env location : /usr
        shell level : 1
   user config file : /home/cmhservices/.condarc

populated config files :
conda version : 4.11.0
conda-build version : not installed
python version : 3.10.6.final.0
virtual packages : __linux=5.19.1=0
__glibc=2.36=0
__unix=0=0
__archspec=1=x86_64
base environment : /usr (read only)
conda av data dir : /usr/etc/conda
conda av metadata url : None
channel URLs : main/linux-64
main/noarch
r/linux-64
r/noarch
package cache : /usr/pkgs
/home/cmhservices/.conda/pkgs
envs directories : /home/cmhservices/.conda/envs
/usr/envs
platform : linux-64
user-agent : conda/4.11.0 requests/2.28.1 CPython/3.10.6 Linux/5.19.1-1175.native clear-linux-os/36820 glibc/2.36
UID:GID : 1000:1000
netrc file : None
offline mode : False

An unexpected error has occurred. Conda has prepared the above report.

If submitted, this report will be used by core maintainers to improve
future releases of conda.
Would you like conda to send this report to the core maintainers?

There are some clues ($path, permissions, no sudo) in this thread :

Hi @cmhservices,

First, I am not sure if you are using the command as sudo. If yes, don’t do it, and if no, maybe it is a permission problem.

Take a look at:

https://conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html#creating-an-environment-with-commands

I would create a folder as /home/user/.condaenvs or something like it and use this prefix to install the new python encironment. Maybe

conda create --name py38 --prefix /home/user/.condaenvs/ python=3.8

works for you.