You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
build-package = {cmd = "poetry build", help = "Build the python package: source and wheels archives."}
140
140
build = {sequence = ["assemble", "build-package"], help = "Run all tasks to build the package."}
141
141
142
142
# Format check tasks
143
+
format-check = {sequence = ["_format-check-ruff", "_format-check-prettier"], help = "Check formatting for all file types via Ruff and Prettier.", ignore_fail = "return_non_zero"}
143
144
_format-check-ruff = {cmd = "poetry run ruff format --check .", help = "Check formatting with Ruff."}
144
145
_format-check-prettier = {cmd = "npx prettier . --check", help = "Check formatting with prettier."}
145
-
format-check = {sequence = ["_format-check-ruff", "_format-check-prettier"], help = "Check formatting for all file types.", ignore_fail = "return_non_zero"}
146
146
147
147
# Format fix tasks
148
+
format-fix = {sequence = ["_format-fix-ruff", "_format-fix-prettier"], help = "Format all file types via Ruff and Prettier.", ignore_fail = "return_non_zero"}
148
149
_format-fix-ruff = {cmd = "poetry run ruff format .", help = "Format with Ruff."}
149
150
_format-fix-prettier = {cmd = "npx prettier . --write", help = "Format with prettier."}
150
-
format-fix = {sequence = ["_format-fix-ruff", "_format-fix-prettier"], help = "Format all file types.", ignore_fail = "return_non_zero"}
151
151
152
152
# Linting/Typing check tasks
153
-
_lint-ruff = {cmd = "poetry run ruff check .", help = "Lint with Ruff."}
153
+
lint = {cmd = "poetry run ruff check .", help = "Lint with Ruff."}
154
154
type-check = {cmd = "poetry run mypy airbyte_cdk", help = "Type check modified files with mypy."}
155
-
lint = {sequence = ["_lint-ruff", "type-check"], help = "Lint all code. Includes type checking.", ignore_fail = "return_non_zero"}
156
-
157
-
# Lockfile check task
158
-
check-lockfile = {cmd = "poetry check", help = "Check the poetry lock file."}
159
155
160
156
# Linting/Typing fix tasks
161
-
lint-fix = { cmd = "poetry run ruff check --fix .", help = "Auto-fix any lint issues that Ruff can automatically resolve (excluding 'unsafe' fixes)." }
162
-
lint-fix-unsafe = { cmd = "poetry run ruff check --fix --unsafe-fixes .", help = "Lint-fix modified files, including 'unsafe' fixes. It is recommended to first commit any pending changes and then always manually review any unsafe changes applied." }
157
+
lint-fix = { cmd = "poetry run ruff check --fix .", help = "Auto-fix any lint issues that Ruff can automatically resolve (excluding 'unsafe' fixes) with Ruff." }
158
+
lint-fix-unsafe = { cmd = "poetry run ruff check --fix --unsafe-fixes .", help = "Lint-fix modified files, including 'unsafe' fixes with Ruff. It is recommended to first commit any pending changes and then always manually review any unsafe changes applied." }
163
159
164
160
# ruff fix everything (ignoring non-Python fixes)
165
161
ruff-fix = { sequence = ["lint-fix", "_format-fix-ruff"], help = "Lint-fix and format-fix all code." }
166
162
167
-
# Combined Check and Fix tasks
163
+
# Lockfile check task
164
+
_check-lockfile = {cmd = "poetry check", help = "Check the poetry lock file."}
168
165
169
-
check-all = {sequence = ["lint", "format-check", "type-check", "check-lockfile"], help = "Lint, format, and type-check modified files.", ignore_fail = "return_non_zero"}
166
+
# Combined Check and Fix tasks
167
+
check-all = {sequence = ["lint", "format-check", "type-check", "_check-lockfile"], help = "Lint, format, and type-check modified files.", ignore_fail = "return_non_zero"}
170
168
fix-all = {sequence = ["format-fix", "lint-fix"], help = "Lint-fix and format-fix modified files, ignoring unsafe fixes.", ignore_fail = "return_non_zero"}
171
169
fix-and-check = {sequence = ["fix-all", "check-all"], help = "Lint-fix and format-fix, then re-check to see if any issues remain.", ignore_fail = "return_non_zero"}
172
170
173
171
# PyTest tasks
174
-
175
172
pytest = {cmd = "poetry run coverage run -m pytest --durations=10", help = "Run all pytest tests."}
176
-
pytest-fast = {cmd = "poetry run coverage run -m pytest --durations=5 --exitfirst -m 'not flaky and not slow and not requires_creds'", help = "Run pytest tests, failing fast and excluding slow tests."}
173
+
pytest-fast = {cmd = "poetry run coverage run -m pytest --skipslow --durations=5 --exitfirst -m 'not flaky and not slow and not requires_creds'", help = "Run pytest tests, failing fast and excluding slow tests."}
177
174
unit-test-with-cov = {cmd = "poetry run pytest -s unit_tests --cov=airbyte_cdk --cov-report=term --cov-config ./pyproject.toml", help = "Run unit tests and create a coverage report."}
178
175
179
176
# Combined check tasks (other)
180
177
181
178
# TODO: find a version of the modified mypy check that works both locally and in CI.
182
-
check-local = {sequence = ["lint", "type-check", "check-lockfile", "unit-test-with-cov"], help = "Lint all code, type-check modified files, and run unit tests."}
183
-
check-ci = {sequence = ["check-lockfile", "build", "lint", "unit-test-with-cov"], help = "Build the package, lint and run unit tests. Does not include type-checking."}
179
+
check-local = {sequence = ["lint", "type-check", "_check-lockfile", "unit-test-with-cov"], help = "Lint all code, type-check modified files, and run unit tests."}
180
+
check-ci = {sequence = ["_check-lockfile", "build", "lint", "unit-test-with-cov"], help = "Build the package, lint and run unit tests. Does not include type-checking."}
184
181
185
182
# Build and check
186
183
pre-push = {sequence = ["build", "check-local"], help = "Run all build and check tasks."}
0 commit comments