Skip to content

Commit d87c16d

Browse files
committed
remaining couple
1 parent 527cdc3 commit d87c16d

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

chia/_tests/blockchain/test_blockchain_transactions.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ async def test_basic_blockchain_tx(
9292
for coin in added_coins:
9393
unspent = await full_node_1.coin_store.get_coin_record(coin.name())
9494
assert unspent is not None
95-
assert not unspent.spent()
95+
assert not unspent.spent
9696
assert not unspent.coinbase
9797

9898
@pytest.mark.anyio

chia/consensus/block_body_validation.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -463,7 +463,7 @@ async def validate_block_body(
463463
False,
464464
block.foliage_transaction_block.timestamp,
465465
)
466-
removal_coin_records[new_unspent.name()] = new_unspent
466+
removal_coin_records[new_unspent.name] = new_unspent
467467
else:
468468
# This check applies to both coins created before fork (pulled from coin_store),
469469
# and coins created after fork (additions_since_fork)
@@ -485,17 +485,17 @@ async def validate_block_body(
485485
if unspent.spent == 1 and unspent.spent_block_index <= fork_info.fork_height:
486486
# Check for coins spent in an ancestor block
487487
return Err.DOUBLE_SPEND
488-
removal_coin_records[unspent.name()] = unspent
488+
removal_coin_records[unspent.name] = unspent
489489
else:
490-
look_in_fork.append(unspent.name())
490+
look_in_fork.append(unspent.name)
491491

492492
if log_coins and len(look_in_fork) > 0:
493493
log.info("%d coins spent after fork", len(look_in_fork))
494494

495495
if len(unspent_records) != len(removals_from_db):
496496
# some coins could not be found in the DB. We need to find out which
497497
# ones and look for them in additions_since_fork
498-
found: set[bytes32] = {u.name() for u in unspent_records}
498+
found: set[bytes32] = {u.name for u in unspent_records}
499499
for rem in removals_from_db:
500500
if rem in found:
501501
continue
@@ -553,7 +553,7 @@ async def validate_block_body(
553553

554554
# 20. Verify that removed coin puzzle_hashes match with calculated puzzle_hashes
555555
for unspent in removal_coin_records.values():
556-
if unspent.coin.puzzle_hash != removals_puzzle_dic[unspent.name()]:
556+
if unspent.coin.puzzle_hash != removals_puzzle_dic[unspent.name]:
557557
return Err.WRONG_PUZZLE_HASH
558558

559559
# 21. Verify conditions

0 commit comments

Comments
 (0)