Repository navigation
Conversation
Needs @_linked/server-utils 1.18 (the delegated call context). The lockfile is refreshed once that version is published. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01BcfKmNq1KK5uCkbJAKTEmQ
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.
Draft: depends on linked-fw/server-utils#125 (the delegated call context,
@_linked/server-utils1.18). The range here reads^1.18.0; the lockfile is refreshed once that release exists, so CI fails until then.What
transactionCaller()binds a store transaction started in a delegated call (runAsDelegate) to the user the delegate acts for —user:<id>, the same identity as that user's own request — instead ofsystem. A delegated account without an id is refused (401), as an HTTP call without a session is.RemoteDataset's user token (a delegated call has a user but no session token, so none is sent).Why
Bound to
system, a delegated caller's transaction could be continued by any system work. Bound to its user, it behaves exactly like that user's own.Tests
src/tests/transaction-caller.test.ts: http with and without a session; delegated →user:<id>and equal to the user's own request; delegated without an id → 401;systemand outside any call →system(control).npm test: 553 pass (run against the server-utils branch linked locally).🤖 Generated with Claude Code
https://claude.ai/code/session_01BcfKmNq1KK5uCkbJAKTEmQ