From 23da5c8c0f85e8b91bb0a24f63ad24ec99b0dd1e Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 13:05:36 -0700 Subject: [PATCH 01/15] :memo: :cookie: Move automation tools to workflow orchestration section --- README.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 11c55c132..522398b0d 100644 --- a/README.md +++ b/README.md @@ -107,6 +107,12 @@ Standardized Developer Workflow Orchestration via self-documenting [Makefile](./{{cookiecutter.project_slug}}/Makefile) - Automated Cookiecutter template synchronization with [cruft](https://cruft.github.io/cruft/) +- Test automation + with [Tox](https://tox.readthedocs.io/en/latest/) +- Code quality tooling automation and management + with [pre-commit](https://pre-commit.com/) +- Continuous integration and deployment + with [`GitHub Actions`](https://github.com/features/actions) Conditionally Rendered Python Package/Project Boilerplate --------------------------------------------------------- @@ -157,8 +163,6 @@ Type Checking and Data Validation Testing ------- -- Test automation - with [Tox](https://tox.readthedocs.io/en/latest/) - Testing with [pytest](https://docs.pytest.org/en/latest/) - Doctests @@ -195,8 +199,6 @@ Security Linting ------- -- Automation and management - with [pre-commit](https://pre-commit.com/) - Code quality: - [FlakeHell](https://github.com/life4/flakehell) - [Pylint](https://www.pylint.org/)[†](#jupyter-compatibility-via-nbqa) @@ -220,8 +222,6 @@ Linting CI/CD ----- -- Continuous integration - with [`GitHub Actions`](https://github.com/features/actions) - Automated Docker image builds and pushes to [Docker Hub](https://hub.docker.com/)[‡](#repo-secret-required) - Automated uploads From 2f1983fac053071e16bb9e36d9afebc6e0ffda92 Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 13:07:19 -0700 Subject: [PATCH 02/15] :memo: :cookie: Update new project creation section wording/formatting --- README.md | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 522398b0d..8e11d3a87 100644 --- a/README.md +++ b/README.md @@ -46,7 +46,7 @@ Table of Contents -- [Initializing a New Project](#initializing-a-new-project) +- [Creating a New Project](#creating-a-new-project) - [Linking an Existing Project](#linking-an-existing-project) - [Features](#features) * [Standardized Developer Workflow Orchestration](#standardized-developer-workflow-orchestration) @@ -65,18 +65,20 @@ Table of Contents -Initializing a New Project +Creating a New Project =========================== - Via [`cruft`](https://cruft.github.io/cruft/) (recommended): + ```shell script cruft create https://github.com/TeoZosa/cookiecutter-cruft-poetry-tox-pre-commit-ci-cd ``` Via [`cookiecutter`](https://github.com/audreyr/cookiecutter): + ```shell script cookiecutter gh:TeoZosa/cookiecutter-cruft-poetry-tox-pre-commit-ci-cd ``` + Note: **_Cookiecutter_** uses `gh:` as short-hand for `https://github.com/` Linking an Existing Project @@ -91,6 +93,7 @@ cruft link https://github.com/TeoZosa/cookiecutter-cruft-poetry-tox-pre-commit-c ``` Then/else: + ```shell script cruft update ``` From b1554c757182364cd8f5f058955ac7bb1a4c8f3a Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 13:08:19 -0700 Subject: [PATCH 03/15] :memo: :cookie: Update self-documenting Makefile instructions --- README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 8e11d3a87..d0f4744a9 100644 --- a/README.md +++ b/README.md @@ -107,7 +107,9 @@ Standardized Developer Workflow Orchestration with [Poetry](https://python-poetry.org/) - Project workflow orchestration with [Make](https://www.gnu.org/software/make/) - via self-documenting [Makefile](./{{cookiecutter.project_slug}}/Makefile) + - Self-documenting [Makefile](./{{cookiecutter.project_slug}}/Makefile); just type + `make` on the command line to display auto-generated documentation on available + targets - Automated Cookiecutter template synchronization with [cruft](https://cruft.github.io/cruft/) - Test automation From 920754c14aab2221641acbb3674cab5973d8c809 Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 13:09:22 -0700 Subject: [PATCH 04/15] :memo: :cookie: Rename "Standardized Developer Workflow Orchestration" section --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index d0f4744a9..99a8e1f0c 100644 --- a/README.md +++ b/README.md @@ -49,7 +49,7 @@ Table of Contents - [Creating a New Project](#creating-a-new-project) - [Linking an Existing Project](#linking-an-existing-project) - [Features](#features) - * [Standardized Developer Workflow Orchestration](#standardized-developer-workflow-orchestration) + * [Developer Workflow Automation](#developer-workflow-automation) * [Conditionally Rendered Python Package/Project Boilerplate](#conditionally-rendered-python-packageproject-boilerplate) * [Docker Image Build/Push/Deploy Orchestration](#docker-image-buildpushdeploy-orchestration) * [Monitoring and Observability](#monitoring-and-observability) @@ -101,8 +101,8 @@ cruft update Features ======== -Standardized Developer Workflow Orchestration ---------------------------------------------- +Developer Workflow Automation +----------------------------- - Packaging and dependency management with [Poetry](https://python-poetry.org/) - Project workflow orchestration From 4d948644af9043c8e707a1576353e6d14f2c32ae Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 13:11:07 -0700 Subject: [PATCH 05/15] :memo: :cookie: Update Poetry description --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 99a8e1f0c..0a76ac8cf 100644 --- a/README.md +++ b/README.md @@ -103,7 +103,7 @@ Features Developer Workflow Automation ----------------------------- -- Packaging and dependency management +- Python packaging and dependency management with [Poetry](https://python-poetry.org/) - Project workflow orchestration with [Make](https://www.gnu.org/software/make/) From 735823f593525e4bf5fdeeb1e4f06ade3c6dafbe Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 13:13:22 -0700 Subject: [PATCH 06/15] :memo: :cookie: Merge Docker-specific orchestration section elements --- README.md | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/README.md b/README.md index 0a76ac8cf..817840068 100644 --- a/README.md +++ b/README.md @@ -51,7 +51,6 @@ Table of Contents - [Features](#features) * [Developer Workflow Automation](#developer-workflow-automation) * [Conditionally Rendered Python Package/Project Boilerplate](#conditionally-rendered-python-packageproject-boilerplate) - * [Docker Image Build/Push/Deploy Orchestration](#docker-image-buildpushdeploy-orchestration) * [Monitoring and Observability](#monitoring-and-observability) * [Type Checking and Data Validation](#type-checking-and-data-validation) * [Testing](#testing) @@ -123,15 +122,10 @@ Conditionally Rendered Python Package/Project Boilerplate --------------------------------------------------------- - Command-line interface with [Typer](https://typer.tiangolo.com/) -- [Optional] [Jupyter](https://jupyter.org/) support[*](#conditional-rendering) - -Docker Image Build/Push/Deploy Orchestration --------------------------------------------- - Project-specific Dockerfile[*](#conditional-rendering) that installs production dependencies for a completely reproducible execution environment -- `build`/`push`/`pull`/`deploy` logic abstracted into corresponding `make` - targets, providing full automation with minimal friction +- [Optional] [Jupyter](https://jupyter.org/) support[*](#conditional-rendering) Monitoring and Observability ---------------------------- From 06ebd51a73cccba2f8a8f3ed00ca0528faa321c5 Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 13:16:26 -0700 Subject: [PATCH 07/15] :memo: :cookie: Merge "Testing" and "Coverage" sections --- README.md | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/README.md b/README.md index 817840068..410c21e56 100644 --- a/README.md +++ b/README.md @@ -53,8 +53,7 @@ Table of Contents * [Conditionally Rendered Python Package/Project Boilerplate](#conditionally-rendered-python-packageproject-boilerplate) * [Monitoring and Observability](#monitoring-and-observability) * [Type Checking and Data Validation](#type-checking-and-data-validation) - * [Testing](#testing) - * [Code Coverage](#code-coverage) + * [Testing/Coverage](#testingcoverage) * [Security](#security) * [Linting](#linting) * [CI/CD](#cicd) @@ -160,8 +159,8 @@ Type Checking and Data Validation - See [the test benchmarks](./tests/test_icontract_benchmark.py) for [example performance overhead measurements](https://teozosa.github.io/cookiecutter-cruft-poetry-tox-pre-commit-ci-cd/dev/py39-benchmark/) -Testing -------- +Testing/Coverage +---------------- - Testing with [pytest](https://docs.pytest.org/en/latest/) - Doctests @@ -183,8 +182,6 @@ Testing > and the > [follow-up by the `mutmut` author](https://stackoverflow.com/a/61849772/6470891). -Code Coverage -------------- - Code coverage with [Coverage.py](https://coverage.readthedocs.io/) - Coverage reporting From 9ccf37d14ea5a7cb6c994fdf7d7fd25dd78b2dbe Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 13:19:54 -0700 Subject: [PATCH 08/15] :memo: :cookie: Move "Monitoring and Observability" section --- README.md | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/README.md b/README.md index 410c21e56..624d1fd60 100644 --- a/README.md +++ b/README.md @@ -51,12 +51,12 @@ Table of Contents - [Features](#features) * [Developer Workflow Automation](#developer-workflow-automation) * [Conditionally Rendered Python Package/Project Boilerplate](#conditionally-rendered-python-packageproject-boilerplate) - * [Monitoring and Observability](#monitoring-and-observability) * [Type Checking and Data Validation](#type-checking-and-data-validation) * [Testing/Coverage](#testingcoverage) * [Security](#security) * [Linting](#linting) * [CI/CD](#cicd) + * [Monitoring and Observability](#monitoring-and-observability) * [Documentation](#documentation) - [Legal](#legal) * [License](#license) @@ -126,24 +126,6 @@ Conditionally Rendered Python Package/Project Boilerplate environment - [Optional] [Jupyter](https://jupyter.org/) support[*](#conditional-rendering) -Monitoring and Observability ----------------------------- -- [Optional] Exception monitoring - with [Sentry](https://sentry.io/welcome/) - - see: the cookiecutter's [.env]({{cookiecutter.project_slug}}/.env) file for - a detailed activation guide -- Structured logging - with [structlog-sentry-logger](https://structlog-sentry-logger.readthedocs.io/en/latest/) (via [structlog](https://www.structlog.org/en/stable/)) - - Granular control flow context logging (via call stack introspection): - - Namespaced module-specific loggers - - Function name logging - - Environment-dependent standard output stream log formatting: - - Production: JSON logs - - Development: Colorized human-readable logs, with JSON logs saved - locally for retrospective analysis - - [Optional] Exception logging to Sentry with - [structlog-sentry](https://www.structlog.org/en/stable/) - Type Checking and Data Validation --------------------------------- - Static type-checking @@ -234,6 +216,24 @@ CI/CD - Lightweight polyglot static analysis for code quality enforcement in addition to bug and security vulnerability identification with [`Semgrep`](https://semgrep.dev/) +Monitoring and Observability +---------------------------- +- [Optional] Exception monitoring + with [Sentry](https://sentry.io/welcome/) + - see: the cookiecutter's [.env]({{cookiecutter.project_slug}}/.env) file for + a detailed activation guide +- Structured logging + with [structlog-sentry-logger](https://structlog-sentry-logger.readthedocs.io/en/latest/) (via [structlog](https://www.structlog.org/en/stable/)) + - Granular control flow context logging (via call stack introspection): + - Namespaced module-specific loggers + - Function name logging + - Environment-dependent standard output stream log formatting: + - Production: JSON logs + - Development: Colorized human-readable logs, with JSON logs saved + locally for retrospective analysis + - [Optional] Exception logging to Sentry with + [structlog-sentry](https://www.structlog.org/en/stable/) + Documentation ------------- - Automated README table of contents generation From dba3ab117ae7b170b421501fc654ed7d81c3b021 Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 13:22:15 -0700 Subject: [PATCH 09/15] :memo: :cookie: Move "Type Checking and Data Validation" section --- README.md | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/README.md b/README.md index 624d1fd60..c6ab4493e 100644 --- a/README.md +++ b/README.md @@ -51,8 +51,8 @@ Table of Contents - [Features](#features) * [Developer Workflow Automation](#developer-workflow-automation) * [Conditionally Rendered Python Package/Project Boilerplate](#conditionally-rendered-python-packageproject-boilerplate) - * [Type Checking and Data Validation](#type-checking-and-data-validation) * [Testing/Coverage](#testingcoverage) + * [Type Checking and Data Validation](#type-checking-and-data-validation) * [Security](#security) * [Linting](#linting) * [CI/CD](#cicd) @@ -126,21 +126,6 @@ Conditionally Rendered Python Package/Project Boilerplate environment - [Optional] [Jupyter](https://jupyter.org/) support[*](#conditional-rendering) -Type Checking and Data Validation ---------------------------------- -- Static type-checking - with [mypy](http://mypy-lang.org/)[†](#jupyter-compatibility-via-nbqa) -- Run-time type-checking - with [typeguard](https://github.com/agronholm/typeguard) - - See the - [typeguard user guide](https://typeguard.readthedocs.io/en/latest/userguide.html?highlight=@typechecked#using-the-decorator) - for usage overview -- [Design-by-contract](https://en.wikipedia.org/wiki/Design_by_contract) support - (precondition, postcondition, and invariant enforcement) - with [icontract](https://github.com/Parquery/icontract) - - See [the test benchmarks](./tests/test_icontract_benchmark.py) - for [example performance overhead measurements](https://teozosa.github.io/cookiecutter-cruft-poetry-tox-pre-commit-ci-cd/dev/py39-benchmark/) - Testing/Coverage ---------------- - Testing @@ -169,6 +154,21 @@ Testing/Coverage - Coverage reporting with [Codecov](https://codecov.io/) +Type Checking and Data Validation +--------------------------------- +- Static type-checking + with [mypy](http://mypy-lang.org/)[†](#jupyter-compatibility-via-nbqa) +- Run-time type-checking + with [typeguard](https://github.com/agronholm/typeguard) + - See the + [typeguard user guide](https://typeguard.readthedocs.io/en/latest/userguide.html?highlight=@typechecked#using-the-decorator) + for usage overview +- [Design-by-contract](https://en.wikipedia.org/wiki/Design_by_contract) support + (precondition, postcondition, and invariant enforcement) + with [icontract](https://github.com/Parquery/icontract) + - See [the test benchmarks](./tests/test_icontract_benchmark.py) + for [example performance overhead measurements](https://teozosa.github.io/cookiecutter-cruft-poetry-tox-pre-commit-ci-cd/dev/py39-benchmark/) + Security -------- - Static application security testing (SAST) From 473a0e0615a229fc5777531d1188455c43ba8f5c Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 13:26:38 -0700 Subject: [PATCH 10/15] :memo: :cookie: Move "Security" section --- README.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index c6ab4493e..dc0ddd46a 100644 --- a/README.md +++ b/README.md @@ -53,10 +53,10 @@ Table of Contents * [Conditionally Rendered Python Package/Project Boilerplate](#conditionally-rendered-python-packageproject-boilerplate) * [Testing/Coverage](#testingcoverage) * [Type Checking and Data Validation](#type-checking-and-data-validation) - * [Security](#security) * [Linting](#linting) * [CI/CD](#cicd) * [Monitoring and Observability](#monitoring-and-observability) + * [Security](#security) * [Documentation](#documentation) - [Legal](#legal) * [License](#license) @@ -169,12 +169,6 @@ Type Checking and Data Validation - See [the test benchmarks](./tests/test_icontract_benchmark.py) for [example performance overhead measurements](https://teozosa.github.io/cookiecutter-cruft-poetry-tox-pre-commit-ci-cd/dev/py39-benchmark/) -Security --------- -- Static application security testing (SAST) - with [Bandit](https://github.com/PyCQA/bandit)[†](#jupyter-compatibility-via-nbqa) - and [Safety](https://github.com/pyupio/safety) - Linting ------- - Code quality: @@ -234,6 +228,12 @@ Monitoring and Observability - [Optional] Exception logging to Sentry with [structlog-sentry](https://www.structlog.org/en/stable/) +Security +-------- +- Static application security testing (SAST) + with [Bandit](https://github.com/PyCQA/bandit)[†](#jupyter-compatibility-via-nbqa) + and [Safety](https://github.com/pyupio/safety) + Documentation ------------- - Automated README table of contents generation From e71f3cf5c40d5b2b89d52a0f2ec59d62b8ffb46a Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 13:42:23 -0700 Subject: [PATCH 11/15] :memo: :cookie: Add superordinate categories for features Inspired by mercari/production-readiness-checklist#1 --- README.md | 68 +++++++++++++++++++++++++++++++++---------------------- 1 file changed, 41 insertions(+), 27 deletions(-) diff --git a/README.md b/README.md index dc0ddd46a..7ee376429 100644 --- a/README.md +++ b/README.md @@ -49,15 +49,18 @@ Table of Contents - [Creating a New Project](#creating-a-new-project) - [Linking an Existing Project](#linking-an-existing-project) - [Features](#features) - * [Developer Workflow Automation](#developer-workflow-automation) - * [Conditionally Rendered Python Package/Project Boilerplate](#conditionally-rendered-python-packageproject-boilerplate) - * [Testing/Coverage](#testingcoverage) - * [Type Checking and Data Validation](#type-checking-and-data-validation) - * [Linting](#linting) - * [CI/CD](#cicd) - * [Monitoring and Observability](#monitoring-and-observability) - * [Security](#security) - * [Documentation](#documentation) + * [🚀 Project Standardization and Automation](#%F0%9F%9A%80-project-standardization-and-automation) + + [Developer Workflow Automation](#developer-workflow-automation) + + [Conditionally Rendered Python Package/Project Boilerplate](#conditionally-rendered-python-packageproject-boilerplate) + * [🔧 Maintainability](#%F0%9F%94%A7-maintainability) + + [Testing/Coverage](#testingcoverage) + + [Type Checking and Data Validation](#type-checking-and-data-validation) + + [Linting](#linting) + + [CI/CD](#cicd) + * [📉 Observability](#%F0%9F%93%89-observability) + * [🔒 Security](#%F0%9F%94%92-security) + * [📋 Accessibility](#%F0%9F%93%8B-accessibility) + + [Documentation](#documentation) - [Legal](#legal) * [License](#license) @@ -99,8 +102,11 @@ cruft update Features ======== -Developer Workflow Automation ------------------------------ +🚀 Project Standardization and Automation +----------------------------------------- + +### Developer Workflow Automation + - Python packaging and dependency management with [Poetry](https://python-poetry.org/) - Project workflow orchestration @@ -117,8 +123,8 @@ Developer Workflow Automation - Continuous integration and deployment with [`GitHub Actions`](https://github.com/features/actions) -Conditionally Rendered Python Package/Project Boilerplate ---------------------------------------------------------- +### Conditionally Rendered Python Package/Project Boilerplate + - Command-line interface with [Typer](https://typer.tiangolo.com/) - Project-specific Dockerfile[*](#conditional-rendering) that @@ -126,8 +132,11 @@ Conditionally Rendered Python Package/Project Boilerplate environment - [Optional] [Jupyter](https://jupyter.org/) support[*](#conditional-rendering) -Testing/Coverage ----------------- +🔧 Maintainability +------------------ + +### Testing/Coverage + - Testing with [pytest](https://docs.pytest.org/en/latest/) - Doctests @@ -154,8 +163,8 @@ Testing/Coverage - Coverage reporting with [Codecov](https://codecov.io/) -Type Checking and Data Validation ---------------------------------- +### Type Checking and Data Validation + - Static type-checking with [mypy](http://mypy-lang.org/)[†](#jupyter-compatibility-via-nbqa) - Run-time type-checking @@ -169,8 +178,8 @@ Type Checking and Data Validation - See [the test benchmarks](./tests/test_icontract_benchmark.py) for [example performance overhead measurements](https://teozosa.github.io/cookiecutter-cruft-poetry-tox-pre-commit-ci-cd/dev/py39-benchmark/) -Linting -------- +### Linting + - Code quality: - [FlakeHell](https://github.com/life4/flakehell) - [Pylint](https://www.pylint.org/)[†](#jupyter-compatibility-via-nbqa) @@ -192,8 +201,8 @@ Linting - Invalid Python files with [check-ast](https://github.com/pre-commit/pre-commit-hooks#check-ast) -CI/CD ------ +### CI/CD + - Automated Docker image builds and pushes to [Docker Hub](https://hub.docker.com/)[‡](#repo-secret-required) - Automated uploads @@ -210,8 +219,9 @@ CI/CD - Lightweight polyglot static analysis for code quality enforcement in addition to bug and security vulnerability identification with [`Semgrep`](https://semgrep.dev/) -Monitoring and Observability ----------------------------- +📉 Observability +---------------- + - [Optional] Exception monitoring with [Sentry](https://sentry.io/welcome/) - see: the cookiecutter's [.env]({{cookiecutter.project_slug}}/.env) file for @@ -228,14 +238,18 @@ Monitoring and Observability - [Optional] Exception logging to Sentry with [structlog-sentry](https://www.structlog.org/en/stable/) -Security --------- +🔒 Security +----------- + - Static application security testing (SAST) with [Bandit](https://github.com/PyCQA/bandit)[†](#jupyter-compatibility-via-nbqa) and [Safety](https://github.com/pyupio/safety) -Documentation -------------- +📋 Accessibility +---------------- + +### Documentation + - Automated README table of contents generation with [markdown-toc](https://github.com/Lucas-C/pre-commit-hooks-nodejs) - Architecture knowledge management From d15b3d779cc286e389b615f8bddb48d4edfd368c Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 13:55:15 -0700 Subject: [PATCH 12/15] :memo: :cookie: Remove `markdown-toc` directive and fix header links with emoji See: jonschlinkert/markdown-toc#119 --- README.md | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 7ee376429..e03973f08 100644 --- a/README.md +++ b/README.md @@ -44,28 +44,24 @@ foundation on which you can build your best work! Table of Contents - - - [Creating a New Project](#creating-a-new-project) - [Linking an Existing Project](#linking-an-existing-project) - [Features](#features) - * [🚀 Project Standardization and Automation](#%F0%9F%9A%80-project-standardization-and-automation) + * [🚀 Project Standardization and Automation](#-project-standardization-and-automation) + [Developer Workflow Automation](#developer-workflow-automation) + [Conditionally Rendered Python Package/Project Boilerplate](#conditionally-rendered-python-packageproject-boilerplate) - * [🔧 Maintainability](#%F0%9F%94%A7-maintainability) + * [🔧 Maintainability](#-maintainability) + [Testing/Coverage](#testingcoverage) + [Type Checking and Data Validation](#type-checking-and-data-validation) + [Linting](#linting) + [CI/CD](#cicd) - * [📉 Observability](#%F0%9F%93%89-observability) - * [🔒 Security](#%F0%9F%94%92-security) - * [📋 Accessibility](#%F0%9F%93%8B-accessibility) + * [📉 Observability](#-observability) + * [🔒 Security](#-security) + * [📋 Accessibility](#-accessibility) + [Documentation](#documentation) - [Legal](#legal) * [License](#license) - - Creating a New Project =========================== Via [`cruft`](https://cruft.github.io/cruft/) (recommended): From c41651fcf1418cbbbd15cad4d8103c34a1f85821 Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 14:00:15 -0700 Subject: [PATCH 13/15] :memo: :cookie: Make separate "Logging" and "Error Tracking" sections --- README.md | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index e03973f08..90a1203b9 100644 --- a/README.md +++ b/README.md @@ -56,6 +56,8 @@ Table of Contents + [Linting](#linting) + [CI/CD](#cicd) * [📉 Observability](#-observability) + + [Logging](#logging) + + [Error Tracking](#error-tracking) * [🔒 Security](#-security) * [📋 Accessibility](#-accessibility) + [Documentation](#documentation) @@ -218,10 +220,8 @@ Features 📉 Observability ---------------- -- [Optional] Exception monitoring - with [Sentry](https://sentry.io/welcome/) - - see: the cookiecutter's [.env]({{cookiecutter.project_slug}}/.env) file for - a detailed activation guide +### Logging + - Structured logging with [structlog-sentry-logger](https://structlog-sentry-logger.readthedocs.io/en/latest/) (via [structlog](https://www.structlog.org/en/stable/)) - Granular control flow context logging (via call stack introspection): @@ -234,6 +234,13 @@ Features - [Optional] Exception logging to Sentry with [structlog-sentry](https://www.structlog.org/en/stable/) +### Error Tracking + +- [Optional] Exception monitoring + with [Sentry](https://sentry.io/welcome/) + - see: the cookiecutter's [.env]({{cookiecutter.project_slug}}/.env) file for + a detailed activation guide + 🔒 Security ----------- From 00f2bbff8c229991b951ca616d77d5117ce1af60 Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 14:03:52 -0700 Subject: [PATCH 14/15] :memo: :cookie: Make separate "Static Application Security Testing (SAST)" section Adding specific descriptions of each tool. --- README.md | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 90a1203b9..ecdca4c95 100644 --- a/README.md +++ b/README.md @@ -59,6 +59,7 @@ Table of Contents + [Logging](#logging) + [Error Tracking](#error-tracking) * [🔒 Security](#-security) + + [Static Application Security Testing (SAST)](#static-application-security-testing-sast) * [📋 Accessibility](#-accessibility) + [Documentation](#documentation) - [Legal](#legal) @@ -244,9 +245,12 @@ Features 🔒 Security ----------- -- Static application security testing (SAST) +### Static Application Security Testing (SAST) + +- Code vulnerabilities with [Bandit](https://github.com/PyCQA/bandit)[†](#jupyter-compatibility-via-nbqa) - and [Safety](https://github.com/pyupio/safety) +- Python package dependencies vulnerabilities + with [Safety](https://github.com/pyupio/safety) 📋 Accessibility ---------------- From 7c4011b1edf1092683e0e8b29f61f5bb8472e3c0 Mon Sep 17 00:00:00 2001 From: Teo Zosa Date: Mon, 7 Jun 2021 14:06:05 -0700 Subject: [PATCH 15/15] :memo: :cookie: Move "Type Checking and Data Validation" section to top --- README.md | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/README.md b/README.md index ecdca4c95..5fd110807 100644 --- a/README.md +++ b/README.md @@ -51,8 +51,8 @@ Table of Contents + [Developer Workflow Automation](#developer-workflow-automation) + [Conditionally Rendered Python Package/Project Boilerplate](#conditionally-rendered-python-packageproject-boilerplate) * [🔧 Maintainability](#-maintainability) - + [Testing/Coverage](#testingcoverage) + [Type Checking and Data Validation](#type-checking-and-data-validation) + + [Testing/Coverage](#testingcoverage) + [Linting](#linting) + [CI/CD](#cicd) * [📉 Observability](#-observability) @@ -134,6 +134,21 @@ Features 🔧 Maintainability ------------------ +### Type Checking and Data Validation + +- Static type-checking + with [mypy](http://mypy-lang.org/)[†](#jupyter-compatibility-via-nbqa) +- Run-time type-checking + with [typeguard](https://github.com/agronholm/typeguard) + - See the + [typeguard user guide](https://typeguard.readthedocs.io/en/latest/userguide.html?highlight=@typechecked#using-the-decorator) + for usage overview +- [Design-by-contract](https://en.wikipedia.org/wiki/Design_by_contract) support + (precondition, postcondition, and invariant enforcement) + with [icontract](https://github.com/Parquery/icontract) + - See [the test benchmarks](./tests/test_icontract_benchmark.py) + for [example performance overhead measurements](https://teozosa.github.io/cookiecutter-cruft-poetry-tox-pre-commit-ci-cd/dev/py39-benchmark/) + ### Testing/Coverage - Testing @@ -162,21 +177,6 @@ Features - Coverage reporting with [Codecov](https://codecov.io/) -### Type Checking and Data Validation - -- Static type-checking - with [mypy](http://mypy-lang.org/)[†](#jupyter-compatibility-via-nbqa) -- Run-time type-checking - with [typeguard](https://github.com/agronholm/typeguard) - - See the - [typeguard user guide](https://typeguard.readthedocs.io/en/latest/userguide.html?highlight=@typechecked#using-the-decorator) - for usage overview -- [Design-by-contract](https://en.wikipedia.org/wiki/Design_by_contract) support - (precondition, postcondition, and invariant enforcement) - with [icontract](https://github.com/Parquery/icontract) - - See [the test benchmarks](./tests/test_icontract_benchmark.py) - for [example performance overhead measurements](https://teozosa.github.io/cookiecutter-cruft-poetry-tox-pre-commit-ci-cd/dev/py39-benchmark/) - ### Linting - Code quality: