Skip to content

fix Alice/bob signed context for clear3()#458

Open
rouzwelt wants to merge 7 commits into
masterfrom
2026-07-07-fix-clear-signed-context
Open

fix Alice/bob signed context for clear3()#458
rouzwelt wants to merge 7 commits into
masterfrom
2026-07-07-fix-clear-signed-context

Conversation

@rouzwelt

@rouzwelt rouzwelt commented Jul 7, 2026

Copy link
Copy Markdown
Collaborator

Motivation

Solution

Checks

By submitting this for review, I'm confirming I've done the following:

  • made this PR as small as possible
  • unit-tested any new functionality
  • linked any relevant issues or PRs
  • included screenshots (if this involves a front-end change)

Summary by CodeRabbit

  • Bug Fixes
    • Corrected the order of signed order data used during orderbook simulation, so “clear” calls now match the expected input format.
    • Updated test expectations to reflect the corrected argument order.
  • Chores
    • Reformatted the Nix flake configuration without functional changes.

@rouzwelt rouzwelt self-assigned this Jul 7, 2026
@coderabbitai

coderabbitai Bot commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Walkthrough

Reorders signedContext arguments in V6 and V5 clear calldata construction, updates the matching test expectation, and reformats the Nix flake outputs block without changing its logic.

Changes

SignedContext Ordering Fix

Layer / File(s) Summary
Reorder clear calldata arguments
src/core/modes/intra/simulation.ts
Both order calldata builders now pass the counterparty’s signedContext before the order’s own signedContext.
Update test expectation
src/core/modes/intra/simulation.test.ts
The expected clear3 arguments now reflect the reordered signedContext values.

Nix Flake Formatting

Layer / File(s) Summary
Reformat flake outputs
flake.nix
Reformats the outputs attribute set and related indentation without changing inputs or logic.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly matches the main change: fixing Alice/bob signed context order for clear3().
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch 2026-07-07-fix-clear-signed-context

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@rouzwelt
rouzwelt changed the base branch from master to 2026-07-20-improve-performance-zero-out-pairs July 20, 2026 22:07
@rouzwelt
rouzwelt changed the base branch from 2026-07-20-improve-performance-zero-out-pairs to master July 20, 2026 22:08
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.

2 participants