datasecops-cli 0.2.4__tar.gz → 0.2.6__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/CHANGELOG.md +12 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/PKG-INFO +1 -1
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/pyproject.toml +1 -1
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/menus/development.py +1 -1
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/menus/downloads.py +1 -1
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/services/bootstrap_service.py +1 -1
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/services/download_service.py +16 -14
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/services/linting_service.py +2 -2
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/.github/workflows/publish-cli.yml +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/.gitignore +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/DEVELOPMENT.md +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/LICENSE +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/README.md +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/docs/getting-started.md +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/docs/legacy.md +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/docs/legacy_plan_of_action.md +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/docs/mcp-server.md +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/mcp-servers.json +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/setup.ps1 +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/setup.sh +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/__init__.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/config.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/main.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/menus/__init__.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/menus/git_operations.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/models/__init__.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/models/git_helpers.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/models/project_config.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/services/__init__.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/services/dbt_runner.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/services/git_service.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/services/skill_service.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/services/snowflake_service.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/utilities/__init__.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/utilities/display.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/utilities/file_utils.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/utilities/yaml_utils.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_mcp/__init__.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_mcp/__main__.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_mcp/connection.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_mcp/server.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/tests/__init__.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/tests/test_config.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/tests/test_file_utils.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/tests/test_models.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/tests/test_version.py +0 -0
- {datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/tests/test_yaml_utils.py +0 -0
|
@@ -2,6 +2,18 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to the DataSecOps CLI are documented in this file.
|
|
4
4
|
|
|
5
|
+
## [0.2.6] - 2026-05-11
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
|
|
9
|
+
- **Include `dbt-core` and `dbt-snowflake` in framework requirements** — `get_sqlfluff_requirements()` now fetches all four active versions from the native app (`sqlfluff`, `sqlfluff-templater-dbt`, `dbt-core`, `dbt-snowflake`) and the lint menu ensures they are all installed at the correct pinned versions before linting, resolving the "Could not find adapter type snowflake!" error
|
|
10
|
+
|
|
11
|
+
## [0.2.5] - 2026-05-11
|
|
12
|
+
|
|
13
|
+
### Fixed
|
|
14
|
+
|
|
15
|
+
- **`.sqlfluff` now written to the dbt project directory** instead of the repo root — `download_sqlfluff_config()` accepts a `dbt_project_dir` parameter and all callers (lint menu, downloads menu, bootstrap) pass the resolved dbt directory so the config lands alongside `dbt_project.yml` where sqlfluff expects it
|
|
16
|
+
|
|
5
17
|
## [0.2.4] - 2026-05-11
|
|
6
18
|
|
|
7
19
|
### Fixed
|
|
@@ -148,7 +148,7 @@ class DevelopmentMenu:
|
|
|
148
148
|
error_line("No .sqlfluff config found and download service not available")
|
|
149
149
|
return False
|
|
150
150
|
info_line("No .sqlfluff config found — downloading from framework...")
|
|
151
|
-
if not self.downloads.download_sqlfluff_config(profiles_dir=self.profiles_dir):
|
|
151
|
+
if not self.downloads.download_sqlfluff_config(profiles_dir=self.profiles_dir, dbt_project_dir=self.linting.project_dir):
|
|
152
152
|
return False
|
|
153
153
|
# Fetch pinned versions from the native app and ensure they're installed
|
|
154
154
|
required = self.downloads.get_sqlfluff_requirements() if self.downloads else None
|
|
@@ -30,7 +30,7 @@ class DownloadsMenu:
|
|
|
30
30
|
if option == 1:
|
|
31
31
|
display_action_header("Download SQLFluff Config")
|
|
32
32
|
profiles_dir = str(Path(self.project_settings.profile_dir).expanduser()) if self.project_settings else None
|
|
33
|
-
self.downloads.download_sqlfluff_config(profiles_dir=profiles_dir)
|
|
33
|
+
self.downloads.download_sqlfluff_config(profiles_dir=profiles_dir, dbt_project_dir=self.dbt_project_dir)
|
|
34
34
|
complete_action()
|
|
35
35
|
elif option == 2:
|
|
36
36
|
display_action_header("Download Pipeline Files")
|
{datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/services/bootstrap_service.py
RENAMED
|
@@ -69,7 +69,7 @@ class BootstrapService:
|
|
|
69
69
|
info_line("")
|
|
70
70
|
info_line("[3] Downloading SQLFluff configuration...")
|
|
71
71
|
profiles_dir = str(Path(self.project_settings.profile_dir).expanduser())
|
|
72
|
-
if self.download_service.download_sqlfluff_config(profiles_dir=profiles_dir):
|
|
72
|
+
if self.download_service.download_sqlfluff_config(profiles_dir=profiles_dir, dbt_project_dir=dbt_project_dir):
|
|
73
73
|
steps_passed += 1
|
|
74
74
|
else:
|
|
75
75
|
info_line(" (skipped - no SQLFluff config in native app)")
|
{datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/services/download_service.py
RENAMED
|
@@ -95,7 +95,7 @@ class DownloadService:
|
|
|
95
95
|
lines.append(f"{key} = {DownloadService._format_value(val)}")
|
|
96
96
|
lines.append("")
|
|
97
97
|
|
|
98
|
-
def download_sqlfluff_config(self, profiles_dir: str = None) -> bool:
|
|
98
|
+
def download_sqlfluff_config(self, profiles_dir: str = None, dbt_project_dir: Path = None) -> bool:
|
|
99
99
|
info_line("Downloading SQLFluff configuration...")
|
|
100
100
|
raw = self.sf.get_framework_config("SQLFLUFF_RULES")
|
|
101
101
|
if not raw:
|
|
@@ -163,13 +163,13 @@ class DownloadService:
|
|
|
163
163
|
self._emit_section(lines, f"sqlfluff:rules:{section_name}", opts)
|
|
164
164
|
|
|
165
165
|
content = "\n".join(lines)
|
|
166
|
-
dest = self.project_dir / ".sqlfluff"
|
|
166
|
+
dest = (dbt_project_dir or self.project_dir) / ".sqlfluff"
|
|
167
167
|
write_file(dest, content)
|
|
168
168
|
success_line(f"SQLFluff config written to {dest}")
|
|
169
169
|
return True
|
|
170
170
|
|
|
171
171
|
def get_sqlfluff_requirements(self) -> list[str]:
|
|
172
|
-
"""Fetch active sqlfluff package versions from the framework."""
|
|
172
|
+
"""Fetch active sqlfluff and dbt package versions from the framework."""
|
|
173
173
|
info_line("Fetching SQLFluff requirements from framework...")
|
|
174
174
|
raw = self.sf.get_framework_config("DBT_VERSIONS")
|
|
175
175
|
if not raw:
|
|
@@ -178,20 +178,22 @@ class DownloadService:
|
|
|
178
178
|
|
|
179
179
|
packages = []
|
|
180
180
|
|
|
181
|
-
#
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
181
|
+
# Map of config key -> pip package name
|
|
182
|
+
version_keys = {
|
|
183
|
+
"sqlfluff_versions": "sqlfluff",
|
|
184
|
+
"sqlfluff_templater_versions": "sqlfluff-templater-dbt",
|
|
185
|
+
"dbt_core_versions": "dbt-core",
|
|
186
|
+
"dbt_snowflake_versions": "dbt-snowflake",
|
|
187
|
+
}
|
|
186
188
|
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
189
|
+
for config_key, pkg_name in version_keys.items():
|
|
190
|
+
for entry in raw.get(config_key, []):
|
|
191
|
+
if entry.get("active"):
|
|
192
|
+
packages.append(f"{pkg_name}=={entry['version']}")
|
|
193
|
+
break
|
|
192
194
|
|
|
193
195
|
if not packages:
|
|
194
|
-
error_line("No active
|
|
196
|
+
error_line("No active versions found in framework configuration")
|
|
195
197
|
|
|
196
198
|
return packages
|
|
197
199
|
|
{datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/services/linting_service.py
RENAMED
|
@@ -13,7 +13,7 @@ class LintingService:
|
|
|
13
13
|
def get_installed_versions(self) -> dict[str, str]:
|
|
14
14
|
"""Get currently installed versions of sqlfluff packages."""
|
|
15
15
|
versions = {}
|
|
16
|
-
for package in ["sqlfluff", "sqlfluff-templater-dbt"]:
|
|
16
|
+
for package in ["sqlfluff", "sqlfluff-templater-dbt", "dbt-core", "dbt-snowflake"]:
|
|
17
17
|
result = subprocess.run(
|
|
18
18
|
["uv", "pip", "show", package],
|
|
19
19
|
capture_output=True, text=True
|
|
@@ -76,7 +76,7 @@ class LintingService:
|
|
|
76
76
|
return self.install_requirements(to_install)
|
|
77
77
|
|
|
78
78
|
# No pinned versions — just ensure packages are present
|
|
79
|
-
missing = [pkg for pkg in ["sqlfluff", "sqlfluff-templater-dbt"] if not installed.get(pkg)]
|
|
79
|
+
missing = [pkg for pkg in ["sqlfluff", "sqlfluff-templater-dbt", "dbt-core", "dbt-snowflake"] if not installed.get(pkg)]
|
|
80
80
|
if not missing:
|
|
81
81
|
return True
|
|
82
82
|
warning_line(f"Missing packages: {', '.join(missing)}")
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{datasecops_cli-0.2.4 → datasecops_cli-0.2.6}/src/datasecops_cli/services/snowflake_service.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|