diff --git a/.github/workflows/build_layer.yml b/.github/workflows/build_layer.yml index db8329b5..1725975f 100644 --- a/.github/workflows/build_layer.yml +++ b/.github/workflows/build_layer.yml @@ -37,7 +37,7 @@ jobs: - name: Patch pyproject.toml run: | echo "Patching pyproject.toml to use latest build of dd-trace-py" - sed -zEi 's|^ddtrace =.*$|ddtrace = { file = "${{ steps.find-ddtrace-wheel.outputs.wheel_path }}" }|' pyproject.toml + sed -i 's|^ddtrace =.*$|ddtrace = { file = "${{ steps.find-ddtrace-wheel.outputs.wheel_path }}" }|' pyproject.toml - name: Build layer for Python ${{ matrix.python_version }} on ${{ matrix.arch }} run: | diff --git a/pyproject.toml b/pyproject.toml index f5a49ead..d8aa4201 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -3,8 +3,12 @@ name = "datadog_lambda" version = "8.123.0.dev0" description = "The Datadog AWS Lambda Library" authors = ["Datadog, Inc. "] + +[project] +name = "datadog_lambda" license = "Apache-2.0" readme = "README.md" +requires-python = ">=3.8.0,<4" repository = "https://github.com/DataDog/datadog-lambda-python" keywords = [ "datadog", @@ -12,10 +16,18 @@ keywords = [ "lambda", "layer", ] +dependencies = [ + "datadog>=0.51.0,<1.0.0", + "wrapt>=1.11.2,<2", + "ddtrace>=3.19.1,<4; python_version>='3.9.0' and python_version < '3.10'", + "ddtrace>=4.1.1,<5; python_version>='3.10.0'", + "ujson>=5.9.0", +] packages = [ { include = "datadog_lambda" } ] classifiers = [ + "Programming Language :: Python :: 3 :: Only", "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", @@ -25,14 +37,13 @@ classifiers = [ "Programming Language :: Python :: 3.14", ] +# can remove tool.poetry.depencies and tool.poetry.extras +# after deprecation of Python 3.8 [tool.poetry.dependencies] python = ">=3.8.0,<4" datadog = ">=0.51.0,<1.0.0" wrapt = "^1.11.2" -ddtrace = [ - {version = ">=3.19.1,<4", python = ">=3.8,<3.10"}, - {version = ">=4.1.1,<5", python = ">=3.10"} -] +ddtrace = ">=3.19.1,<4" ujson = ">=5.9.0" botocore = { version = "^1.34.0", optional = true } requests = { version ="^2.22.0", optional = true } @@ -49,9 +60,18 @@ dev = [ "requests", ] +[project.optional-dependencies] +dev = [ + "botocore>=1.34.0,<2", + "requests>=2.22.0,<3", + "pytest>=8.0.0,<9", + "pytest-benchmark>=4.0,<5", + "flake8>=5.0.4,<6", +] + [build-system] requires = ["poetry-core>=1.0.0"] build-backend = "poetry.core.masonry.api" [tool.pytest.ini_options] -addopts = "--benchmark-disable --benchmark-autosave" \ No newline at end of file +addopts = "--benchmark-disable --benchmark-autosave"