Skip to content

Dodaios is an open-source agent OS for your desktop: it runs your coding agents, browser and apps by voice or chat, on your own machine. Formerly Personal Jarvis.

chore(i18n): translate committed German to English in test_log_summarizer/test_prompts

Ruben Lütkee6ca186b047c
diff --git a/jarvis/ui/web/server.py b/jarvis/ui/web/server.py
index da65e7f7ee..00021be3c3 100644
--- a/jarvis/ui/web/server.py
+++ b/jarvis/ui/web/server.py
@@ -70,7 +70,7 @@ _WS_SEND_TIMEOUT_S = 3.0
class WebServer:
- """In-Process uvicorn + FastAPI, betrieben vom Orchestrator-Loop."""
+ """In-process uvicorn + FastAPI, run by the orchestrator loop."""
def __init__(self, cfg: JarvisConfig, bus: EventBus | None = None) -> None:
self.cfg = cfg
@@ -78,32 +78,32 @@ class WebServer:
self._clients: dict[str, WebSocket] = {}
self._server: uvicorn.Server | None = None
self._serve_task: asyncio.Task[None] | None = None
- # PTY-Manager fuer die Desktop-App-Terminal-View. Sessions sind
- # global pro Server-Instanz — sie ueberleben WS-Reconnects, aber
- # nicht den Server-Shutdown (siehe stop()).
+ # PTY manager for the desktop-app terminal view. Sessions are
+ # global per server instance — they survive WS reconnects, but
+ # not a server shutdown (see stop()).
self._pty = PtyManager()
- # Per-Terminal Line-Buffer fuer Audit-Events.
+ # Per-terminal line buffer for audit events.
self._pty_input_buffers: dict[str, str] = {}
self._pty_shell_ids: dict[str, str] = {}
- # Skill-Registry: nach First-Run-Bootstrap auf user_skills_dir() gewatcht.
- # Watcher startet in ``start()`` sobald die Event-Loop laeuft.
+ # Skill registry: watched on user_skills_dir() after first-run bootstrap.
+ # The watcher starts in ``start()`` once the event loop is running.
self._skill_registry: Any | None = None
- # Doc-Registry: gewatcht auf default_doc_roots(); FTS5-Index unter
- # docs_index_db_path(). Watcher startet in ``start()``.
+ # Doc registry: watched on default_doc_roots(); FTS5 index under
+ # docs_index_db_path(). Watcher also starts in ``start()``.
self._doc_registry: Any | None = None
self._cli_registry: Any | None = None
self._plugin_registry: Any | None = None
- # Board-Stack wird in _setup_board() befuellt (im _build_app-Pfad).
+ # Board stack is populated in _setup_board() (in the _build_app path).
self._board_aggregator: Any | None = None
self._board_aggregator_task: asyncio.Task[None] | None = None
self._board_evaluator: Any | None = None
self._bio_scheduler: Any | None = None
self._bio_generator: Any | None = None
- # Voice-Session-Recorder — laeuft am EventBus mit, wird in
- # _init_session_stack() befuellt. None solange Recorder disabled.
+ # Voice-session recorder — runs alongside the EventBus, populated in
+ # _init_session_stack(). None while the recorder is disabled.
self._session_recorder: Any | None = None
- # Phase-5 Task-Stack (Aufgaben-View). _init_task_stack() befuellt
- # alle drei; ohne Wiring liefert /api/tasks 503 (siehe BUG-007).
+ # Phase-5 task stack (tasks view). _init_task_stack() populates
+ # all three; without wiring /api/tasks returns 503 (see BUG-007).
self._task_store: Any | None = None
self._task_scheduler: Any | None = None
self._task_runner: Any | None = None
diff --git a/tests/missions/critic/test_log_summarizer.py b/tests/missions/critic/test_log_summarizer.py
index f5e963e8a9..992b043135 100644
--- a/tests/missions/critic/test_log_summarizer.py
+++ b/tests/missions/critic/test_log_summarizer.py
@@ -1,4 +1,4 @@
-"""Tests fuer log_summarizer (head/tail/grep + optional Haiku-triage)."""
+"""Tests for log_summarizer (head/tail/grep + optional Haiku triage)."""
from __future__ import annotations
import asyncio
@@ -84,7 +84,7 @@ async def test_error_grep_dedups_repeated_lines() -> None:
out = await summarize_log(log, max_chars=10_000)
error_section_start = out.index("ERRORS")
error_section = out[error_section_start:]
- # nur EIN "Error: same"-Eintrag im error-Block (dedup)
+ # only ONE "Error: same" entry in the error block (dedup)
error_block_lines = error_section.split("\n")
error_count = sum(1 for line in error_block_lines if line == "Error: same")
assert error_count == 1
@@ -119,7 +119,7 @@ async def test_triage_fn_called_on_large_log() -> None:
log = "x" * (TRIAGE_THRESHOLD_CHARS + 1)
out = await summarize_log(log, triage_fn=fake_triage, max_chars=1000)
- assert called, "triage_fn wurde nicht aufgerufen"
+ assert called, "triage_fn was not called"
assert "TRIAGED_SUMMARY" in out
@@ -138,7 +138,7 @@ async def test_triage_fn_not_called_below_threshold() -> None:
@pytest.mark.asyncio
async def test_triage_fn_crash_falls_back_to_pure_python() -> None:
- """Triage darf den Critic NIE blockieren — Fallback auf head/tail/grep."""
+ """Triage must NEVER block the Critic — fallback to head/tail/grep."""
async def crashing_triage(_text: str) -> str:
raise RuntimeError("brain manager kaputt")
@@ -146,7 +146,7 @@ async def test_triage_fn_crash_falls_back_to_pure_python() -> None:
log = "head\n" * 10 + "tail\n" * 10
log = log + "x" * (TRIAGE_THRESHOLD_CHARS + 1)
out = await summarize_log(log, triage_fn=crashing_triage, max_chars=10_000)
- # Fallback ist head/tail-Rendering (kein Crash, kein leerer String).
+ # Fallback is head/tail rendering (no crash, no empty string).
assert "HEAD" in out
diff --git a/tests/missions/critic/test_prompts.py b/tests/missions/critic/test_prompts.py
index 8a494931ea..0bf3e6734d 100644
--- a/tests/missions/critic/test_prompts.py
+++ b/tests/missions/critic/test_prompts.py
@@ -1,10 +1,10 @@
-"""Tests fuer Critic-Prompt-Templates.
+"""Tests for the Critic prompt templates.
-Pruefen explizit die fuenf Design-Reviewer-Kriterien aus
+Explicitly checks the five design-reviewer criteria from
`.claude/agents/jarvis-critic-design-reviewer.md`:
-- Kriterium 1 — Evidence-Cite-Pflicht (Prompt verlangt file:line / log_line:N / test:name).
-- Kriterium 2 — Adversarial Framing verbatim aus Research-Doc §F.
-- Kriterium 3 — Anchor-Token (mission_prompt verbatim, triple-bracketed).
+- Criterion 1 — evidence-cite requirement (prompt demands file:line / log_line:N / test:name).
+- Criterion 2 — adversarial framing verbatim from the research doc §F.
+- Criterion 3 — anchor token (mission_prompt verbatim, triple-bracketed).
"""
from __future__ import annotations
@@ -15,7 +15,7 @@ from jarvis.missions.critic.prompts import (
)
-# --- Kriterium 2 — Adversarial Framing ---
+# --- Criterion 2 — Adversarial Framing ---
def test_template_contains_skeptical_phrasing() -> None:
@@ -37,7 +37,7 @@ def test_template_uses_adversarial_role() -> None:
assert "adversarial code critic" in CRITIC_SYSTEM_PROMPT
-# --- Kriterium 1 — Evidence-Cite-Pflicht ---
+# --- Criterion 1 — Evidence-Cite Requirement ---
def test_template_requires_evidence_format() -> None:
@@ -54,11 +54,11 @@ def test_template_rejects_empty_evidence_fail() -> None:
assert "Empty-evidence FAILs are treated as abstentions" in CRITIC_SYSTEM_PROMPT
-# --- Kriterium 3 — Anchor-Token ---
+# --- Criterion 3 — Anchor Token ---
def test_anchor_token_triple_bracketed_in_template() -> None:
- """Das Template enthaelt die Bracket-Marker — nicht den eingesetzten String."""
+ """The template contains the bracket markers — not the substituted string."""
assert "<<<{mission_prompt}>>>" in CRITIC_SYSTEM_PROMPT
@@ -75,7 +75,7 @@ def test_render_includes_mission_prompt_verbatim() -> None:
def test_render_does_not_paraphrase_mission_prompt() -> None:
- """Selbst bei langen Prompts mit Sonderzeichen verbatim einsetzen."""
+ """Insert verbatim even for long prompts with special characters."""
weird = "Build X with !@#$%^&*() in the name and \"quoted\" parts."
out = render_critic_prompt(
mission_prompt=weird,
@@ -104,7 +104,7 @@ def test_template_includes_output_schema_keys() -> None:
def test_template_demands_no_prose_no_markdown() -> None:
- """`no prose` + `markdown` koennen ueber einen Zeilenumbruch verteilt sein."""
+ """`no prose` + `markdown` can be split across a line break."""
assert "no prose" in CRITIC_SYSTEM_PROMPT
assert "markdown" in CRITIC_SYSTEM_PROMPT
assert "no code fences" in CRITIC_SYSTEM_PROMPT
@@ -219,7 +219,7 @@ def test_adversarial_prefix_emphasizes_skepticism() -> None:
def test_render_anchor_present_in_both_modes() -> None:
- """Anchor-Token muss auch im Adversarial-Reframe-Modus drin sein."""
+ """The anchor token must also be present in adversarial-reframe mode."""
out = render_critic_prompt(
mission_prompt="ANCHOR_X",
worker_diff="d",