Repository navigation
ci: run the OpenRouter live tests with the testing key only - #605
Conversation
The manual live-model job passed the production OpenRouter key. It now passes OPENROUTER_API_KEY_FOR_TESTING, and test_llm.py reads only that key, so no live test can spend the production credit. The job starts with a presence check. It names each live key that is missing, and it fails when ANTHROPIC_BASE_URL is set without ANTHROPIC_WORKSPACE_ID. Entering openrouter as the model input limits a manual run to the OpenRouter route. Claude-Session: https://claude.ai/code/session_01QGLYRKyTuTjzGbVydofSCC Co-Authored-By: Claude <[email protected]>
|
Integration Tests failed on the manual run (run 37832679262,
Why this is not this PR's failure: this PR does not touch Base status: on No fix exists yet. Proposed patch, not included in this PR: add a helper that returns the reply text whether Generated by Claude Code |
The two live caching tests read response.content as a string. On the OpenRouter route the reply arrived as a block list in CI, so the assertion raised AttributeError. extract_text returns the answer text and drops reasoning blocks, so the tests still check what the model said. Claude-Session: https://claude.ai/code/session_01QGLYRKyTuTjzGbVydofSCC Co-Authored-By: Claude <[email protected]>
|
Fixed in 127a641. On this route the reply arrives as a list of content blocks, so the two live caching tests now read the answer text with The manual OpenRouter run is 37834516978. Its live model step passes: 16 passed, 0 failed. The same job's network step reports two failures in Generated by Claude Code |
The integration-tests job runs by hand only since #605. Its credential step warned about a missing key but passed, and each test module skips itself without its key, so a run with no key set was green with every live test skipped. It now fails in that case. The rules files and the notebook-site-check comment still described the job as running after a merge and skipping gracefully; they now say it is started by hand and fails without a credential. Co-Authored-By: Claude Sonnet 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_019MtQNfPzMpGxEJFUciXbTN
Retitles [Unreleased] to [0.8.18], as for earlier releases. Adds the entries that were missing for #599 (hed-suggest in the image), #600 (HED prompt), #601 (widget host styles) and #605 (live tests by hand), and one for the DEFAULT_MODEL check at startup. Names the three classes that are accepted (the other five are refused), and fixes a reference that pointed the wrong way. Co-Authored-By: Claude Sonnet 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_019MtQNfPzMpGxEJFUciXbTN
Summary
OPENROUTER_API_KEY_FOR_TESTINGinstead of the productionOPENROUTER_API_KEY. A manual run can no longer spend the production OpenRouter credit.tests/test_integration/test_llm.pyreads onlyOPENROUTER_API_KEY_FOR_TESTING. It used to accept the production key too.ANTHROPIC_BASE_URLis set withoutANTHROPIC_WORKSPACE_ID, which would otherwise stop the whole run at startup.openrouterruns only the OpenRouter-route tests.tests/test_core/test_litellm_llm.pyread the answer text withextract_text. On this route the reply arrives as a list of content blocks, which made the old.lower()assertion fail.Testing
ruff checkandruff format --checkpass on the changed test files.openrouteras the model input. The live model step reports 16 passed, 0 failed.Before merging
OPENROUTER_API_KEY_FOR_TESTINGmust exist under that exact name. The presence check in run 37834516978 printed it as set.