읽어야하는 대상

1. FastAPI를 쓰려는 사람

2. anaconda, pyenv 를 쓰지않고 다른 가상환경을 쓰고싶은사람

 

 

Install FastAPI, Uvicorn

pip install fastapi
pip install uvicorn

Install Poetry

# MAC, Linux
curl -sSL [<https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py>](<https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py>) | python -

#Windows
Windows(Powershell)
(Invoke-WebRequest -Uri [<https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py>](<https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py>) -UseBasicParsing).Content | python -

Poetry init

poetry init

 

 

poetry shell

# 경로 : C:\\Users\\jjongguet\\AppData\\Local\\pypoetry\\Cache\\virtualenvs\\test-fastapi-jxjUSc-c-py3.8

 

Poetry 켜는법

C:\\Users\\jjongguet\\AppData\\Local\\pypoetry\\Cache\\virtualenvs\\test-fastapi-jxjUSc-c-py3.8\\Scripts\\activate
#해당경로 + \\Scripts\\activate

 

기타

poetry shell은 처음만들때, spawn할때 라는 2가지 상태를 가지는것같음.

poetry shell이 켜진상태처럼 보여도, 종종 지혼자 꺼질때가 있는것으로 생각되는데

이럴때는 poetry shell을 다시실행시켜서 spawn시키고, 다시 poetry shell을 켜주도록 하자

 

 

 

jjongguet