Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,16 @@ ui-style:
SKIP=ruff,ruff-format,mypy pre-commit run --all-files

doc-test:
PYTEST_PLUGINS=tests.common_fixtures pytest --doctest-modules sqlmesh/core sqlmesh/utils
PYTEST_PLUGINS=tests.common_fixtures python -m pytest --doctest-modules sqlmesh/core sqlmesh/utils

package:
pip3 install wheel && python3 setup.py sdist bdist_wheel
pip3 install build && python3 -m build

publish: package
pip3 install twine && python3 -m twine upload dist/*

package-tests:
pip3 install wheel && python3 tests/setup.py sdist bdist_wheel
pip3 install build && cp pyproject.toml tests/sqlmesh_pyproject.toml && python3 -m build tests/

publish-tests: package-tests
pip3 install twine && python3 -m twine upload -r tobiko-private tests/dist/*
Expand Down
2 changes: 1 addition & 1 deletion examples/airflow/Dockerfile.template
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ RUN pip install apache-airflow-providers-databricks==6.4.0 \

# Install Deps
USER root
ADD setup.py /opt/sqlmesh/setup.py
ADD pyproject.toml /opt/sqlmesh/pyproject.toml
RUN mkdir /opt/sqlmesh/sqlmesh && touch /opt/sqlmesh/sqlmesh/__init__.py && chown -R airflow /opt/sqlmesh

ADD examples/custom_materializations /opt/custom_materializations
Expand Down
155 changes: 155 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,155 @@
[project]
name = "sqlmesh"
dynamic = ["version"]
description = "Next-generation data transformation framework"
readme = "README.md"
authors = [{ name = "TobikoData Inc.", email = "engineering@tobikodata.com" }]
license = { file = "LICENSE" }
requires-python = ">= 3.9"
dependencies = [
"astor",
"click",
"croniter",
"duckdb!=0.10.3",
"dateparser",
"hyperscript>=0.1.0",
"importlib-metadata; python_version<'3.12'",
"ipywidgets",
"jinja2",
"pandas",
"pydantic>=2.0.0",
"requests",
"rich[jupyter]",
"ruamel.yaml",
"sqlglot[rs]~=26.8.0",
"tenacity",
"time-machine",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this be a dev dependency?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

]
classifiers=[
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: Apache Software License",
"Operating System :: OS Independent",
"Programming Language :: SQL",
"Programming Language :: Python :: 3 :: Only",
]

[project.optional-dependencies]
athena = ["PyAthena[Pandas]"]
azuresql = ["pymssql"]
bigquery = [
"google-cloud-bigquery[pandas]",
"google-cloud-bigquery-storage"
]
bigframes = ["bigframes>=1.32.0"]
clickhouse = ["clickhouse-connect"]
databricks = ["databricks-sql-connector"]
dev = [
"agate==1.7.1",
"apache-airflow==2.9.1",
"opentelemetry-proto==1.27.0", # pip was having trouble resolving this transitive dependency of airflow
"beautifulsoup4",
"clickhouse-connect",
"cryptography",
"databricks-sql-connector",
"dbt-bigquery",
"dbt-core",
"dbt-duckdb>=1.7.1",
"dbt-snowflake",
"dbt-athena-community",
"dbt-clickhouse",
"dbt-databricks",
"dbt-redshift",
"dbt-sqlserver>=1.7.0",
"dbt-trino",
"Faker",
"google-auth",
"google-cloud-bigquery",
"google-cloud-bigquery-storage",
"mypy~=1.13.0",
"pandas-stubs",
"pre-commit",
"psycopg2-binary",
"pydantic",
"PyAthena[Pandas]",
"PyGithub~=2.5.0",
"pyspark~=3.5.0",
"pytest",
"pytest-asyncio",
"pytest-mock",
"pytest-retry",
"pytest-xdist",
"pytz",
"redshift_connector",
"ruff~=0.7.0",
"snowflake-connector-python[pandas,secure-local-storage]>=3.0.2",
"sqlalchemy-stubs",
"trino",
"types-croniter",
"types-dateparser",
"types-PyMySQL",
"types-python-dateutil",
"types-pytz",
"types-requests==2.28.8",
"typing-extensions",
]
dbt = ["dbt-core<2"]
dlt = ["dlt"]
gcppostgres = ["cloud-sql-python-connector[pg8000]>=1.8.0"]
github = ["PyGithub~=2.5.0"]
llm = ["langchain", "openai"]
mssql = ["pymssql"]
mysql = ["pymysql"]
mwaa = ["boto3"]
postgres = ["psycopg2"]
redshift = ["redshift_connector"]
slack = ["slack_sdk"]
snowflake = [
"cryptography",
"snowflake-connector-python[pandas,secure-local-storage]",
# as at 2024-08-05, snowflake-snowpark-python is only available up to Python 3.11
"snowflake-snowpark-python; python_version<'3.12'",
]
trino = ["trino"]
web = [
"fastapi==0.115.5",
"watchfiles>=0.19.0",
"uvicorn[standard]==0.22.0",
"sse-starlette>=0.2.2",
"pyarrow",
]
risingwave = ["psycopg2"]

[project.scripts]
sqlmesh = "sqlmesh.cli.main:cli"
sqlmesh_cicd = "sqlmesh.cicd.bot:bot"

[project.entry-points."airflow.plugins"]
sqlmesh_airflow = "sqlmesh.schedulers.airflow.plugin:SqlmeshAirflowPlugin"

[project.urls]
Homepage = "https://sqlmesh.com/"
Documentation = "https://sqlmesh.readthedocs.io/en/stable/"
Repository = "https://github.com/TobikoData/sqlmesh"
Issues = "https://github.com/TobikoData/sqlmesh/issues"

[build-system]
requires = ["setuptools >= 61.0", "setuptools_scm"]
build-backend = "setuptools.build_meta"

[tool.setuptools]
include-package-data = false

[tool.setuptools_scm]
version_file = "sqlmesh/_version.py"
fallback_version = "0.0.0"
local_scheme = "no-local-version"

[tool.setuptools.packages.find]
include=["sqlmesh", "sqlmesh.*", "web*"]

[tool.setuptools.package-data]
web = ["client/dist/**"]
"*" = ["py.typed"]


3 changes: 0 additions & 3 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
[metadata]
version = attr: sqlmesh.__version__

[mypy]
plugins = pydantic.mypy
no_implicit_optional = True
Expand Down
175 changes: 0 additions & 175 deletions setup.py

This file was deleted.

1 change: 1 addition & 0 deletions tests/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
sqlmesh_pyproject.toml
Loading