This is quite an important release for several reasons:
KOIOS Collaboration & CIP-88 Support
Our friends at KOIOS came up with the idea of implementing a function for convenient validation of key registration according to their proposed CIP-88 standard. This release owes its existence to that collaboration.
It has a rather unusual tag: v1.0.5-p1
, where p1
stands for "phase 1". This is a full-fledged release, not a beta—it is simply divided into two phases.
- Phase 1 introduces the implementation of
tools_verify_cip88_pool_key_registration
as an SQL procedure that utilizes multiple calls to native code instead of a fully native implementation. Essentially, this is a prototype, but one that is production-ready and fully tested. - Phase 2 (
v1.0.5-p2
) will provide the same functionality but as a purely native implementation, without changing the function signature. The only difference will be improved performance. 🚀
CBOR<->JSONB Improvements
During development, we uncovered several inconsistencies in repeated CBOR<->JSONB serialization and deserialization, which have now been fixed. This makes the release not just important but also highly beneficial.
-
Enhanced CBOR->JSONB Encoder
- The encoder now properly serializes
bytea
as hex-encoded rather than a hex-like string. - This makes CBOR output more compact.
- It also aligns the serialization process with
cardano-cli
.
- The encoder now properly serializes
-
Fixing JSONB Bytearray Handling
- JSONB does not have a native
bytearray
type; it is always passed as a hex-encoded string, which, in some cases, was still stored as text. - This limitation has been successfully worked around, making the handling more robust than ever.
- JSONB does not have a native
-
New Function:
cbor_decode_jsonb_hex2bytea
- Correct encoding of
bytea
into CBOR is important, but so is correct decoding. - Instead of modifying the existing
cbor_decode_jsonb
function (which could introduce regressions for users), a new function,cbor_decode_jsonb_hex2bytea
, was introduced to handle this properly.
- Correct encoding of
Release Notes:
- Fixed the issue with
\u{0}
characters in property keys; - JSONB->CBOR conversion now follows the same rules as
cardano-cli
; - JSONB->CBOR conversion now correctly handles bytearray transfer between formats;
- CBOR->JSONB conversion now allows handling bytearray transfer between formats with
cbor_decode_jsonb_hex2bytea
function; - Refactoring, lots of refactoring, and some optimizations;
- Added a function
tools_verify_cip88_pool_key_registration
; - README.md update;
- Tests update;
- Migrations update;