Skip to content

docs: clarify SafeMultiChainSigAccountV1 works as a single-chain account - #228

Merged
sherifahmed990 merged 3 commits into
devfrom
docs/multichain-account-single-chain-jsdoc
Jul 28, 2026
Merged

docs: clarify SafeMultiChainSigAccountV1 works as a single-chain account#228
sherifahmed990 merged 3 commits into
devfrom
docs/multichain-account-single-chain-jsdoc

Conversation

@Sednaoui

@Sednaoui Sednaoui commented Jul 28, 2026

Copy link
Copy Markdown
Member

Summary by CodeRabbit

  • Documentation
    • Clarified single-chain and multi-chain signing behavior for EntryPoint v0.9.
    • Documented automatic multi-chain signature encoding and single-operation signing details.
    • Added guidance for bundling multiple operations.
    • Clarified derived addresses and deployment or migration requirements for existing deployments.

The class doc opened with "Safe account variant that supports multi-chain
signatures via Merkle trees" and never mentioned single-chain use, and both
single-op signing methods were documented as signing "for multi-chain".
Read cold, that says a normal single-chain signature is not available from
this class.

It is: the single-op path signs the leaf SafeOp hash directly rather than a
Merkle root, and the multi-chain flag only selects the signature encoding.
An integrator evaluating EntryPoint v0.9 concluded from these comments that
adopting this class meant "different signature machinery, a separate
integration" rather than selecting a different account class.

Lead with the single-chain case, state the API compatibility with
SafeAccountV0_3_0 explicitly, note that the multi-op methods are additive,
and flag the one thing that does change — the derived account address.
No behaviour change.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@coderabbitai

coderabbitai Bot commented Jul 28, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

You’ve reached a temporary PR review limit under our Fair Usage Limits Policy.

Your recent review volume is higher than typical usage, so adaptive limits are currently applied.

Next review available in: 12 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 7430edc7-8d6e-487d-8c38-2a2b7a57da19

📥 Commits

Reviewing files that changed from the base of the PR and between bdd76de and 24724b8.

📒 Files selected for processing (1)
  • src/account/Safe/SafeMultiChainSigAccount.ts
📝 Walkthrough

Walkthrough

Updated SafeMultiChainSigAccountV1 documentation to clarify single-chain compatibility, multi-chain helpers, v0.9 deployment requirements, and single- versus multi-operation signing semantics. No runtime behavior or public declarations changed.

Changes

Safe multi-chain signing documentation

Layer / File(s) Summary
Account and signing method documentation
src/account/Safe/SafeMultiChainSigAccount.ts
Documents account compatibility and migration requirements, then clarifies automatic multi-chain encoding, leaf SafeOp hash validation, and multi-operation signing references.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Possibly related PRs

Suggested reviewers: sherifahmed990

Poem

I’m a bunny with docs in my paws,
Clarifying signatures and hashing laws.
Leaf hashes guide the way,
While multi-chain helpers play.
Clearer signing, hop by hop! 🐇

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning No pull request description was provided, so the required Summary, Test, and Risk/Compatibility sections are missing. Add the template sections for Summary, Test, and Risk/Compatibility, and briefly describe the doc changes and any validation performed.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title is clear and matches the main change: documentation clarifying single-chain behavior for SafeMultiChainSigAccountV1.
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.

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

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 69fd3ad0fd

ℹ️ 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".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +51 to +52
* class instead of `SafeAccountV0_3_0` targets EntryPoint v0.9 — it is not a
* separate integration. The multi-op methods ({@link signUserOperations},

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Require migration before switching deployed accounts

For an already-deployed Safe used through SafeAccountV0_3_0, selecting this class at the same account address is not sufficient: the v0.9 module must first be enabled and installed as the fallback handler. The migration helper in SafeAccountV0_3_0.ts explicitly requires sending its disable/enable/set-fallback batch through the old v0.7 account, so describing this as merely selecting a class can lead users to submit operations against a module their Safe has not enabled.

Useful? React with 👍 / 👎.

@Sednaoui
Sednaoui requested a review from sherifahmed990 July 28, 2026 07:36
Sednaoui and others added 2 commits July 28, 2026 09:41
The previous wording covered only counterfactual addresses, so "selecting
this class targets EntryPoint v0.9" could be read as sufficient for an
already-deployed Safe. It is not: a Safe deployed through
SafeAccountV0_3_0 has neither the v0.9 module enabled nor installed as its
fallback handler, and UserOperations sent before the migration batch lands
will fail.

Separate API compatibility (real) from account interchangeability (not
real), and point at
createMigrateToSafeMultiChainSigAccountV1MetaTransactions, noting its batch
must be sent from the v0.7 account itself. Also qualify the constructor
doc, whose "existing or new account" is where this mistake would be made.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Enabling the v0.9 module and repointing the Safe's fallback handler are two
distinct configuration changes; the wording ran them together. Also note
that a deployed Safe keeps its address across the migration — the differing
address applies to counterfactual derivation for new accounts only.

Mirrors candidelabs/developer-docs#83.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

@sherifahmed990 sherifahmed990 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@sherifahmed990
sherifahmed990 merged commit 4a5306c into dev Jul 28, 2026
3 checks passed
@sherifahmed990
sherifahmed990 deleted the docs/multichain-account-single-chain-jsdoc branch July 28, 2026 16: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