diff --git a/CHANGELOG.md b/CHANGELOG.md index ba9e925a9..1937d96cc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,18 @@ ## unreleased +- Support for bech32m has been added. bcoin can now validate and send BTC to +addresses for witness programs with versions > 0. The address indexer has +also been updated to retrieve the new addresses. A bug was fixed where the +indexer may return data for a witness version 0 address even if a version 1 +address was queried, if the two addresses had the same data (hash). After +upgrading bcoin, a full rescan may be necessary to re-index these collisions +correctly. To accomplish this: + - Stop bcoin (`bcoin-cli rpc stop` or `ctrl-C`) + - Delete the existing addr indexer data (`rm -rf ~/.bcoin/index/addr`) + - Restart bcoin + - The address indexer will automatically begin re-indexing the chain. It may take up to 24 hours. + - The logging module `blgr` has been updated. Log files will now be rolled over at around 20 MB and timestamped. Only the last 10 log files will be kept on disk and older log files will be purged. These values can be configured by passing diff --git a/test/indexer-test.js b/test/indexer-test.js index 2d2013790..2d5d62aea 100644 --- a/test/indexer-test.js +++ b/test/indexer-test.js @@ -58,6 +58,12 @@ const vectors = [ addr: '2Muy8nSQaMsMFAZwPyiXSEMTVFJv9iYuhwT', amount: 0.11, label: 'p2sh' + }, + // Same data part as version 0 p2wsh address but different witness version (1) + { + addr: 'bcrt1p2nj8e2nhmsa4hl9qw3xas7l5n2547h5uhlj47nc3pqfxaeq5rtjs0l3rl5', + amount: 0.22, + label: 'p2tr' } ]; @@ -1033,7 +1039,7 @@ describe('Indexer', function() { } } - await forValue(node.mempool.map, 'size', 20); + await forValue(node.mempool.map, 'size', 25); }); after(async () => {