[PR #4161] [TUI] readiness: probe /v1/telemetry with the telemetry key when there is no API key #4930

Open
opened 2026-11-07 16:31:25 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Niko1221/Strata/pull/4161
Author: @JbareenM
Created: 10/25/2026
Status: 🔄 Open

Base: main ← Head: fix/readiness-telemetry-key


📝 Commits (1)

  • bd7c68d [TUI] readiness: probe /v1/telemetry with the telemetry key when there is no API key

📊 Changes

2 files changed (+28 additions, -4 deletions)

View changed files

📝 strata_control/readiness.py (+14 -1)
📝 tests/terminal/test_runtime.py (+14 -3)

📄 Description

Problem and result

With STRATA_TELEMETRY_KEY set in the environment (the read-only monitor key, set once for strata monitor), a
launch of a profile that has no API key never becomes ready:

strata: The server did not become ready (failed: probe_http_401)

The server takes STRATA_TELEMETRY_KEY (or the config's telemetry_read_key) and then wants a key on
/v1/telemetry. strata_control/readiness.py reads that endpoint first, but sends only the inference API key, and
a profile without one sends none. Reproduced with a strata launch ... --access local --no-tui (no key) and in the
new test below; the same launch with --new-key starts.

Approach

verify() reads /v1/telemetry with the API key when there is one (the server accepts it there too), else with
the telemetry key taken from the same places the server takes it (STRATA_TELEMETRY_KEY, then
telemetry_read_key). The chat-completion probe still uses the API key only. A server without either key is
unchanged (no Authorization header).

tests/terminal/test_runtime.py: setUp clears STRATA_TELEMETRY_KEY as it already clears STRATA_API_KEY, so a
developer's own key does not change the other tests (with it set, test_managed_benchmark_binds_to_owned_launch
failed with 401 here). A new test sets the key and checks that runtime.start and runtime.verify pass.

Validation

  • The new test fails on main with probe_http_401 and passes with the change.
  • tests/terminal/test_runtime.py and tests/terminal/test_launch_identity.py: 48 passed, 2 failed. Both failures
    also happen on main on this PC and are unrelated: test_local_management_bridge_and_cli_share_owner_and_journal
    (PermissionError: [WinError 32], a file still open on Windows) and
    test_liveness_check_does_not_end_the_process_it_asks_about (fails only inside the full file; passed 3 of 3 runs
    alone, with and without the change).
  • Not tested: Linux, macOS.

Environment: Windows 11 Pro, RTX 5070 Ti 16 GB, Ryzen 9 9950X3D, 64 GB RAM, NVIDIA driver 621.01; Strata app 0.2.6,
control 0.1.51, engine 0.1.48; branch based on 4b9e05a2.

AI assistance: prepared with Claude Code.

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Niko1221/Strata/pull/4161 **Author:** [@JbareenM](https://github.com/JbareenM) **Created:** 10/25/2026 **Status:** 🔄 Open **Base:** `main` ← **Head:** `fix/readiness-telemetry-key` --- ### 📝 Commits (1) - [`bd7c68d`](https://github.com/Niko1221/Strata/commit/bd7c68da685579f58553f4d09aca706e25ce6adf) [TUI] readiness: probe /v1/telemetry with the telemetry key when there is no API key ### 📊 Changes **2 files changed** (+28 additions, -4 deletions) <details> <summary>View changed files</summary> 📝 `strata_control/readiness.py` (+14 -1) 📝 `tests/terminal/test_runtime.py` (+14 -3) </details> ### 📄 Description ## Problem and result With `STRATA_TELEMETRY_KEY` set in the environment (the read-only monitor key, set once for `strata monitor`), a launch of a profile that has no API key never becomes ready: ``` strata: The server did not become ready (failed: probe_http_401) ``` The server takes `STRATA_TELEMETRY_KEY` (or the config's `telemetry_read_key`) and then wants a key on `/v1/telemetry`. `strata_control/readiness.py` reads that endpoint first, but sends only the inference API key, and a profile without one sends none. Reproduced with a `strata launch ... --access local --no-tui` (no key) and in the new test below; the same launch with `--new-key` starts. ## Approach `verify()` reads `/v1/telemetry` with the API key when there is one (the server accepts it there too), else with the telemetry key taken from the same places the server takes it (`STRATA_TELEMETRY_KEY`, then `telemetry_read_key`). The chat-completion probe still uses the API key only. A server without either key is unchanged (no Authorization header). `tests/terminal/test_runtime.py`: `setUp` clears `STRATA_TELEMETRY_KEY` as it already clears `STRATA_API_KEY`, so a developer's own key does not change the other tests (with it set, `test_managed_benchmark_binds_to_owned_launch` failed with 401 here). A new test sets the key and checks that `runtime.start` and `runtime.verify` pass. ## Validation - The new test fails on main with `probe_http_401` and passes with the change. - `tests/terminal/test_runtime.py` and `tests/terminal/test_launch_identity.py`: 48 passed, 2 failed. Both failures also happen on main on this PC and are unrelated: `test_local_management_bridge_and_cli_share_owner_and_journal` (`PermissionError: [WinError 32]`, a file still open on Windows) and `test_liveness_check_does_not_end_the_process_it_asks_about` (fails only inside the full file; passed 3 of 3 runs alone, with and without the change). - Not tested: Linux, macOS. Environment: Windows 11 Pro, RTX 5070 Ti 16 GB, Ryzen 9 9950X3D, 64 GB RAM, NVIDIA driver 621.01; Strata app 0.2.6, control 0.1.51, engine 0.1.48; branch based on 4b9e05a2. AI assistance: prepared with Claude Code. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Niko1221/Strata#4930
No description provided.