generated from infinitelambda/template
-
Notifications
You must be signed in to change notification settings - Fork 1
/
pyproject.toml
130 lines (117 loc) · 3.97 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
[tool.poetry]
name = "dbt-data-diff"
version = "0.0.0"
description = "Data-diff solution for dbt-ers with Snowflake ❄️ 🚀"
authors = ["Infinite Lambda <[email protected]>"]
readme = "README.md"
license = "Apache-2.0"
repository = "https://github.com/infinitelambda/dbt-data-diff"
homepage = "https://infinitelambda.com"
documentation = "https://data-diff.iflambda.com/latest/"
keywords = ["packaging", "dbt", "data-quality", "data-diff", "markdown", "lint"]
classifiers = [
"Topic :: dbt Package Development :: Documentation",
"Topic :: dbt Package Development :: Testing",
"Topic :: dbt Package :: Blue-Green",
]
[tool.poetry.dependencies]
python = ">=3.9,<3.13"
dbt-snowflake = "^1.7.0"
[tool.poetry.dev-dependencies]
pre-commit = "^2.17.0"
poethepoet = "^0.16.4"
sqlfluff = "^2.3.5"
sqlfluff-templater-dbt = "^2.3.5"
mkdocs = "^1.5.3"
mkdocs-material = "^9.4.8"
mkdocs-minify-plugin = "^0.7.1"
mike = "^2.0.0"
[build-system]
requires = ["poetry-core>=1.0.0"]
build-backend = "poetry.core.masonry.api"
[tool.sqlfluff.core]
templater = "dbt"
dialect = "snowflake"
sql_file_exts = ".sql,.sql.j2,.dml,.ddl"
max_line_length = 120
[tool.sqlfluff.templater.dbt]
profile = "data_diff"
[tool.sqlfluff.rules]
allow_scalar = true
single_table_references = "consistent"
unquoted_identifiers_policy = "all"
[tool.sqlfluff.layout.type.comma]
line_position = "leading"
[tool.sqlfluff.indentation]
tab_space_size = 2
indent_unit = "space"
[toolsqlfluff.rules.capitalisation.keywords]
capitalisation_policy = "lower"
[toolsqlfluff.rules.capitalisation.functions]
capitalisation_policy = "lower"
[tool.sqlfluff.templater]
unwrap_wrapped_queries = true
[tool.sqlfluff.templater.jinja]
apply_dbt_builtins = true
[tool.poe.tasks]
git-hooks = { shell = "pre-commit install --install-hooks && pre-commit install --hook-type commit-msg" }
format = [
{cmd = "dbt clean"},
{cmd = "dbt deps"},
{cmd = "sqlfluff format . --dialect snowflake"},
]
lint = [
{cmd = "dbt clean"},
{cmd = "dbt deps"},
{cmd = "sqlfluff lint . --dialect snowflake"},
]
data-diff-verify = [
{cmd = "dbt deps --project-dir integration_tests"},
{cmd = "dbt debug --project-dir integration_tests"},
]
data-diff-migration = [
{cmd = "dbt run -s data_diff --full-refresh --vars '{fresh: true, data_diff__on_migration: true, data_diff__on_migration_data: true, data_diff__full_refresh: true}' --project-dir integration_tests"},
]
data-diff-migration-4async = [
{cmd = "dbt run -s data_diff --full-refresh --vars '{data_diff__on_migration: true, data_diff__on_migration_data: true, data_diff__full_refresh: true, data_diff__auto_pipe: true}' --project-dir integration_tests"},
]
data-diff-bg = [
{cmd = "dbt build -s example --project-dir integration_tests -t blue"},
{cmd = "dbt build -s example --project-dir integration_tests -t green"},
]
data-diff-run = [
{cmd = "dbt run-operation data_diff__run --project-dir integration_tests"},
]
data-diff-run-async = [
{cmd = "dbt run-operation data_diff__run_async --project-dir integration_tests"},
]
data-diff-run-async-wait = [
{cmd = "dbt run-operation data_diff__run_async --project-dir integration_tests --args '{is_polling_status: true}'"},
]
data-diff-test = [
{cmd = "dbt build --exclude example --project-dir integration_tests"},
]
data-diff = [
{cmd = "poe data-diff-migration"},
{cmd = "poe data-diff-bg"},
{cmd = "poe data-diff-run"}
]
data-diff-async-wait = [
{cmd = "poe data-diff-migration-4async"},
{cmd = "poe data-diff-bg"},
{cmd = "poe data-diff-run-async-wait"}
]
build-doc = [
{cmd = "dbt deps --project-dir integration_tests"},
{cmd = "dbt docs generate --select package:data_diff --project-dir integration_tests"},
{cmd = "mkdocs build"}
]
build-doc-and-serve = [
{cmd = "poe build-doc"},
{cmd = "mkdocs serve"}
]
git-push-github = [
{cmd = "git remote set-url origin https://github.com/infinitelambda/dbt-data-diff.git"},
{cmd = "git push"},
{cmd = "git remote set-url origin [email protected]:infinitelambda/bi-chapter/dbt-data-diff.git"}
]