这是我的安装命令:
pip install pytest
下面是错误信息:
Defaulting to user installation because normal site-packages is not writeable
Requirement already satisfied: pytest in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (4.6.11)
Requirement already satisfied: more-itertools=4.0.0; python_version <= "2.7" in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from pytest) (5.0.0)
Requirement already satisfied: packaging in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from pytest) (20.4)
Requirement already satisfied: pathlib2>=2.2.0; python_version < "3.6" in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from pytest) (2.3.5)
Requirement already satisfied: funcsigs>=1.0; python_version < "3.0" in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from pytest) (1.0.2)
Requirement already satisfied: six>=1.10.0 in /System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python (from pytest) (1.12.0)
Requirement already satisfied: importlib-metadata>=0.12; python_version < "3.8" in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from pytest) (1.7.0)
Requirement already satisfied: py>=1.5.0 in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from pytest) (1.9.0)
Requirement already satisfied: atomicwrites>=1.0 in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from pytest) (1.4.0)
Requirement already satisfied: attrs>=17.4.0 in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from pytest) (19.3.0)
Requirement already satisfied: pluggy=0.12 in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from pytest) (0.13.1)
Requirement already satisfied: wcwidth in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from pytest) (0.2.5)
Requirement already satisfied: pyparsing>=2.0.2 in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from packaging->pytest) (2.4.7)
Requirement already satisfied: scandir; python_version < "3.5" in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from pathlib2>=2.2.0; python_version < "3.6"->pytest) (1.10.0)
Requirement already satisfied: configparser>=3.5; python_version < "3" in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from importlib-metadata>=0.12; python_version < "3.8"->pytest) (4.0.2)
Requirement already satisfied: zipp>=0.5 in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from importlib-metadata>=0.12; python_version < "3.8"->pytest) (1.2.0)
Requirement already satisfied: contextlib2; python_version < "3" in /Users/fanyan/Library/Python/2.7/lib/python/site-packages (from importlib-metadata>=0.12; python_version < "3.8"->pytest) (0.6.0.post1)
Collecting backports.functools-lru-cache>=1.2.1; python_version < "3.2"
Using cached backports.functools_lru_cache-1.6.1-py2.py3-none-any.whl (5.7 kB)
Installing collected packages: backports.functools-lru-cache
Successfully installed backports.functools-lru-cache-1.6.1