MAINNET-DAY-0.md says:
What needs no proof at all: registering a viewing key, and shielding. Both are ordinary public transactions. A headless service can move value into the pool today with nothing but an RPC URL
I do not think that is right, and it is the kind of thing that costs a team a day.
apply_actions calls validate_proof unconditionally, before it does anything else:
fn apply_actions(
ref self: ContractState,
actions: Span<ServerAction>,
screening: Option<ScreeningAttestation>,
) {
self.reentrancy_guard.start();
self.pausable.assert_not_paused();
self.validate_proof(:actions);
...
and validate_proof starts with:
let mut proof_facts_span = execution_info.tx_info.proof_facts;
assert(!proof_facts_span.is_empty(), errors::EMPTY_PROOF_FACTS);
There is no branch on the action types. apply_actions is also the only non-admin write entrypoint on the contract, so as far as I can tell every state change needs a proof, registration and shielding included.
That matches what I observed building against the Sepolia pool: SetViewingKey and a shield both had to go through compile_actions, a prover, and then apply_actions with proof and proof_facts attached. Without them the submission does not get as far as reverting.
If there is a route I have missed I would like to know, since it would make the first mainnet transactions much cheaper to reach. But if the doc is out of date it is worth fixing: it currently tells teams they can write to the pool with only an RPC URL, and that is where the eligibility transactions have to happen.
MAINNET-DAY-0.mdsays:I do not think that is right, and it is the kind of thing that costs a team a day.
apply_actionscallsvalidate_proofunconditionally, before it does anything else:and
validate_proofstarts with:There is no branch on the action types.
apply_actionsis also the only non-admin write entrypoint on the contract, so as far as I can tell every state change needs a proof, registration and shielding included.That matches what I observed building against the Sepolia pool:
SetViewingKeyand a shield both had to go throughcompile_actions, a prover, and thenapply_actionswithproofandproof_factsattached. Without them the submission does not get as far as reverting.If there is a route I have missed I would like to know, since it would make the first mainnet transactions much cheaper to reach. But if the doc is out of date it is worth fixing: it currently tells teams they can write to the pool with only an RPC URL, and that is where the eligibility transactions have to happen.