Skip to content

fix(sdk): pass rentPayer through rpc.proposalCreate - #208

Open
Blockchains wants to merge 1 commit into
Squads-Protocol:mainfrom
Blockchains:fix/proposal-create-rent-payer
Open

Blockchains wants to merge 1 commit into
Squads-Protocol:mainfrom
Blockchains:fix/proposal-create-rent-payer

Conversation

@Blockchains

Copy link
Copy Markdown

Problem

rpc.proposalCreate accepts a rentPayer signer but never passes it to transactions.proposalCreate, so the instruction falls back to rentPayer: creator. Passing a rentPayer therefore fails before sending:

Error: Cannot sign with non signer key <rentPayer>
    at VersionedTransaction.sign
    at proposalCreate (sdk/multisig/src/rpc/proposalCreate.ts)

The signer is pushed into allSigners, but its key is not in the compiled message. The transactions and instructions layers already support rentPayer, and rpc.batchCreate / rpc.batchAddTransaction already forward it with rentPayer?.publicKey.

Change

Forward rentPayer: rentPayer?.publicKey from rpc.proposalCreate to transactions.proposalCreate. Without a rentPayer the behaviour is unchanged (the creator pays).

Tests

Added proposal_create › rent payer pays for the proposal account to tests/suites/multisig-sdk.ts: a funded non-member pays the proposal rent, the proposal account holds exactly that amount, and the creator's balance is unchanged.

  • Before the change the new test fails with Cannot sign with non signer key; after it, it passes.
  • Full suite (npx mocha … tests/index.ts) against solana-test-validator with the --features testing build: 161 passing, 12 pending, 3 failing. The 3 failures are the missing signature cases in multisig_create, multisig_create_v2 and multisig_add_member; they fail on the unmodified code too, because the local validator (Agave 4.1.2, newer than the 2.2.0 in Anchor.toml) reports Transaction did not pass signature verification instead of the expected Transaction signature verification failure.
  • Also checked on devnet against a separately deployed copy of the program: the proposal rent (1,493,520 lamports) came from the rent payer and the creator's balance did not change.

No program or account-layout change.

Disclosure: prepared with AI coding assistance; reviewed and tested as described above. Review replies will come from a person.

@vercel

vercel Bot commented Nov 22, 2026

Copy link
Copy Markdown

@Blockchains is attempting to deploy a commit to the squads Team on Vercel.

A member of the Team first needs to authorize it.

This branch has not been deployed

No deployments
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