-
Notifications
You must be signed in to change notification settings - Fork 0
feat: support all ovos core services + CLI tooling for ovoscope #46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
d54f0a9
feat: add CLI, PHAL/OCP/pipeline harnesses, coverage scanner, GUI cap…
JarbasAl d351e9d
fix(coverage): add setup.py scanning + legacy ovos.plugin.* entry poi…
JarbasAl 6d66963
Fix CodeRabbit PR #46 review comments (critical, major, and minor iss…
JarbasAl 7b21318
Require stable ovos-audio>=1.2.0 in audio extra
JarbasAl 9e1e05a
feat(listener): add VAD and WakeWord support to MiniListener
JarbasAl ac066ed
docs: fill documentation gaps identified in /docs review
JarbasAl File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,134 @@ | ||
| # ovoscope CLI | ||
|
|
||
| The `ovoscope` command-line tool provides five subcommands for recording, | ||
| replaying, diffing, validating, and scanning E2E test fixtures. | ||
|
|
||
| ## Installation | ||
|
|
||
| After installing the package (``pip install ovoscope``), the ``ovoscope`` | ||
| command is available on your ``$PATH``. | ||
|
|
||
| ```bash | ||
| ovoscope --help | ||
| ``` | ||
|
|
||
| --- | ||
|
|
||
| ## Subcommands | ||
|
|
||
| ### `ovoscope record` — Record a fixture | ||
|
|
||
| **In-process recording** (default): loads the skill(s) inside the current | ||
| process using `MiniCroft` — `cli.py:cmd_record`. | ||
|
|
||
| ```bash | ||
| ovoscope record \ | ||
| --skill-id ovos-skill-hello-world.openvoiceos \ | ||
| --utterance "hello" \ | ||
| --output fixture.json \ | ||
| --lang en-US \ | ||
| --timeout 20 | ||
| ``` | ||
|
|
||
| **Live recording** from a running OVOS instance (`RemoteRecorder` — | ||
| `remote_recorder.py:RemoteRecorder.record`): | ||
|
|
||
| ```bash | ||
| ovoscope record --live \ | ||
| --bus-url ws://localhost:8181/core \ | ||
| --skill-id ovos-skill-date-time.openvoiceos \ | ||
| --utterance "what time is it" \ | ||
| --output datetime_fixture.json | ||
| ``` | ||
|
|
||
| | Flag | Default | Description | | ||
| |------|---------|-------------| | ||
| | `--skill-id` | — | OPM skill IDs to load (repeatable). | | ||
| | `--utterance` | **required** | User utterance text. | | ||
| | `--output` | **required** | Output fixture JSON path. | | ||
| | `--lang` | `en-US` | Language tag. | | ||
| | `--pipeline` | None | Comma-separated pipeline stage IDs. | | ||
| | `--timeout` | `20.0` | Capture timeout in seconds. | | ||
| | `--live` | False | Use live OVOS instance via `RemoteRecorder`. | | ||
| | `--bus-url` | `ws://localhost:8181/core` | MessageBus URL (only for `--live`). | | ||
|
|
||
| --- | ||
|
|
||
| ### `ovoscope run` — Replay a fixture | ||
|
|
||
| Replays a saved fixture file and exits with code 1 on failure — | ||
| `cli.py:cmd_run`. | ||
|
|
||
| ```bash | ||
| ovoscope run test/fixtures/hello.json | ||
| ovoscope run test/fixtures/hello.json --verbose --timeout 30 | ||
| ``` | ||
|
|
||
| | Flag | Default | Description | | ||
| |------|---------|-------------| | ||
| | `fixture` | **required** | Path to fixture JSON file. | | ||
| | `--verbose` | False | Print failure details. | | ||
| | `--timeout` | `30.0` | Execution timeout in seconds. | | ||
|
|
||
| --- | ||
|
|
||
| ### `ovoscope diff` — Compare two fixtures | ||
|
|
||
| Compares two fixture files and prints a colored report — | ||
| `diff.py:diff_fixtures`, `cli.py:cmd_diff`. | ||
|
|
||
| ```bash | ||
| ovoscope diff expected.json actual.json | ||
| ovoscope diff expected.json actual.json --no-color | ||
| ``` | ||
|
|
||
| Exits 0 if identical, 1 if differences are found. | ||
|
|
||
| | Flag | Default | Description | | ||
| |------|---------|-------------| | ||
| | `expected` | **required** | Reference fixture path. | | ||
| | `actual` | **required** | Fixture to compare against reference. | | ||
| | `--no-color` | False | Disable ANSI color codes. | | ||
| | `--include-context` | False | Include `context` fields in the comparison. By default context is ignored because it contains ephemeral routing metadata (`source`, `destination`, `session`) that varies between runs. Pass `--include-context` when you specifically want to assert routing behaviour. | | ||
|
|
||
| --- | ||
|
|
||
| ### `ovoscope validate` — Schema-validate fixtures | ||
|
|
||
| Validates one or more fixture files against the expected schema — | ||
| `cli.py:cmd_validate`. | ||
|
|
||
| ```bash | ||
| ovoscope validate test/fixtures/*.json | ||
| ``` | ||
|
|
||
| Uses `pydantic_helpers.validate_fixture` when available (requires | ||
| `pip install ovoscope[pydantic]`); falls back to basic JSON structure | ||
| validation (checks required top-level keys and that `expected_messages` | ||
| is a list) when the `pydantic` extra is not installed. | ||
|
|
||
| --- | ||
|
|
||
| ### `ovoscope coverage` — Ecosystem coverage scan | ||
|
|
||
| Scans a workspace root for OVOS plugin repos and reports E2E test coverage — | ||
| `coverage.py:scan_workspace`, `cli.py:cmd_coverage`. | ||
|
|
||
| ```bash | ||
| ovoscope coverage "OpenVoiceOS Workspace/" --format table | ||
| ovoscope coverage "OpenVoiceOS Workspace/" --format json | ||
| ``` | ||
|
|
||
| | Flag | Default | Description | | ||
| |------|---------|-------------| | ||
| | `workspace` | **required** | Workspace root directory. | | ||
| | `--format` | `table` | Output format: `table` or `json`. | | ||
|
|
||
| --- | ||
|
|
||
| ## Exit Codes | ||
|
|
||
| | Code | Meaning | | ||
| |------|---------| | ||
| | 0 | Success / no differences / all valid | | ||
| | 1 | Failure / differences found / validation error | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.