Skip to content

Commit

Permalink
chore: Use Poetry support for PEP 621
Browse files Browse the repository at this point in the history
  • Loading branch information
edgarrmondragon committed May 3, 2024
1 parent 887ca9d commit 8b562be
Show file tree
Hide file tree
Showing 4 changed files with 92 additions and 107 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/constraints.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
pip==24.0
poetry==1.8.2
poetry @ git+https://github.com/radoering/poetry.git@pep621-support
poetry-plugin-export==1.7.1
poetry-dynamic-versioning==1.3.0
pre-commit==3.7.0
Expand Down
8 changes: 4 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ repos:
samples/.*
)$
- 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
8 changes: 4 additions & 4 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

181 changes: 83 additions & 98 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,13 +1,19 @@
[tool.poetry]
[project]
name = "singer-sdk"
version = "0.0.0"
dynamic = [
"version",
]
description = "A framework for building Singer taps"
authors = ["Meltano Team and Contributors <[email protected]>"]
maintainers = ["Meltano Team and Contributors <[email protected]>"]
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 = "[email protected]" }]
maintainers = [{ name = "Meltano Team and Contributors", email = "[email protected]" }]
urls.Homepage = "https://sdk.meltano.com/en/latest/"
urls.Repository = "https://github.com/meltano/sdk"
urls.Documentation = "https://sdk.meltano.com/en/latest/"
urls."Issue Tracker" = "https://github.com/meltano/sdk/issues"
urls."Twitter" = "https://twitter.com/meltanodata/"
urls."Changelog" = "https://github.com/meltano/sdk/blob/main/CHANGELOG.md"
urls."Slack" = "https://meltano.com/slack"
urls."Youtube" = "https://www.youtube.com/meltano"
keywords = [
"Meltano",
"Singer",
Expand All @@ -28,93 +34,76 @@ classifiers = [
"Topic :: Software Development :: Libraries :: Application Frameworks",
"Typing :: Typed",
]
license = "Apache-2.0"

[tool.poetry.urls]
"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.dependencies]
python = ">=3.8"
backoff = { version = ">=2.0.0", python = "<4" }
backports-datetime-fromisoformat = { version = ">=2.0.1", python = "<3.11" }
click = "~=8.0"
cryptography = ">=3.4.6"
fs = ">=2.4.16"
importlib-metadata = {version = "<8.0.0", python = "<3.12"}
importlib-resources = {version = ">=5.12.0,!=6.2.0,!=6.3.0,!=6.3.1", python = "<3.9"}
inflection = ">=0.5.1"
joblib = ">=1.3.0"
jsonpath-ng = ">=1.5.3"
jsonschema = ">=4.16.0"
packaging = ">=23.1"
pendulum = ">=2.1.0,<4"
PyJWT = "~=2.4"
python-dateutil = ">=2.8.2"
python-dotenv = ">=0.20"
PyYAML = ">=6.0"
referencing = ">=0.30.0"
requests = ">=2.25.1"
simpleeval = ">=0.9.13"
simplejson = ">=3.17.6"
sqlalchemy = ">=1.4,<3.0"
typing-extensions = ">=4.5.0"
# urllib3 2.0 is not compatible with botocore
urllib3 = ">=1.26,<2"

# Sphinx dependencies installed as optional 'docs' extras
# https://github.com/readthedocs/readthedocs.org/issues/4912#issuecomment-664002569
sphinx = {version = ">=4.5", optional = true}
furo = {version = ">=2022.12.7", optional = true}
sphinx-copybutton = {version = ">=0.3.1", optional = true}
myst-parser = {version = ">=1", optional = true}
sphinx-autobuild = {version = ">=2021.3.14", optional = true}
sphinx-inline-tabs = {version = ">=2023.4.21", optional = true}
sphinx-notfound-page = {version = ">=1.0.0", optional = true}
sphinx-reredirects = {version = ">=0.1.1", optional = true}

# File storage dependencies installed as optional 'filesystem' extras
fs-s3fs = {version = ">=1.1.1", optional = true}

# Parquet file dependencies installed as optional 'parquet' extras
numpy = [
{ version = ">=1.22,<1.25", python = ">=3.8,<3.9", optional = true },
{ version = ">=1.22", python = ">=3.9", optional = true },
readme = "README.md"
license.file = "LICENSE"
requires-python = ">=3.8"
dependencies = [
"backoff>=2.0.0,<4; python_version<'4'",
"backports-datetime-fromisoformat>=2.0.1,<3.11; python_version<'3.11'",
"click~=8.0",
"cryptography>=3.4.6",
"fs>=2.4.16",
"importlib-metadata<8.0.0; python_version<'3.12'",
"importlib-resources>=5.12.0,!=6.2.0,!=6.3.0,!=6.3.1; python_version<'3.9'",
"inflection>=0.5.1",
"joblib>=1.3.0",
"jsonpath-ng>=1.5.3",
"jsonschema>=4.16.0",
"packaging>=23.1",
"pendulum>=2.1.0,<4",
"PyJWT~=2.4",
"python-dateutil>=2.8.2",
"python-dotenv>=0.20",
"PyYAML>=6.0",
"referencing>=0.30.0",
"requests>=2.25.1",
"simpleeval>=0.9.13",
"simplejson>=3.17.6",
"sqlalchemy>=1.4,<3.0",
"typing-extensions>=4.5.0",
# urllib3 2.0 is not compatible with botocore
"urllib3>=1.26,<2",
]
optional-dependencies.docs = [
"furo>=2022.12.7",
"myst-parser>=1",
"pytest>=7.2.1",
"sphinx>=4.5",
"sphinx-autobuild>=2021.3.14",
"sphinx-copybutton>=0.3.1",
"sphinx-inline-tabs>=2023.4.21",
"sphinx-notfound-page>=1.0.0",
"sphinx-reredirects>=0.1.1",
]
optional-dependencies.s3 = [
"fs-s3fs>=1.1.1",
]
pyarrow = { version = ">=13", optional = true }

# Testing dependencies installed as optional 'testing' extras
pytest = {version=">=7.2.1", optional = true}
pytest-durations = {version = ">=1.2.0", optional = true}

# installed as optional 'faker' extra
faker = {version = ">=22.5,<26.0", optional = true}

[tool.poetry.extras]
# TODO: Add 'cryptography' and 'PyJWT' to the 'jwt' when we want to remove them
# from the main dependencies
jwt = []
docs = [
"furo",
"myst-parser",
"pytest",
"sphinx",
"sphinx-copybutton",
"sphinx-autobuild",
"sphinx-inline-tabs",
"sphinx-notfound-page",
"sphinx-reredirects",
optional-dependencies.jwt = []
optional-dependencies.parquet = [
"numpy>=1.22,<1.25; python_version<'3.9'",
"numpy>=1.22; python_version>='3.9'",
"pyarrow>=13",
]
optional-dependencies.testing = [
"pytest>=7.2.1",
"pytest-durations>=1.2.0",
]
s3 = ["fs-s3fs"]
testing = [
"pytest",
"pytest-durations"
optional-dependencies.faker = [
"faker>=22.5,<26.0",
]
parquet = ["numpy", "pyarrow"]
faker = ["faker"]

[project.entry-points."pytest11"]
singer_testing = "singer_sdk.testing.pytest_plugin"

[project.entry-points."singer_sdk.batch_encoders"]
jsonl = "singer_sdk.contrib.batch_encoder_jsonl:JSONLinesBatcher"
parquet = "singer_sdk.contrib.batch_encoder_parquet:ParquetBatcher"

[tool.poetry]
name = "singer-sdk"
version = "0.0.0"

[tool.poetry.group.dev.dependencies]
coverage = {extras = ["toml"], version = ">=7.4"}
Expand Down Expand Up @@ -242,16 +231,12 @@ enable = true
style = "pep440"

[build-system]
requires = ["poetry-core==1.9.0", "poetry-dynamic-versioning==1.2.0"]
requires = [
"poetry-core@ git+https://github.com/radoering/poetry-core.git@pep621-support",
"poetry-dynamic-versioning==1.2.0",
]
build-backend = "poetry_dynamic_versioning.backend"

[tool.poetry.plugins."pytest11"]
singer_testing = "singer_sdk.testing.pytest_plugin"

[tool.poetry.plugins."singer_sdk.batch_encoders"]
jsonl = "singer_sdk.contrib.batch_encoder_jsonl:JSONLinesBatcher"
parquet = "singer_sdk.contrib.batch_encoder_parquet:ParquetBatcher"

[tool.ruff]
extend-exclude = [
"cookiecutter/*",
Expand Down

0 comments on commit 8b562be

Please sign in to comment.