Skip to content

Akagi201/poetry-template

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

poetry template

New project

poetry new

poetry new poetry-template --src --name=poetry-template

or poetry init inside a folder

poetry init

Create .gitignore

curl -L https://www.toptal.com/developers/gitignore/api/python > .gitignore

Poetry env

poetry env info
poetry install # install all dependencies in the virtualenv
poetry shell # spawn a shell within the virtual environment
poetry show # show all packages
poetry update # update all packages
python src/poetry_template/main.py
# or simpl
poetry run python src/poetry_template/main.py
poetry build # package the project
poetry publish # publish the project

Add packages

poetry add <package>
poetry add ./lib/<package>

Install dependencies

poetry install --with jupyterlab
poetry install --only main

Jupyter

If use conda packages, use a separate venv in mini-conda

poetry run jupyter lab src/notebooks

requirements.txt generation

poetry export --without-hashes --with dev --format=requirements.txt > requirements.txt

Python Libs

  • dask - Parallel computing
  • FFTW - FFT Wrapper
  • httpx - next generation HTTP client lib and cli
  • aiohttp - Asyncio http client/server
  • websockets - websockets client and server library
  • aiogram - Asyncio telegram bot framework
  • loguru - simple json logger
  • Typer - cli parser

Python tools

  • mypy - Static type checker
  • ruff - Python linter and formatter
  • erg - Rust like lang can interop with python
  • pylyzer - alternative to mypy
  • pixi - conda dep manager tool
  • rvp - alternative to poetry
  • unpack - Unpack python packages

Python Books

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published