This repository was archived by the owner on Sep 8, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +10
-4
lines changed Expand file tree Collapse file tree 1 file changed +10
-4
lines changed Original file line number Diff line number Diff line change @@ -163,10 +163,15 @@ def __call__(self, computation: ComputationAPI) -> None:
163163 computation .stack_push_int (0 )
164164 computation .return_data = b''
165165 if insufficient_funds :
166- err_msg = f"Insufficient Funds: { storage_address_balance } < { stack_data .endowment } "
166+ self .logger .debug2 (
167+ "%s failure: %s" ,
168+ self .mnemonic ,
169+ f"Insufficient Funds: { storage_address_balance } < { stack_data .endowment } "
170+ )
167171 elif stack_too_deep :
168- err_msg = "Stack limit reached"
169- self .logger .debug2 ("%s failure: %s" , self .mnemonic , err_msg ,)
172+ self .logger .debug2 ("%s failure: %s" , self .mnemonic , "Stack limit reached" )
173+ else :
174+ raise RuntimeError ("Invariant: error must be insufficient funds or stack too deep" )
170175 return
171176
172177 call_data = computation .memory_read_bytes (
@@ -183,11 +188,12 @@ def __call__(self, computation: ComputationAPI) -> None:
183188 is_collision = computation .state .has_code_or_nonce (contract_address )
184189
185190 if is_collision :
191+ computation .stack_push_int (0 )
192+ computation .return_data = b''
186193 self .logger .debug2 (
187194 "Address collision while creating contract: %s" ,
188195 encode_hex (contract_address ),
189196 )
190- computation .stack_push_int (0 )
191197 return
192198
193199 child_msg = computation .prepare_child_message (
You can’t perform that action at this time.
0 commit comments