mirror of
https://github.com/pewdiepie-archdaemon/odysseus.git
synced 2026-07-08 11:56:59 +00:00
038bdd85ec
Align regression tests with the current Odysseus behavior after merging origin/dev into local main. - keep phone/name-only contacts valid and cover null email without crashes - pin explicit web-search false form submission in chat.js - update Cookbook dependency/download completion tests for combined live + persisted output - expose SGLang OS package repair hints from backend diagnosis - treat MLX and MLX-community repos as servable on Apple Metal while keeping CUDA behavior unchanged - keep desktop new-chat coverage on the shared preferred-model helper - remove a hardcoded crop overlay portal z-index literal - include the local agent-loop cleanup that removes the old manage_notes reminder repair shim Verified with: docker run --rm -v /home/pewds/odysseus-cookbook-fresh:/app -w /app odysseus-cookbook-fresh-odysseus python3 -m pytest -q (4515 passed, 4 skipped).
37 lines
1.3 KiB
Python
37 lines
1.3 KiB
Python
from routes.cookbook_helpers import _diagnose_serve_output
|
|
|
|
|
|
def test_diagnose_vllm_modelopt_lm_head_error():
|
|
output = """
|
|
ValueError: There is no module or parameter named 'lm_head.input_scale'
|
|
Engine core initialization failed.
|
|
"""
|
|
|
|
diagnosis = _diagnose_serve_output(output)
|
|
|
|
assert diagnosis is not None
|
|
assert "ModelOpt LM-head" in diagnosis["message"]
|
|
assert diagnosis["suggestions"][0]["op"] == "manual"
|
|
assert "provides this CLI" in diagnosis["suggestions"][0]["label"]
|
|
|
|
|
|
def test_diagnose_sglang_native_dependency_errors():
|
|
output = """
|
|
/tmp/cuda_utils.c:7:10: fatal error: Python.h: No such file or directory
|
|
ImportError:
|
|
[sgl_kernel] CRITICAL: Could not load any common_ops library!
|
|
Please ensure sgl_kernel is properly installed with:
|
|
pip install --upgrade sglang-kernel
|
|
Error details from previous import attempts:
|
|
- ImportError: libnuma.so.1: cannot open shared object file
|
|
"""
|
|
|
|
diagnosis = _diagnose_serve_output(output)
|
|
|
|
assert diagnosis is not None
|
|
assert "SGLang native kernel/runtime" in diagnosis["message"]
|
|
labels = [suggestion["label"] for suggestion in diagnosis["suggestions"]]
|
|
assert any("libnuma-dev" in label for label in labels)
|
|
assert any("python3.12-dev" in label for label in labels)
|
|
assert any("sglang-kernel" in label for label in labels)
|