installation – I cannot install conda in python

I type pip install conda in cmd but it came out like this :

Collecting conda
  Using cached conda-4.3.16.tar.gz (299 kB)
  Preparing metadata (setup.py) ... error
  error: subprocess-exited-with-error

  × python setup.py egg_info did not run successfully.
  │ exit code: 1
  ╰─> [18 lines of output]

      WARNING: Your current install method for conda only supports conda
      as a python library.  You are not installing a conda executable command
      or activate/deactivate commands.  If your intention is to install conda
      as a standalone application, currently supported install methods include
      the Anaconda installer and the miniconda installer.  If you'd still like
      for setup.py to create entry points for you, use `utils/setup-testing.py`.

      Traceback (most recent call last):
        File "<string>", line 2, in <module>
        File "<pip-setuptools-caller>", line 34, in <module>
        File "C:\Users\PHU PHUC\AppData\Local\Temp\pip-install-fr270g_y\conda_a287c5dfce9b412b845e064492896238\setup.py", line 35, in <module>
          import conda._vendor.auxlib.packaging  # NOQA
        File "C:\Users\PHU PHUC\AppData\Local\Temp\pip-install-fr270g_y\conda_a287c5dfce9b412b845e064492896238\conda\__init__.py", line 13, in <module>
          from .common.compat import iteritems, text_type
        File "C:\Users\PHU PHUC\AppData\Local\Temp\pip-install-fr270g_y\conda_a287c5dfce9b412b845e064492896238\conda\common\compat.py", line 77, in <module>
          from collections import Iterable
      ImportError: cannot import name 'Iterable' from 'collections' (C:\Users\PHU PHUC\AppData\Local\Programs\Python\Python310\lib\collections\__init__.py)
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

How can I fix it?
Thanks very much

Read more here: Source link