To use Poetry for managing dependencies and virtual environments, follow these steps:
- Install Poetry by running the following command in your terminal:
curl -sSL https://install.python-poetry.org | python3 -
- Navigate to your project directory and initialize Poetry by running:
poetry init
-
Follow the prompts to provide information about your project.
-
Add dependencies to your project by running:
poetry add package_name
-
Poetry will automatically create a virtual environment for your project and install the specified package.
-
To activate the virtual environment, run:
poetry shell
- You can now run your Python server using Poetry.
poetry run dev
- pydantic
- pydantic-settings - provides optional Pydantic features for loading a settings or config class from environment variables or secrets files.
- typer - Typer, build great CLIs. Easy to code. Based on Python type hints.
- Gunicorn WSGI HTTP Server for unix
- docusarus - refer to this https://github.com/langflow-ai/langflow/blob/dev/docs/package.json
- sphinx - python documentation generator
cd docs
npx docusaurus start
Open http://localhost:3000 and follow the tutorial.
Look into poetry groups for managing dependencies over multiple environments