Skip to content

Commit

Permalink
fix bootstrap cleaning
Browse files Browse the repository at this point in the history
  • Loading branch information
Ouziel committed Jan 10, 2025
1 parent 2674038 commit 0670fe0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
8 changes: 5 additions & 3 deletions counterparty-core/counterpartycore/lib/bootstrap.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,9 +114,11 @@ def clean_data_dir(data_dir):
if not os.path.exists(data_dir):
os.makedirs(data_dir, mode=0o755)
return
files_to_delete = glob.glob(os.path.join(data_dir, "*.db"))
files_to_delete += glob.glob(os.path.join(data_dir, "*.db-wal"))
files_to_delete += glob.glob(os.path.join(data_dir, "*.db-shm"))
network = "" if config.NETWORK_NAME == "mainnet" else f".{config.NETWORK_NAME}"
files_to_delete = []
for db_name in ["counterparty", "state"]:
for ext in ["db", "db-wal", "db-shm"]:
files_to_delete += glob.glob(os.path.join(data_dir, f"{db_name}{network}.{ext}"))
for file in files_to_delete:
os.remove(file)

Expand Down
2 changes: 1 addition & 1 deletion release-notes/release-notes-v10.9.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ The following transaction construction parameters have been deprecated (but rema
- Fix the `dispensers` table in State DB: include dispensers with same the `source` and `asset` but a different `tx_hash`
- Fix endpoint to get info from raw transaction when block index is not provided
- Fix issue where composed transactions contained `script_pubkey` (lock script) where the `script_sig` (unlock script) should be
- Fix bootstrap when using `--bootstrap-url` flag
- Fix bootstrap when using `--bootstrap-url` flag and don't clean other networks files
- Fix logic for blockchain reorgs of several blocks
- Have the node terminate when the `follow` loop raises an error
- Don't stop the server on "No such mempool or blockchain" error
Expand Down

0 comments on commit 0670fe0

Please sign in to comment.