1- use std:: {
2- collections:: { BTreeMap , HashMap } ,
3- fs:: remove_dir_all,
4- path:: PathBuf ,
5- } ;
1+ use std:: collections:: { BTreeMap , HashMap } ;
62
73use ethrex_common:: { Address , U256 } ;
84use ethrex_l2_common:: {
@@ -74,8 +70,6 @@ pub struct L1ProofSender {
7470 l1_chain_id : u64 ,
7571 network : Network ,
7672 fee_estimate : FeeEstimationType ,
77- /// Directory where checkpoints are stored.
78- checkpoints_dir : PathBuf ,
7973 aligned_mode : bool ,
8074}
8175
@@ -94,7 +88,6 @@ pub struct L1ProofSenderHealth {
9488}
9589
9690impl L1ProofSender {
97- #[ allow( clippy:: too_many_arguments) ]
9891 async fn new (
9992 cfg : & ProofCoordinatorConfig ,
10093 committer_cfg : & CommitterConfig ,
@@ -103,7 +96,6 @@ impl L1ProofSender {
10396 aligned_cfg : & AlignedConfig ,
10497 rollup_store : StoreRollup ,
10598 needed_proof_types : Vec < ProverType > ,
106- checkpoints_dir : PathBuf ,
10799 ) -> Result < Self , ProofSenderError > {
108100 let eth_client = EthClient :: new_with_config (
109101 eth_cfg. rpc_url . clone ( ) ,
@@ -130,7 +122,6 @@ impl L1ProofSender {
130122 l1_chain_id,
131123 network : aligned_cfg. network . clone ( ) ,
132124 fee_estimate,
133- checkpoints_dir,
134125 aligned_mode : aligned_cfg. aligned_mode ,
135126 } )
136127 }
@@ -140,7 +131,6 @@ impl L1ProofSender {
140131 sequencer_state : SequencerState ,
141132 rollup_store : StoreRollup ,
142133 needed_proof_types : Vec < ProverType > ,
143- checkpoints_dir : PathBuf ,
144134 ) -> Result < GenServerHandle < L1ProofSender > , ProofSenderError > {
145135 let state = Self :: new (
146136 & cfg. proof_coordinator ,
@@ -150,7 +140,6 @@ impl L1ProofSender {
150140 & cfg. aligned ,
151141 rollup_store,
152142 needed_proof_types,
153- checkpoints_dir,
154143 )
155144 . await ?;
156145 let mut l1_proof_sender = L1ProofSender :: start ( state) ;
@@ -203,16 +192,6 @@ impl L1ProofSender {
203192 self . rollup_store
204193 . set_latest_sent_batch_proof ( batch_to_send)
205194 . await ?;
206- let checkpoint_path = self
207- . checkpoints_dir
208- . join ( format ! ( "checkpoint_batch_{}" , batch_to_send - 1 ) ) ;
209- if checkpoint_path. exists ( ) {
210- let _ = remove_dir_all ( & checkpoint_path) . inspect_err ( |e| {
211- error ! (
212- "Failed to remove checkpoint directory at path {checkpoint_path:?}. Should be removed manually. Error: {}" , e. to_string( )
213- )
214- } ) ;
215- }
216195 } else {
217196 let missing_proof_types: Vec < String > = missing_proof_types
218197 . iter ( )
0 commit comments