The agent that grows with you
Python aiai-agentai-agentsanthropicchatgptclaudeclaude-codecodexhermeshermes-agentllmnous-researchopenai
test(e2e): read stored reasoning blocks under the stored session key
Brooklyn Nicholsonbcdffce5188a
diff --git a/tests/e2e/core/providers/test_chat_reasoning_variants.py b/tests/e2e/core/providers/test_chat_reasoning_variants.pyindex 0b1756cde00..effa2ffcaec 100644--- a/tests/e2e/core/providers/test_chat_reasoning_variants.py+++ b/tests/e2e/core/providers/test_chat_reasoning_variants.py@@ -130,7 +130,8 @@ def test_long_session_does_not_wedge_on_replayed_reasoning_budget(tmp_path) -> Nh.write(_impersonated_config("inference-api.nousresearch.com"), dotenv={"OPENAI_API_KEY": "sk-fake"})gw = TuiGateway(h, _proxy_env(srv))try:- sid = gw.call("session.create", {"cols": 120})["session_id"]+ created = gw.call("session.create", {"cols": 120})+ sid, stored_id = created["session_id"], created["stored_session_id"]for i in range(turns):answers.append(gw.turn(sid, f"question {i}"))finally:@@ -144,6 +145,7 @@ def test_long_session_does_not_wedge_on_replayed_reasoning_budget(tmp_path) -> Nassert leaked == [], f"reasoning_details sent to the Portal wire: {leaked}"missing = [i for i in range(turns) if f"ANSWER-{i}" not in answers[i]]assert not missing, f"turns {missing} were not answered: {answers}"- stored = [json.loads(r["reasoning_details"]) for r in db_messages(h, sid)+ # Rows persist under the STORED session key (the runtime id only routes RPCs).+ stored = [json.loads(r["reasoning_details"]) for r in db_messages(h, stored_id)if r["role"] == "assistant" and r["reasoning_details"]]assert stored == [_rd(str(i), "r" * 1000) for i in range(turns)], "state.db must keep the blocks for a switch back"