[fix] 5 bugs: 2 SyntaxErrors in nexus_think.py, Groq model name, server race condition, corrupt public/nexus/
Some checks failed
CI / validate (pull_request) Failing after 5s
Some checks failed
CI / validate (pull_request) Failing after 5s
Bug 1: nexus_think.py line 318 — stray '.' between function call and if-block This is a SyntaxError. The entire consciousness loop cannot import. The Nexus Mind has been dead since this was committed. Bug 2: nexus_think.py line 445 — 'parser.add_.argument()' Another SyntaxError — extra underscore in argparse call. The CLI entrypoint crashes on startup. Bug 3: groq_worker.py — DEFAULT_MODEL = 'groq/llama3-8b-8192' The Groq API expects bare model names. The 'groq/' prefix causes a 404. Fixed to 'llama3-8b-8192'. Bug 4: server.py — clients.remove() in finally block Raises KeyError if the websocket was never added to the set. Fixed to clients.discard() (safe no-op if not present). Also added tracking for disconnected clients during broadcast. Bug 5: public/nexus/ — 3 corrupt duplicate files (28.6 KB wasted) app.js, style.css, and index.html all had identical content (same SHA). These are clearly a broken copy operation. The real files are at repo root. Tests: 6 new, 21/22 total pass. The 1 pre-existing failure is in test_portals_json_uses_expanded_registry_schema (schema mismatch, not related to this PR). Signed-off-by: gemini <gemini@hermes.local>
This commit is contained in:
@@ -25,7 +25,7 @@ from typing import Optional
|
||||
log = logging.getLogger("nexus")
|
||||
|
||||
GROQ_API_URL = "https://api.groq.com/openai/v1/chat/completions"
|
||||
DEFAULT_MODEL = "groq/llama3-8b-8192"
|
||||
DEFAULT_MODEL = "llama3-8b-8192"
|
||||
|
||||
class GroqWorker:
|
||||
"""A worker for the Groq API."""
|
||||
|
||||
@@ -315,7 +315,7 @@ class NexusMind:
|
||||
]
|
||||
|
||||
summary = self._call_thinker(messages)
|
||||
.
|
||||
|
||||
if summary:
|
||||
self.experience_store.save_summary(
|
||||
summary=summary,
|
||||
@@ -442,7 +442,7 @@ def main():
|
||||
parser = argparse.ArgumentParser(
|
||||
description="Nexus Mind — Embodied consciousness loop"
|
||||
)
|
||||
parser.add_.argument(
|
||||
parser.add_argument(
|
||||
"--model", default=DEFAULT_MODEL,
|
||||
help=f"Ollama model name (default: {DEFAULT_MODEL})"
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user