title: Getting AttributeError: module 'collections' has no attribute 'MutableMapping' while using any pip3 command on linux Python 3.10
body: <p>Hey I have installed latest python 3.10 and pip3 on my linux (Zorin os lite 15.3 X64) machine but whenever I try to use any pip3 command I get following error
  For example I use the command:</p>
  <blockquote>
  <p>pip3 freeze</p>
  </blockquote>
  <p>I get the following error:</p>
  <pre><code>Traceback (most recent call last):
    File &quot;/usr/bin/pip3&quot;, line 9, in &lt;module&gt;
      from pip import main
    File &quot;/usr/lib/python3/dist-packages/pip/__init__.py&quot;, line 22, in &lt;module&gt;
      from pip._vendor.requests.packages.urllib3.exceptions import DependencyWarning
    File &quot;/usr/lib/python3/dist-packages/pip/_vendor/__init__.py&quot;, line 73, in &lt;module&gt;
      vendored(&quot;pkg_resources&quot;)
    File &quot;/usr/lib/python3/dist-packages/pip/_vendor/__init__.py&quot;, line 33, in vendored
      __import__(modulename, globals(), locals(), level=0)
    File &quot;/usr/share/python-wheels/pkg_resources-0.0.0-py2.py3-none-any.whl/pkg_resources/__init__.py&quot;, line 77, in &lt;module&gt;
    File &quot;/usr/share/python-wheels/pkg_resources-0.0.0-py2.py3-none-any.whl/pkg_resources/_vendor/packaging/requirements.py&quot;, line 9, in &lt;module&gt;
    File &quot;&lt;frozen importlib._bootstrap&gt;&quot;, line 1027, in _find_and_load
    File &quot;&lt;frozen importlib._bootstrap&gt;&quot;, line 1006, in _find_and_load_unlocked
    File &quot;&lt;frozen importlib._bootstrap&gt;&quot;, line 672, in _load_unlocked
    File &quot;&lt;frozen importlib._bootstrap&gt;&quot;, line 632, in _load_backward_compatible
    File &quot;/usr/share/python-wheels/pkg_resources-0.0.0-py2.py3-none-any.whl/pkg_resources/extern/__init__.py&quot;, line 43, in load_module
    File &quot;/usr/share/python-wheels/pkg_resources-0.0.0-py2.py3-none-any.whl/pkg_resources/_vendor/pyparsing.py&quot;, line 943, in &lt;module&gt;
  AttributeError: module 'collections' has no attribute 'MutableMapping'
  </code></pre>
  <p>This was working fine with python 3.9 but when I updated to 3.10 I started getting this error. How can I solve this?</p>