chore: remove configuration files and enhance blockchain explorer with advanced search, analytics, and export features
- Delete .aitbc.yaml.example CLI configuration template - Delete .lycheeignore link checker exclusion rules - Delete .nvmrc Node.js version specification - Add advanced search panel with filters for address, amount range, transaction type, time range, and validator - Add analytics dashboard with transaction volume, active addresses, and block time metrics - Add Chart.js integration
This commit is contained in:
17
dev/scripts/patch_mempool5.py
Normal file
17
dev/scripts/patch_mempool5.py
Normal file
@@ -0,0 +1,17 @@
|
||||
with open("/home/oib/windsurf/aitbc/apps/blockchain-node/src/aitbc_chain/rpc/router.py", "r") as f:
|
||||
content = f.read()
|
||||
|
||||
# Fix DatabaseMempool.add() call in router.py - the problem was `mempool.add(tx_dict, chain_id)` which is 3 positional arguments (self, tx, chain_id).
|
||||
# Wait, `def add(self, tx: Dict[str, Any], chain_id: str = "ait-devnet") -> str:`
|
||||
# `mempool.add(tx_dict, chain_id)` shouldn't raise "takes 2 positional arguments but 3 were given" unless `get_mempool()` is returning `InMemoryMempool` instead of `DatabaseMempool`.
|
||||
|
||||
# Let's check init_mempool in main.py, it uses MEMPOOL_BACKEND from config.
|
||||
# If MEMPOOL_BACKEND="database" then it should be DatabaseMempool.
|
||||
|
||||
content = content.replace(
|
||||
"tx_hash = mempool.add(tx_dict, chain_id)",
|
||||
"tx_hash = mempool.add(tx_dict, chain_id=chain_id)" # try keyword
|
||||
)
|
||||
|
||||
with open("/home/oib/windsurf/aitbc/apps/blockchain-node/src/aitbc_chain/rpc/router.py", "w") as f:
|
||||
f.write(content)
|
||||
Reference in New Issue
Block a user