Releases: CounterpartyXCP/counterparty-core
v10.4.6
Release Notes - Counterparty Core v10.4.6 (2024-10-17)
This is a Hotfix release to address the slowness of block parsing.
Upgrading
ChangeLog
Bugfixes
Codebase
- Use of RAM cache to verify balances attached to a UTXO
API
CLI
Credits
- Ouziel Slama
- Warren Puffett
- Adam Krellenstein
v10.4.5
Release Notes - Counterparty Core v10.4.5 (2024-10-16)
This is a minor release with a number of bugfixes and minor improvements to the API.
Upgrading
This release is not a protocol change and does not require a database reparse. However a minor bug in the reorg-handling logic was detected and fixed. If your node hashes for block 865699 were not equal to L: 6d64717, TX: f71fa92, M: 8734a58, then you should either rollback to 865690 or restart with the latest bootstrap file. This bug is not believed to have affected node consensus.
ChangeLog
Bugfixes
- Fix
TypeError
inis_server_ready()
function - Handle
AddressError
in API calls - Fix RSFetcher pre-fetcher queue
- Fix RSFetcher blockchain reorganization management
Codebase
- Retry when Bitcon Core returns a 503 error
API
- Use UTXOs locks when
unspents_set
is used (formerlycustom_inputs
) - Tweak and fix
asset_events
field (new eventstransfer
andchange_description
;reissuance
only ifquantity
greater than 0;lock
also when locked with thelock
argument) - Add Waitress WSGI server support and make it the default
- Fix missing parentheses in SQL queries
- Fix
dispenser.close_block_index
type in API database - Set CORS in pre-flight requests
CLI
Credits
- Ouziel Slama
- Warren Puffett
- Adam Krellenstein
v10.4.4
Release Notes - Counterparty Core v10.4.4 (2024-10-09)
This is a minor release with a number of bugfixes and minor improvements to the API.
Upgrading
This release is not a protocol change and does not require a database reparse.
ChangeLog
Bugfixes
- Handle invalid scripts in outputs properly
- Fix
last_block
inget_running_info
command (API v1) - Fix blockchain reorganization support
Codebase
- Add
regtest
support in RSFetcher
API
- Add Gunicorn support
CLI
- Add
wsgi-server
(werkzeug
orgunicorn
) andgunicorn-workers
flags - Enable Sentry Caches and Queries pages
Credits
- Ouziel Slama
- Warren Puffett
- Adam Krellenstein
v10.4.3
Release Notes - Counterparty Core v10.4.3 (2024-10-05)
This is a minor release with a number of bugfixes and minor improvements to the API.
Upgrading
This release is not a protocol change and does not require a database reparse.
ChangeLog
Bugfixes
- Fix
asset_events
during an asset ownership transfer - Refresh XCP supply in API DB on startup
- Clean mempool after each block when catching up
- Tweak mempool cleaning in API Watcher
- Fix
AttributeError
onget_transactions
(API v1) - Catch
BadRequest
error (API v2) - Fix off-by-one error in RSFetcher reorg logic
Codebase
- Add
regtest
andmainnet
test for thehealthz
endpoint - Re-enable
check.asset_conservation()
and run it in the background, in a separate thread, both at startup and every 12 hours
API
- Use the GitHub repository for the Blueprint URL
- Add the
/v2/routes
route in the/v2/
result - Add the
addresses
argument to the/v2/mempool/events
route - Support prefixed data for
/v2/transactions/unpack
- Return assets issued and owned by
<address>
in/v2/addresses/<address>/assets
- Add the following routes:
/v2/addresses/<address>/assets/issued
/v2/addresses/<address>/assets/owned
CLI
Credits
- Ouziel Slama
- Warren Puffett
- Adam Krellenstein
v10.4.2
Release Notes - Counterparty Core v10.4.2 (2024-10-02)
This is a small but important release which includes fixes for a number of node stability issues and updates to the API. All node hosts should upgrade as soon as possible.
Upgrading
This release is not a protocol change and does not require any reparsing. A regression in the v1 API has been resolved.
ChangeLog
Protocol Changes
Bugfixes
- Retry indefinitely when RSFetcher cannot connect to Bitcoin Core
- Fix RSFetcher startup logic
- Restart RSFetcher when it is found to have been stopped
- Fix JSON serialization of
bytes
in API v1
Codebase
- Fix Docker Compose test
- Fetch old mempool entries from Bitcoin Core after node startup
API
- Disable expiration of mempool entries after 24 hours
- Expose timestamp field for mempool transactions (for client-side filtering)
- Revert accidental change in API v1 (renamed
unsigned_tx_hex
totx_hex
increate_*()
result) - Disable
p2sh
encoding, which no longer works with recent versions of Bitcoin Core
CLI
Credits
- Ouziel Slama
- Warren Puffett
- Adam Krellenstein
v10.4.1
Release Notes - Counterparty Core v10.4.1 (2024-09-24)
This release is a minor update with miscellaneous bugfixes.
Upgrading
This release fixes an old bug leading to potential undefined behavior for dispenser refills. No database reparse is required.
ChangeLog
Protocol Changes
Bugfixes
- Fix order cache: update cache when an order is filled
- Fix typo in
protocol_changes.json
- Fix division by zero in
api.util.divide()
- Catch invalid raw transaction in
/v2/transactions/info
endpoint - Fix duplicate command in
xcpcli.py
- Fix
source
field when refilling a dispenser created by a different source
Codebase
- Don't report expected errors to Sentry in API v1
- Use
trace
instead ofwarning
for "Prefetch queue is empty." message - Use debug for expected and handled
yoyo
migration error - Support Python 3.10 and 3.11 only
- Refactor and clean up
transaction.py
. The contents of this file are now distributed acrosslib/api/compose.py
,lib/transaction_helper/transaction_outputs.py
, andlib/transaction_helper/transaction_inputs.py
.
API
- Add support for
inputs_set
parameter - Rename the
fee
argument toexact_fee
(thefee
argument is still available in API v1) - Have the composition API return, in addition to a
rawtransaction
or apsbt
, the following fields:data
,btc_in
,btc_out
,btc_change
, andbtc_fee
- Add
sort
argument fororders
,order_matches
anddispenser
- Add the following route:
/v2/transactions/<tx_hash>/info
(This route works if the tx is in the mempool of the queried node)
CLI
Credits
- Ouziel Slama
- Warren Puffett
- Adam Krellenstein
v10.4.0
Release Notes - Counterparty Core v10.4.0 (2024-09-18)
This is a major release with numerous protocol upgrades that will dramatically increase the functionality of the Counterparty protocol as well as resolve some long-standing security issues, in addition to a number of bugfixes and quality-of-life improvements.
Upgrading
If you run a Counterparty node, be sure to upgrade your node as soon as possible. Your node must be upgraded by block 866,000, which should be mined around October 16th, 2024, approximately four weeks from today.
The upgrade procedure should be straightforward: the API remains backwards-compatible, and the node will not have to perform a reparse. There are, however, two notable changes in this release that will require attention:
-
It will no longer be possible to create a dispenser from an address that you don’t control. You will have to create the dispenser from the
source
address of the transaction, like all other Counterparty transactions. -
It will no longer be possible to trigger dispensers using vanilla Bitcoin wallets. The
create_send
API call has been modified so that it will automatically turn any BTC send to a dispenser into acreate_dispense
transaction.
ChangeLog
Protocol Changes
- Require Dispenser to be Source Address
- Make Dispenses Normal Counterparty Transactions
- Be Able to Lock Descriptions
- Fair Minting Protocol
- UTXO Support
- Gas System
- Expire order matches then orders
- Free Subassets
- Subassets on Numeric Assets
- Fix minimum BTC amount in order contract
Bugfixes
- Fix adding new transactions in unit test fixtures (
scenarios.py
) - Fix mempool parsing on testnet and regtest
- Fix
get_dispensers_by_asset
endpoint filtering by query parameter. Numeric statuses can now be used, e.g.status=0
. - Fix
cursor
type in API routes - Fix
ledger.get_last_db_index()
(server is ready onBLOCK_PARSED
not onNEW_BLOCK
) - Fix
ledger.get_block(block_index)
function - Check that the previous block is present when a block is received with ZeroMQ
- Log API v1 responses
Codebase
- New test suite and github workflow with
regtest
network - Delete mempool events older than 24 hours
- Use order caching only during catch-up
API
- Add
return_only_data
argument for composition routes - Add an
asset_events
field to theissuances
table. This field contains one or more of the following values separated by spaces:creation
,reissuance
,reset
,lock_quantity
,lock_description
,open_fairminter
,close_fairminter
,fairmint
. - Return only valid issuances
- Generate API blueprint from regtest node
- Run Dredd tests on regtest node
- Add the new following routes:
/v2/order_matches
/v2/bitcoin/getmempoolinfo
CLI
Credits
- Ouziel Slama
- Warren Puffett
- Adam Krellenstein
v10.3.2
Release Notes - Counterparty Core v10.3.2 (2024-08-11)
This release is a minor update with some bugfixes.
Upgrading
This release is not a protocol change and does not require any reparsing.
ChangeLog
Bugfixes
- Fix
get_value_by_block_index()
onregtest
- Fix events hash mismatch after a reparse
- Fix
regtest
default ports - Fix
/v2/assets/XCP
route - Fix queries on
messages
table (remove mempool filtering) - Fix graceful closing of
counterparty.db
- Fix Get XCP Holders route
- Fix division by zero in API market prices
Codebase
API
CLI
- Move Counterparty Node UUID from
~/counterparty-node-uuid
to~/.local/state/counterparty/.counterparty-node-uuid
Credits
- Ouziel Slama
- Adam Krellenstein
- Warren Puffett
- Matt Marcello
v10.3.1
Release Notes - Counterparty Core v10.3.1 (2024-08-07)
This release is a relatively minor update with a large number of improvements to the node API, as well as a few important bugfixes and tweaks to the CLI and telemetry subsystems.
Upgrading
This release is not a protocol change and does not require any reparsing.
ChangeLog
Bugfixes
- Fix cache for
/v2/bitcoin/*
routes - Fix queries by
asset_longname
- Fix capture exception by Sentry
- Be sure not to cache
orders
and dispenser addresses from mempool - Catch
UnicodeError
intransactions.unpack()
function - Fix
script_to_address()
function on Regtest
Codebase
API
- Add the following routes:
- Get Balances By Addresses
- Get Events By Addresses
- Get Mempool Events By Addresses
- Get Order Matches By Asset
- Get Order Matches By Two Assets
- Get Subassets By Asset
- Get Unspent Txouts By Addresses
- Capitalize
<asset>
in routes - Accept
asset_longname
forGET /v2/assets/<asset>/issuances
- Add default values for the
locked
andreset
fields inissuances
table - Add XCP to the
assets_info
table - Remove
timestamp
from events in API results - Standardize the format of mempool events and confirmed events
- Use strings instead of integers to query
dispensers
by status - Accept several statuses for querying
dispensers
,orders
andorder_matches
- Add
sort
argument for the following routes:/v2/assets/<asset>/balances
/v2/addresses/<address>/balances
/v2/addresses/balances
- Sort
orders
bytx_index DESC
- Insert
return_psbt
argument for compose endpoints - Insert
market_price
when getting orders or order matches by two assets - Make queries to get orders or order matches by two assets case-insensitive
- Make unconfirmed objects (
transactions
,issuances
,orders
, etc.) accessible via the API with the parameter?show_unconfirmed=true
- Inject
fiat_price
and oracle info in dispensers - Include decoded transaction in the result of
/v2/transactions/info
- Return
null
whendestination
field is empty - Support comma-separated addresses for the
<address>
value in API routes - Catch
CBitcoinAddressError
correctly - Return a 400 error instead a 503 on
ComposeError
andUnpackError
CLI
- Add
--json-logs
flag for displaying logs in the JSON format - Send telemetry data after each block
- Reduce Sentry Trace Sample Rate to 10%
Credits
- Ouziel Slama
- Adam Krellenstein
- Warren Puffett
v10.3.0
Release Notes - Counterparty Core v10.3.0 (2024-07-12)
This version most notably introduces a major performance optimization for node API access: an additional SQLite3 database has been added which tracks the current state of all Counterparty objects (in addition to the primary database that is purely log-structured). Other major changes for this version include the removal of the kickstart
functionality, which is possible now that start
is performant, and numerous tweaks and improvements to the v2 API.
Upgrading
This update requires an automatic full reparse of the Counterparty transactions to populate the new database file. This process may take a number of hours to complete.
ChangeLog
Bugfixes
- Fix verbose logging of order matches
- Fix the order of
NEW_TRANSACTION
events on reparse - Check the ZMQ
rawblock
topic more frequently on testnet - Trigger
NEW_TRANSACTION_OUTPUT
events during a reparse - Fix incorrect
messages_hash
after a reparse - Fix silent errors in ZMQ follower
- Catch
TimeoutError
during version check; re-check on error - Catch Bitcoin Core API errors correctly
- Show warning to user when Bitcoin Core cannot be reached
Codebase
- Remove
UPDATE
query for theaddresses
table - Add
NEW_ADDRESS_OPTIONS
andADDRESS_OPTIONS_UPDATE
events - Add
tx_hash
toDISPENSE_UPDATE
event - Add
event_hash
field to themessages
table - Add a new database optimized for the API. This new database is reconstructed only from events by the
API Watcher
, and a new fieldmessages.event_hash
ensures the correspondence between the two databases in the event of a blockchain reorganization. - Parse transactions vouts with Rust
- Optimize
get_matching_orders()
with consolidated cache
API
- Introduce the following new routes:
/v2/transactions/<tx_hash>/sends
/v2/transactions/<tx_hash>/dispenses
/v2/dispenses
/v2/sends
/v2/issuances
/v2/issuances/<tx_hash>
/v2/sweeps
/v2/sweeps/<tx_hash>
/v2/broadcasts
/v2/broadcasts/<tx_hash>
/v2/assets/<asset>/info
- Add
quantity_normalized
to issuances endpoints - Increase the detail for the
InsufficientBTC
error - Inject
unpacked_data
into all results containing adata
field whenverbose=true
- Remove
asset_info
from theASSET_ISSUANCE
event - Standardize on trailing zeros for divisible quantities
/v2/orders/<order_hash>/matches
returns all order matches by default- Fix cache for
/v2/blocks/last
route - Clean and enrich
message_data
for MPMA sends - Support
dispense
message type - Add
supply_normalized
to asset info object in API responses - Add
btc_amount
to API responses returningdispenses
objects - Use
all
as the default status when returningorders
objects - Provide link to Apiary documentation in the root route for the v2 API
CLI
- Remove all
kickstart
functionality;start
is now recommended for the initial catchup. - Tweak RPS logging
- Fix erroneous Rust Fetcher errors on shutdown
- Use millisecond precision for logging
Credits
- Ouziel Slama
- Adam Krellenstein
- Warren Puffett