deepctl-cmd-plugin 0.1.11__tar.gz → 0.1.12__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.
- {deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/.gitignore +3 -1
- {deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/CHANGELOG.md +7 -0
- {deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/PKG-INFO +1 -1
- {deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/pyproject.toml +1 -1
- {deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/tests/unit/test_plugin_command.py +68 -75
- {deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/README.md +0 -0
- {deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/src/deepctl_cmd_plugin/__init__.py +0 -0
- {deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/src/deepctl_cmd_plugin/command.py +0 -0
- {deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/src/deepctl_cmd_plugin/models.py +0 -0
- {deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/src/deepctl_cmd_plugin/strategies.py +0 -0
- {deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/tests/__init__.py +0 -0
- {deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/tests/unit/__init__.py +0 -0
- {deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/tests/unit/test_strategies.py +0 -0
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [0.1.12](https://github.com/deepgram/cli/compare/deepctl-cmd-plugin-v0.1.11...deepctl-cmd-plugin-v0.1.12) (2026-05-09)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* **telemetry:** full Sentry observability + per-command usage tags ([#75](https://github.com/deepgram/cli/issues/75)) ([0fe43d2](https://github.com/deepgram/cli/commit/0fe43d2e00c58d8101ef2bd4b5aaf4437db9f0cf))
|
|
9
|
+
|
|
3
10
|
## [0.1.11](https://github.com/deepgram/cli/compare/deepctl-cmd-plugin-v0.1.10...deepctl-cmd-plugin-v0.1.11) (2026-03-09)
|
|
4
11
|
|
|
5
12
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
name = "deepctl-cmd-plugin"
|
|
3
3
|
description = "Plugin management command for deepctl"
|
|
4
4
|
readme = "README.md"
|
|
5
|
-
version = "0.1.
|
|
5
|
+
version = "0.1.12" # x-release-please-version
|
|
6
6
|
requires-python = ">=3.10"
|
|
7
7
|
authors = [{ name = "Deepgram DevRel", email = "devrel@deepgram.com" }]
|
|
8
8
|
dependencies = [
|
|
@@ -79,12 +79,11 @@ class TestPluginCommand:
|
|
|
79
79
|
"""Test getting plugin state from existing file."""
|
|
80
80
|
test_state = {"plugins": {"test-plugin": {"version": "1.0.0"}}}
|
|
81
81
|
|
|
82
|
-
with patch.object(Path, "exists", return_value=True)
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
)
|
|
86
|
-
|
|
87
|
-
assert state == test_state
|
|
82
|
+
with patch.object(Path, "exists", return_value=True), patch.object(
|
|
83
|
+
Path, "read_text", return_value=json.dumps(test_state)
|
|
84
|
+
):
|
|
85
|
+
state = self.command._get_plugin_state()
|
|
86
|
+
assert state == test_state
|
|
88
87
|
|
|
89
88
|
def test_save_plugin_state(self) -> None:
|
|
90
89
|
"""Test saving plugin state."""
|
|
@@ -140,34 +139,32 @@ class TestPluginCommand:
|
|
|
140
139
|
# Mock state and version operations
|
|
141
140
|
with patch.object(
|
|
142
141
|
self.command, "_get_plugin_state"
|
|
143
|
-
) as mock_get_state
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
# Should save plugin state
|
|
170
|
-
mock_save_state.assert_called_once()
|
|
142
|
+
) as mock_get_state, patch.object(
|
|
143
|
+
self.command, "_save_plugin_state"
|
|
144
|
+
) as mock_save_state, patch.object(
|
|
145
|
+
self.command,
|
|
146
|
+
"_get_package_version",
|
|
147
|
+
return_value="1.0.0",
|
|
148
|
+
):
|
|
149
|
+
mock_get_state.return_value = {"plugins": {}}
|
|
150
|
+
|
|
151
|
+
options = PluginInstallOptions(
|
|
152
|
+
package="test-plugin"
|
|
153
|
+
)
|
|
154
|
+
result = self.command.install_plugin(
|
|
155
|
+
self.config,
|
|
156
|
+
self.auth_manager,
|
|
157
|
+
self.client,
|
|
158
|
+
options,
|
|
159
|
+
)
|
|
160
|
+
|
|
161
|
+
assert result.success is True
|
|
162
|
+
assert "Successfully installed" in result.message
|
|
163
|
+
# Strategy should use the plugin env python
|
|
164
|
+
cmd = mock_strategy_run.call_args[0][0]
|
|
165
|
+
assert cmd[0] == "/path/to/plugin/python"
|
|
166
|
+
# Should save plugin state
|
|
167
|
+
mock_save_state.assert_called_once()
|
|
171
168
|
|
|
172
169
|
def test_install_plugin_git_url(self) -> None:
|
|
173
170
|
"""Test handling git URL in install options."""
|
|
@@ -317,32 +314,29 @@ class TestPluginCommand:
|
|
|
317
314
|
|
|
318
315
|
with patch.object(
|
|
319
316
|
self.command, "_discover_plugins", return_value=test_plugins
|
|
320
|
-
)
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
"system" in str(call).lower()
|
|
344
|
-
for call in mock_print_info.call_args_list
|
|
345
|
-
)
|
|
317
|
+
), patch(
|
|
318
|
+
"deepctl_cmd_plugin.command.console.print"
|
|
319
|
+
) as mock_print, patch(
|
|
320
|
+
"deepctl_cmd_plugin.command.print_info"
|
|
321
|
+
) as mock_print_info, patch.object(
|
|
322
|
+
self.command.detector, "detect"
|
|
323
|
+
) as mock_detect:
|
|
324
|
+
mock_detect.return_value.method = InstallMethod.SYSTEM
|
|
325
|
+
|
|
326
|
+
self.command.list_plugins(
|
|
327
|
+
self.config,
|
|
328
|
+
self.auth_manager,
|
|
329
|
+
self.client,
|
|
330
|
+
verbose=True,
|
|
331
|
+
)
|
|
332
|
+
|
|
333
|
+
# Should print a table
|
|
334
|
+
mock_print.assert_called_once()
|
|
335
|
+
# Should show system installation info via print_info
|
|
336
|
+
assert any(
|
|
337
|
+
"system" in str(call).lower()
|
|
338
|
+
for call in mock_print_info.call_args_list
|
|
339
|
+
)
|
|
346
340
|
|
|
347
341
|
def test_setup_commands(self) -> None:
|
|
348
342
|
"""Test that all subcommands are properly set up."""
|
|
@@ -396,21 +390,20 @@ class TestPluginCommand:
|
|
|
396
390
|
# Test search all
|
|
397
391
|
with patch(
|
|
398
392
|
"deepctl_cmd_plugin.command.console.print"
|
|
399
|
-
) as mock_print
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
self.
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
)
|
|
393
|
+
) as mock_print, patch(
|
|
394
|
+
"deepctl_cmd_plugin.command.print_info"
|
|
395
|
+
) as mock_info:
|
|
396
|
+
self.command._handle_search(
|
|
397
|
+
self.config, self.auth_manager, self.client
|
|
398
|
+
)
|
|
399
|
+
|
|
400
|
+
# Should print a table
|
|
401
|
+
mock_print.assert_called_once()
|
|
402
|
+
# Should show install hint
|
|
403
|
+
assert any(
|
|
404
|
+
"install" in str(call)
|
|
405
|
+
for call in mock_info.call_args_list
|
|
406
|
+
)
|
|
414
407
|
|
|
415
408
|
# Test search with query
|
|
416
409
|
with patch(
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{deepctl_cmd_plugin-0.1.11 → deepctl_cmd_plugin-0.1.12}/src/deepctl_cmd_plugin/strategies.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|