Skip to content

Add Tempo session payments#181

Draft
parvahuja wants to merge 3 commits into
parv/agent-payment-runtimefrom
parv/tempo-sessions
Draft

Add Tempo session payments#181
parvahuja wants to merge 3 commits into
parv/agent-payment-runtimefrom
parv/tempo-sessions

Conversation

@parvahuja

@parvahuja parvahuja commented Jul 21, 2026

Copy link
Copy Markdown
Member

Summary

  • add the private-key TIP-1034 v2 client with a required raw-unit max_deposit and generic Store
  • persist and replay channel opens, top-ups, and vouchers; recover validated snapshots and on-chain state
  • handle sync and async HTTP/SSE controls on the exact request URI, including compressed streams
  • serialize channel updates, enforce deposit caps, accept scoped operators, and reuse one 2D nonce lane per channel
  • recover unknown sponsored opens/top-ups only from a finalized block hash with a fail-closed EIP-1898 state read
  • keep async channel-store state on the shared runtime loop and add built-wheel session API coverage

Private-key scope only: no access keys, WebSockets, close/server manager, or bootstrap preflight.

Stacked on #170. Depends on merged tempoxyz/pytempo#69 and its next PyPI release before merge.

Validation

  • full stacked Python 3.13 suite with exact pytempo ci: add CI Gate job for branch protection #69: 894 passed, 41 skipped
  • focused session/SSE suite: 33 passed
  • ruff check, ruff format --check, and pyright with zero errors
  • wheel and sdist builds plus strict twine checks
  • clean Python 3.12 pympp + pytempo wheel-to-wheel install and session construction smoke
  • independent correctness/concision review completed with no remaining findings

PyPI still serves pytempo 0.5.1, which lacks encode_for_signing(). After the #69 change is released, this PR must raise the pytempo minimum and rerun the package matrix. Protocol-shaped HTTP/SSE flows are covered locally; a live TIP-1034 server was not exercised. The PR remains draft.

@parvahuja
parvahuja force-pushed the parv/receipt-extensions branch 2 times, most recently from 36c2bf0 to 7c25cfb Compare July 21, 2026 16:35
@parvahuja
parvahuja force-pushed the parv/tempo-sessions branch 2 times, most recently from b4effc0 to 0e6e203 Compare July 21, 2026 21:17
@parvahuja
parvahuja changed the base branch from parv/receipt-extensions to parv/agent-payment-runtime July 21, 2026 21:18
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