From 12dca2eed5b01bbeffca4f3939647a1e2002c4ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Edgar=20Ram=C3=ADrez-Mondrag=C3=B3n?= Date: Thu, 2 May 2024 22:40:38 -0600 Subject: [PATCH] chore: Use Poetry support for PEP 621 --- .github/workflows/constraints.txt | 2 +- .pre-commit-config.yaml | 8 +++---- poetry.lock | 4 ++-- pyproject.toml | 40 ++++++++++++++++++++----------- 4 files changed, 33 insertions(+), 21 deletions(-) diff --git a/.github/workflows/constraints.txt b/.github/workflows/constraints.txt index 4dfd4edc8e..e17dbe02d8 100644 --- a/.github/workflows/constraints.txt +++ b/.github/workflows/constraints.txt @@ -1,6 +1,6 @@ griffe==1.3.1 pip==24.2 -poetry==1.8.3 +poetry @ git+https://github.com/python-poetry/poetry.git@main poetry-plugin-export==1.8.0 poetry-dynamic-versioning==1.4.1 pre-commit==3.8.0 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 22a0b74c7b..fab7a044dc 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -64,7 +64,7 @@ repos: cookiecutter/.* )$ -- repo: https://github.com/python-poetry/poetry - rev: 1.8.0 - hooks: - - id: poetry-check +# - repo: https://github.com/python-poetry/poetry +# rev: 1.8.0 +# hooks: +# - id: poetry-check diff --git a/poetry.lock b/poetry.lock index 1d4a0981d2..6ff822a3ec 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 1.8.3 and should not be changed by hand. +# This file is automatically @generated by Poetry 2.0.0.dev0 and should not be changed by hand. [[package]] name = "alabaster" @@ -2627,4 +2627,4 @@ testing = ["pytest"] [metadata] lock-version = "2.0" python-versions = ">=3.8" -content-hash = "5ce14d58274c3f56d84c8787fefb42b26868bd191298df945fe99dc45e545fce" +content-hash = "53731e9195e19e21a45e6efc0ff66ece91eb0446538dc931995f94ead724dda6" diff --git a/pyproject.toml b/pyproject.toml index 2a5c80b88e..7885633043 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,13 +1,12 @@ -[tool.poetry] +[project] name = "singer-sdk" -version = "0.0.0" +dynamic = [ + "dependencies", + "version", +] description = "A framework for building Singer taps" -authors = ["Meltano Team and Contributors "] -maintainers = ["Meltano Team and Contributors "] -readme = "README.md" -homepage = "https://sdk.meltano.com/en/latest/" -repository = "https://github.com/meltano/sdk" -documentation = "https://sdk.meltano.com/en/latest/" +authors = [{ name = "Meltano Team and Contributors", email = "hello@meltano.com" }] +maintainers = [{ name = "Meltano Team and Contributors", email = "hello@meltano.com" }] keywords = [ "Meltano", "Singer", @@ -28,15 +27,26 @@ classifiers = [ "Topic :: Software Development :: Libraries :: Application Frameworks", "Typing :: Typed", ] -license = "Apache-2.0" +readme = "README.md" +license.file = "LICENSE" +requires-python = ">=3.8" -[tool.poetry.urls] +[project.urls] +Homepage = "https://sdk.meltano.com/en/latest/" +Repository = "https://github.com/meltano/sdk" +Documentation = "https://sdk.meltano.com/en/latest/" "Issue Tracker" = "https://github.com/meltano/sdk/issues" "Twitter" = "https://twitter.com/meltanodata/" "Changelog" = "https://github.com/meltano/sdk/blob/main/CHANGELOG.md" "Slack" = "https://meltano.com/slack" "Youtube" = "https://www.youtube.com/meltano" +[tool.poetry] +# TODO: remove this duplicate name when nox-poetry supports PEP 621 +# https://github.com/cjolowicz/nox-poetry/pull/1223 +name = "singer-sdk" +version = "0.0.0" + [tool.poetry.dependencies] python = ">=3.8" backoff = { version = ">=2.0.0", python = "<4" } @@ -297,13 +307,16 @@ enable = true style = "pep440" [build-system] -requires = ["poetry-core==1.9.0", "poetry-dynamic-versioning==1.4.0"] +requires = [ + "poetry-core@ git+https://github.com/python-poetry/poetry-core.git@main", + "poetry-dynamic-versioning", +] build-backend = "poetry_dynamic_versioning.backend" -[tool.poetry.plugins."pytest11"] +[project.entry-points."pytest11"] singer_testing = "singer_sdk.testing.pytest_plugin" -[tool.poetry.plugins."singer_sdk.batch_encoders"] +[project.entry-points."singer_sdk.batch_encoders"] jsonl = "singer_sdk.contrib.batch_encoder_jsonl:JSONLinesBatcher" parquet = "singer_sdk.contrib.batch_encoder_parquet:ParquetBatcher" @@ -313,7 +326,6 @@ extend-exclude = [ "*simpleeval*", ] line-length = 88 -target-version = "py38" [tool.ruff.format] docstring-code-format = true