{"id":15169292,"url":"https://github.com/ross-tsenov/python-project-template","last_synced_at":"2026-01-22T20:33:17.487Z","repository":{"id":227572096,"uuid":"771608481","full_name":"ross-tsenov/python-project-template","owner":"ross-tsenov","description":"A modern Python project template with essential tooling for development, testing, and documentation.","archived":false,"fork":false,"pushed_at":"2024-03-18T03:30:08.000Z","size":115,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-14T05:44:50.258Z","etag":null,"topics":["boilerplate","devcontainer","github","github-actions","logging","mkdocs","mypy","poetry","pre-commit","project-template","pydantic","pytest","python","python-project-template","ruff","template"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ross-tsenov.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-03-13T16:01:08.000Z","updated_at":"2024-03-18T03:30:17.000Z","dependencies_parsed_at":"2024-03-16T21:29:47.999Z","dependency_job_id":"54562d0e-ea49-4781-94f5-b9a98887e284","html_url":"https://github.com/ross-tsenov/python-project-template","commit_stats":null,"previous_names":["ross-tsenov/python-project-template"],"tags_count":0,"template":true,"template_full_name":null,"purl":"pkg:github/ross-tsenov/python-project-template","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ross-tsenov%2Fpython-project-template","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ross-tsenov%2Fpython-project-template/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ross-tsenov%2Fpython-project-template/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ross-tsenov%2Fpython-project-template/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ross-tsenov","download_url":"https://codeload.github.com/ross-tsenov/python-project-template/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ross-tsenov%2Fpython-project-template/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28670381,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-22T19:36:09.361Z","status":"ssl_error","status_checked_at":"2026-01-22T19:36:05.567Z","response_time":144,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["boilerplate","devcontainer","github","github-actions","logging","mkdocs","mypy","poetry","pre-commit","project-template","pydantic","pytest","python","python-project-template","ruff","template"],"created_at":"2024-09-27T07:01:09.937Z","updated_at":"2026-01-22T20:33:17.465Z","avatar_url":"https://github.com/ross-tsenov.png","language":"Python","readme":"# README for Python Project Template\r\n\r\nThis Python Project Template is designed to streamline the development process, focusing on best practices, code quality, and documentation. It employs a variety of tooling and a structured folder layout to ensure maintainability and ease of use. Below is an overview of its key components, tooling, folder structure, and useful commands to get you started.\r\n\r\n## Tooling\r\n\r\n- [**Poetry**](https://github.com/python-poetry/poetry): Used for dependency management and packaging, making it simple to manage project libraries and their versions.\r\n- [**Pydantic Settings**](https://github.com/pydantic/pydantic-settings): Loads and validates settings from `.env` files, ensuring configurations are both accessible and correctly typed.\r\n- [**Ruff**](https://github.com/astral-sh/ruff): A fast and comprehensive linter that checks for syntax errors and enforces style consistency.\r\n- [**Mypy**](https://github.com/python/mypy): A static type checker for Python, enhancing code quality and detect errors before runtime.\r\n- [**Pytest**](https://github.com/pytest-dev/pytest): The go-to framework for writing and running tests, ensuring your code behaves as expected.\r\n- [**Pre-commit**](https://github.com/pre-commit/pre-commit): Runs a series of checks (linting, formatting, type checking) before each commit to maintain code quality.\r\n- [**MkDocs**](https://github.com/mkdocs/mkdocs): Generates project documentation from Markdown files, making it easy to create and maintain up-to-date documentation.\r\n- [**Simple Logger**](https://docs.python.org/3/library/logging.html): A basic logging implementation that can be easily customized and integrated throughout the project.\r\n- [**Devcontainer**](https://github.com/microsoft/vscode-dev-containers): Supports development inside a Docker container in VSCode or GitHub Codespaces, providing a consistent and isolated development environment.\r\n- [**GitHub Actions**](https://github.com/features/actions): Automates linting, type checking, and testing workflows, ensuring that code meets quality standards before merging.\r\n\r\n## Folder Structure\r\n\r\n- `.devcontainer/`: Contains Docker configurations for the development environment, including a `Dockerfile` and `devcontainer.json` for container settings.\r\n- `.github/workflows/`: Stores CI configurations for automated linting, typing, and testing. It's extendable for additional workflows.\r\n- `docs/`: Holds MkDocs structured documentation, serving as the home for project documentation.\r\n  - `docs/assets/`: Stores images and other assets for the documentation.\r\n- `scripts/`: Typically includes utility bash scripts.\r\n- `src/`: The primary directory for project source code.\r\n  - `src/settings.py`: Manages application settings loaded and validated from `.env`.\r\n  - `src/logger.py`: Provides a global logger accessible throughout the project.\r\n- `tests/`: Contains test cases and fixtures for the project.\r\n  - `tests/conftest.py`: Defines reusable pytest fixtures.\r\n  - `tests/core.py`: Tests core functionalities like settings and logging.\r\n- `.env.sample`: An example `.env` file outlining required environment variables.\r\n- `.gitignore`: Specifies intentionally untracked files to ignore.\r\n- `.pre-commit-config.yaml`: Configures checks to run before commits.\r\n- `main.py`: The entry point for running the application.\r\n- `mkdocs.yml`: Configuration for MkDocs.\r\n- `pyproject.toml`: Specifies project settings, dependencies, and build information.\r\n\r\nSure, here are the useful commands with code blocks for better readability:\r\n\r\n### Useful Commands\r\n\r\n- **Poetry Commands**\r\n\r\n  Install dependencies:\r\n  ```bash\r\n  poetry install [--with dev] [--with docs]\r\n  ```\r\n\r\n\r\n- **Pre-commit Commands**\r\n\r\n  Install pre-commit hooks:\r\n  ```bash\r\n  pre-commit install\r\n  ```\r\n  Run all pre-commit hooks:\r\n  ```bash\r\n  pre-commit run --all-files\r\n  ```\r\n\r\n- **Mypy Commands**\r\n\r\n  Run type checking:\r\n  ```bash\r\n  mypy src/ tests/\r\n  ```\r\n\r\n- **Pytest Commands**\r\n\r\n  Run tests:\r\n  ```bash\r\n  pytest tests\r\n  ```\r\n\r\n- **MkDocs Commands**\r\n\r\n  Serve documentation locally:\r\n  ```bash\r\n  mkdocs serve\r\n  ```\r\n  Build static site:\r\n  ```bash\r\n  mkdocs build\r\n  ```\r\n\r\n- **Devcontainer Command**\r\n\r\n  To use the devcontainer, if you are using VSCode, follow these steps:\r\n  - Open the Command Palette (`Ctrl+Shift+P` or `Cmd+Shift+P` on macOS).\r\n  - Type and select \"Remote-Containers: Open Folder in Container\".\r\n\r\n  Alternatively, if you are using GitHub Codespaces, it will automatically use the `.devcontainer` configuration when you create a new codespace.\r\n\r\nThis project template is equipped with a robust set of tools and a clear structure to help you start your Python project on the right foot. Adjust and extend it as needed to fit your project requirements.\r\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fross-tsenov%2Fpython-project-template","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fross-tsenov%2Fpython-project-template","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fross-tsenov%2Fpython-project-template/lists"}