반응형
윈도우 환경에서 파이썬과 패키지 설치할때 오류로 패키지 설치가 안되는 현상
#### 파이썬 환경설정
1. 파이썬 인터프리터 설치
2. 프로젝트 폴더에 venv 생성 (터미널에 입력)
윈도우
python -m venv venv
맥
python3 -m venv venv
3. 필요한 패키지 설치
pip install 패키지명
패키지 설치시 에러났을때 (ERROR: Could not install packages due to an EnvironmentError)
1. 해당위치로 이동
C:\Users\User\AppData\Local\Programs\Python\Python38\Lib\site-packages\pip\_vendor\requests
2. sessions.py 파일에서 self.verify = False로 설정
3. 아래 명령어로 패키지 설치
pip install --trusted-host pypi.org --trusted-host files.pythonhosted.org
반응형
'TIL' 카테고리의 다른 글
[TIL] Git checkout, switch, restore, 깃로그 그래프로 보기 (0) | 2023.03.30 |
---|---|
[TIL] 깃 개념 재정리 (0) | 2023.03.30 |