@@ -376,6 +376,8 @@ pub fn update_storage_and_augment_bitcoin_block_with_inscription_reveal_data(
376
376
return ;
377
377
}
378
378
} ;
379
+ let mut sats_overflow = vec ! [ ] ;
380
+
379
381
for new_tx in block. transactions . iter_mut ( ) . skip ( 1 ) {
380
382
let mut ordinals_events_indexes_to_discard = VecDeque :: new ( ) ;
381
383
// Have a new inscription been revealed, if so, are looking at a re-inscription
@@ -428,7 +430,9 @@ pub fn update_storage_and_augment_bitcoin_block_with_inscription_reveal_data(
428
430
} else {
429
431
// If the satoshi inscribed correspond to a sat overflow, we will store the inscription
430
432
// but exclude it from the block data
433
+ sats_overflow. push ( inscription. clone ( ) ) ;
431
434
ordinals_events_indexes_to_discard. push_front ( ordinal_event_index) ;
435
+ continue ;
432
436
}
433
437
latest_inscription_number += 1 ;
434
438
inscription. inscription_number = inscription_number;
@@ -472,6 +476,33 @@ pub fn update_storage_and_augment_bitcoin_block_with_inscription_reveal_data(
472
476
new_tx. metadata . ordinal_operations . remove ( index) ;
473
477
}
474
478
}
479
+
480
+ for inscription in sats_overflow. iter_mut ( ) {
481
+ match storage {
482
+ Storage :: Sqlite ( rw_hord_db_conn) => {
483
+ latest_inscription_number += 1 ;
484
+ inscription. inscription_number = latest_inscription_number;
485
+ ctx. try_log ( |logger| {
486
+ slog:: info!(
487
+ logger,
488
+ "Inscription {} (#{}) detected on Satoshi overflow {} (block {}, {} transfers)" ,
489
+ inscription. inscription_id,
490
+ inscription. inscription_number,
491
+ inscription. ordinal_number,
492
+ block. block_identifier. index,
493
+ inscription. transfers_pre_inscription,
494
+ ) ;
495
+ } ) ;
496
+ store_new_inscription (
497
+ & inscription,
498
+ & block. block_identifier ,
499
+ & rw_hord_db_conn,
500
+ & ctx,
501
+ ) ;
502
+ }
503
+ _ => { }
504
+ }
505
+ }
475
506
}
476
507
477
508
/// For each input of each transaction in the block, we retrieve the UTXO spent (outpoint_pre_transfer)
0 commit comments