Skip to content

Send literal read calls as written, refuse bad values at preparation, commit run outcomes before answering - #6694

Merged
Sinity merged 1 commit into
integrate-20261101from
pl-remaining-failures
Nov 1, 2026
Merged

Sinity merged 1 commit into
integrate-20261101from
pl-remaining-failures

Conversation

@Sinity

@Sinity Sinity commented Nov 1, 2026

Copy link
Copy Markdown
Owner

What changed

  • CLI read sends a literal call exactly as written. Fix daemon and surface test failures at their owners #6688 made the page path rebuild the call from the parsed request so the CLI could state its print format; that also expanded a --request call with CLI defaults. The stream command handlers now receive how the call arrived (CallForm::Literal or CallForm::Flags). A literal call is sent unchanged; a call built from flags still states the format and delivery the client uses (docs/interfaces.md, "Ready calls are complete requests"). Fixes cli::tests::literal_read_envelope_is_not_expanded_with_cli_defaults.
  • Query preparation refuses values a numeric field cannot take. sessions where cost > nonsense prepared successfully and failed only at SQL compilation, so a historical saved definition with that text got a semantic identity. Preparation now checks each value compared with a catalog number, amount or duration field, using the bound query's typed operands. The value rule moved to its owner, polylogue-query (fields::Kind::scalar, time::money_nusd), and store compilation uses the same rule; the store's copy of money_nusd is now a re-export. Fixes composition::saved_relation_errors_reach_the_query_error_path.
  • A run's outcome is committed before its answer returns. execution::record sent the outcome to the writer and dropped the receipt without waiting, so a read right after the answer could find the run (begin is synchronous) without its outcome. The answer cites run:<id>, so the record now waits for the outcome receipt. This adds one writer round trip per execution; begin already costs one. Fixes object::tests::actual_no_effect_request_read_records_one_object_run_and_roundtrips_through_directory_import.

Deleted: the store's own money_nusd body and the duplicate scalar parsing in conditions.rs.

MCP timeout

mcp::tests::generated_ready_mcp_call_executes_its_exact_typed_envelope passes alone in 0.67 s (job 300). I did not find what made it take more than 90 s under load, so that part is not fixed. The waits in that path that have no deadline are TestDaemon::wait_for (it polls until status is idle), the Deadline::None client call, and the writer round trip on begin.

Verification

  • compile -p polylogue -p polylogue-store -p polylogue-query --tests: job 296 passed.
  • focused, the four target tests: job 300, 4/4 passed.
  • focused -p polylogue -p polylogue-store: job 305 (results in a comment).

🤖 Generated with Claude Code

https://claude.ai/code/session_01AcQETkbTfFMr1hgNJ8A3em

… commit run outcomes before answering

- CLI read: a call given with --request goes to the daemon exactly as
  written; only a call built from flags states the format and delivery the
  client prints (docs/interfaces.md, "Ready calls are complete requests").
  The stream command handlers receive how the call arrived (CallForm).
- Query preparation checks each value compared with a number, amount or
  duration field against that field's kind, so `cost > nonsense` is refused
  before the question gets an identity. The value rule (Kind::scalar and
  money_nusd) moves to polylogue-query; store compilation uses the same rule.
- Execution records wait for the run outcome to commit before the answer
  returns, so a caller reading the cited run sees how it ended. The outcome
  was sent to the writer and never awaited, so a read right after the
  answer could find the run without its outcome.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01AcQETkbTfFMr1hgNJ8A3em
@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
🔒 Security Review ⚠️ Failed 2026-11-01T12:44:08.504497Z
We couldn’t complete this review. Comment @codex security review to try again.
ebb4f3e PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

The account paying for this security review has reached its Codex usage limits. The payer can check the Codex usage dashboard. For personal accounts, using credits requires enabling “Use credits for security reviews” in Code review settings. If you do not manage the paying account, contact this repository's admins.

@Sinity

Sinity commented Nov 1, 2026

Copy link
Copy Markdown
Owner Author

Focused -p polylogue -p polylogue-store, job 324: 1431 tests, 1401 passed, 30 failed, 9 skipped. Job 305 hit the 30-minute job timeout and did not finish. 28 of the 30 failures are already in the baselines. The other two passed when run alone in job 332:

  • mcp::completion::tests::completion_route_uses_full_query_cursor_and_preserves_the_suffix: two completion answers carry "values as of " timestamps 31 ms apart. This test depends on the wall clock and does not touch this change.
  • e2e cli::attachments::unicode_attachment_pages_check_the_descriptor_and_refuse_a_changed_file: a CLI read page hit its default deadline after 36 s under load; it took 18 s alone. This change adds a writer round trip to each recorded read, so it may have made this test more sensitive to a busy writer. That is not confirmed.

@Sinity
Sinity merged commit 93aa5f3 into integrate-20261101 Nov 1, 2026
@Sinity
Sinity deleted the pl-remaining-failures branch November 1, 2026 13:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant