Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: finalizationPeriod #266

Merged
merged 2 commits into from
Dec 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion book/contracts/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ You can configure additional parameters when deploying or upgrading the `OPSucci
| `VERIFIER_ADDRESS` | Default: Succinct's official Groth16 VerifierGateway. Address of the `ISP1Verifier` contract used to verify proofs. For mock proofs, this is the address of the `SP1MockVerifier` contract. |
| `STARTING_BLOCK_NUMBER` | Default: The finalized block number on L2. The block number to initialize the contract from. OP Succinct will start proving state roots from this block number. |
| `SUBMISSION_INTERVAL` | Default: `1000`. The minimum interval in L2 blocks at which checkpoints must be submitted. An aggregation proof can be posted for any range larger than this interval. |
| `FINALIZATION_PERIOD` | Default: `0`. The time period (in seconds) after which a proposed output becomes finalized and withdrawals can be processed. |
| `FINALIZATION_PERIOD_SECS` | Default: `3600` (1 hour). The time period (in seconds) after which a proposed output becomes finalized and withdrawals can be processed. |
| `PROPOSER` | Default: The address of the account associated with `PRIVATE_KEY`. An Ethereum address authorized to submit proofs. Set to `address(0)` to allow permissionless submissions. **Note: Use `addProposer` and `removeProposer` functions to update the list of approved proposers.** |
| `CHALLENGER` | Default: `address(0)`, no one can dispute proofs. Ethereum address authorized to dispute proofs. |
| `OWNER` | Default: The address of the account associated with `PRIVATE_KEY`. Ethereum address authorized to update the `aggregationVkey`, `rangeVkeyCommitment`, `verifier`, and `rollupConfigHash` parameters. Can also transfer ownership of the contract and update the approved proposers. In a production setting, set to the governance smart contract or multi-sig of the chain. |
7 changes: 5 additions & 2 deletions scripts/utils/bin/fetch_rollup_config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -95,9 +95,12 @@ async fn update_l2oo_config() -> Result<()> {
.map(|p| p.parse().unwrap())
.unwrap_or(1000);

let finalization_period = env::var("FINALIZATION_PERIOD")
// Default finalization period of 1 hour. Gives the challenger enough time to dispute the output.
// Docs: https://docs.optimism.io/builders/chain-operators/configuration/rollup#finalizationperiodseconds
const DEFAULT_FINALIZATION_PERIOD_SECS: u64 = 60 * 60;
let finalization_period = env::var("FINALIZATION_PERIOD_SECS")
.map(|p| p.parse().unwrap())
.unwrap_or(0);
.unwrap_or(DEFAULT_FINALIZATION_PERIOD_SECS);

let private_key = env::var("PRIVATE_KEY").unwrap_or_else(|_| B256::ZERO.to_string());
let (proposer, owner) = if private_key == B256::ZERO.to_string() {
Expand Down
Loading