Repository navigation
Native stores retain contributor authority per invocation - #865
Merged
Merged
Conversation
Observe the native response body before releasing marked frames and keep every contributing handle across buffered automatic work. Explicit actions retain observation without becoming automatic capture. Signed-off-by: zlareb1 <[email protected]>
A shared monotonic patch could expire a freshly loaded model-call policy before the bearer test reached its first request. Exercise the same attributed token rotation at two clock epochs without changing the policy clock. Signed-off-by: zlareb1 <[email protected]>
Keep constructor and callback contributors across client rebinding. Treat history reads and additions as automatic work while preserving observed explicit pop and clear operations. Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Signed-off-by: zlareb1 <[email protected]>
Keep the reviewed adapter and test source unchanged while using published session protection as the base. Signed-off-by: zlareb1 <[email protected]>
zlareb1
changed the base branch from
feat/native-history-session-protection
to
main
November 18, 2026 13:55
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related: #859
Changelog category (leave one):
Changelog entry (one or two sentences a user of Loom can read without the diff; the release pull request collects these into the release notes):
Native stores retain their contributing conversation protection across client rebinding. Existing automatic SDK contexts apply per invocation; direct calls and model-selected tools retain explicit behavior.
Why
A store can outlive the context that created it, and its Loom client can be rebound before a later batch. Observing only the current client loses earlier response contributors. The generic store protocol also serves explicit tools, so making every store call automatic would suppress legitimate selected operations.
Scope and risk
The LangGraph adapter retains constructor, ambient and callback contributors through the existing private helper. Each batch captures its entry contributors before consuming a lazy operation iterable. An existing automatic context selects automatic handling for that invocation; other calls retain observation only. Automatic classification does not latch for the store's lifetime.
Marked and malformed responses protect retained contributors before returning or refusing. Protected automatic invocations refuse before dispatch, including after a credential wait. Explicit calls remain usable on the same store after automatic work ends. Native namespaces, keys and user or thread ids select no protection authority.
Use one protected store per logical conversation family and reopen its existing application-owned capsule on restore. The sender inventory renews only this adapter's reviewed source hash; all six literal SDK call ASTs and all sender exception categories and reasons stay intact. No wire, backend, host binding or capability is added.
The native-history dependency is published. This four-path change targets main. Full CI passed on the final pushed head, and fresh independent whole-diff review found no findings or nits.
Compatibility, rollout and rollback
Tests
pytest -q -n0 tests/unit/test_sdk_langgraph_store.py -k "protection_store or test_put_get_delete_round_trip_with_tags_ttl_and_index_false or test_batch_executes_ops_in_order_and_aligns_results".AI assistance in the code (leave one; writing this description with AI is fine):
AI-generated: Codex wrote the change. Fresh independent whole-diff review found no findings or nits, and final-head CI passed.
I can explain every line of this diff and how it interacts with the rest of Loom.
Checklist