From 9afc69371f7e36e652ac4b59df06d8d0b3602011 Mon Sep 17 00:00:00 2001 From: AJ Stuyvenberg Date: Tue, 16 Dec 2025 15:53:19 -0500 Subject: [PATCH 1/3] fix: add black so our AI dev platform formats correctly --- pyproject.toml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index 6ca4f147..99ffc653 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -36,6 +36,7 @@ requests = { version ="^2.22.0", optional = true } pytest = { version= "^8.0.0", optional = true } pytest-benchmark = { version = "^4.0", optional = true } flake8 = { version = "^5.0.4", optional = true } +black = { version = "==25.11.0", optional = true } [tool.poetry.extras] dev = [ @@ -44,8 +45,12 @@ dev = [ "pytest", "pytest-benchmark", "requests", + "black", ] +[tool.black] +include = "(^datadog_lambda/.*\\.pyi?$|^tests/.*\\.pyi?$)" + [build-system] requires = ["poetry-core>=1.0.0"] build-backend = "poetry.core.masonry.api" From f15e2244a71c6c6ecffea2301d1a8cd413318dbd Mon Sep 17 00:00:00 2001 From: AJ Stuyvenberg Date: Tue, 16 Dec 2025 16:00:07 -0500 Subject: [PATCH 2/3] remove pip install black --- scripts/check_format.sh | 3 --- 1 file changed, 3 deletions(-) diff --git a/scripts/check_format.sh b/scripts/check_format.sh index 783a17d6..f630a425 100755 --- a/scripts/check_format.sh +++ b/scripts/check_format.sh @@ -1,9 +1,6 @@ #!/bin/sh set -e -PYTHON_VERSION=$(python -c 'import sys; print(sys.version_info.major)') -pip install -Iv black==25.11.0 - python -m black --check datadog_lambda/ --diff python -m black --check tests --diff From ea5aad2b2e5688ec990d29800dc29c236a8cb895 Mon Sep 17 00:00:00 2001 From: AJ Stuyvenberg Date: Tue, 16 Dec 2025 16:03:54 -0500 Subject: [PATCH 3/3] Python 3.8 support is gone from black 25+ so just use 24 and deprecate 3.8 soon --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 99ffc653..3070484d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -36,7 +36,7 @@ requests = { version ="^2.22.0", optional = true } pytest = { version= "^8.0.0", optional = true } pytest-benchmark = { version = "^4.0", optional = true } flake8 = { version = "^5.0.4", optional = true } -black = { version = "==25.11.0", optional = true } +black = { version = ">=24.8.0", optional = true } [tool.poetry.extras] dev = [