File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed
src/aleph/vm/orchestrator Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -178,6 +178,8 @@ async def check_payment(pool: VmPool):
178
178
# and forget the instance message. Compared to just stopping or decreasing the payment stream as the CRN don't know
179
179
# which VM it affects.
180
180
for vm_hash in list (pool .executions .keys ()):
181
+ if vm_hash == settings .FAKE_INSTANCE_ID :
182
+ continue
181
183
message_status = await get_message_status (vm_hash )
182
184
if message_status != MessageStatus .PROCESSED :
183
185
logger .debug (f"Stopping { vm_hash } execution due to { message_status } message status" )
@@ -188,11 +190,13 @@ async def check_payment(pool: VmPool):
188
190
for sender , chains in pool .get_executions_by_sender (payment_type = PaymentType .hold ).items ():
189
191
for chain , executions in chains .items ():
190
192
executions = [execution for execution in executions if execution .is_confidential ]
193
+ if not executions :
194
+ continue
191
195
balance = await fetch_balance_of_address (sender )
192
196
193
197
# Stop executions until the required balance is reached
194
198
required_balance = await compute_required_balance (executions )
195
- logger .debug (f"Required balance for Sender { sender } executions: { required_balance } " )
199
+ logger .debug (f"Required balance for Sender { sender } executions: { required_balance } , { executions } " )
196
200
# Stop executions until the required balance is reached
197
201
while executions and balance < (required_balance + settings .PAYMENT_BUFFER ):
198
202
last_execution = executions .pop (- 1 )
You can’t perform that action at this time.
0 commit comments