📢 Release Announcement: steemutil v0.0.12 & steemgosdk v0.0.8

in #steemit14 days ago

steemutil v0.0.12

Critical Fix: Custom JSON Operation Serialization

This release fixes a critical bug in custom_json operation serialization that was causing "missing required posting authority" errors when broadcasting transactions.

What Was Fixed

  • Operation Type Code Encoding: The CustomJSONOperation.MarshalTransaction() method now correctly encodes the operation type code (18) at the beginning of the serialized operation data. Previously, the operation type code was missing, causing the blockchain to interpret the operation incorrectly.
  • Flat Set Serialization: Added explicit sorting for required_auths and required_posting_auths fields to ensure consistent serialization matching Steem's C++ flat_set requirements.

Technical Details

The fix ensures that custom_json operations are serialized identically to steem-js, maintaining full compatibility with the Steem blockchain protocol. This resolves issues where valid transactions were rejected by the network due to incorrect binary encoding.

Testing Improvements

  • Enhanced unit tests with comprehensive coverage of operation serialization
  • Added tests comparing Go SDK serialization with steem-js reference implementation
  • Improved test coverage for edge cases including empty auths and multiple auth types

steemgosdk v0.0.8

Dependency Update & Custom JSON Improvements

This release updates the dependency to steemutil v0.0.12 and includes improvements to the CustomJson broadcasting method.

Changes

  • Updated Dependency: Now requires steemutil v0.0.12 which includes the critical custom_json serialization fix
  • Auth Sorting: The Broadcast.CustomJson() method now automatically sorts required_auths and required_posting_auths before creating operations, ensuring consistent transaction serialization
  • Enhanced Debugging: Added comprehensive debug output for transaction serialization, digest calculation, and signature recovery verification

Impact

With this release, custom_json operations will now broadcast successfully to the Steem blockchain without "missing required posting authority" errors. The SDK maintains full compatibility with steem-js for all custom_json operations.


Migration Guide

For steemutil Users

No code changes required. Simply update your dependency:

go get github.com/steemit/steemutil@v0.0.12
go mod tidy

For steemgosdk Users

Update to the latest version:

go get github.com/steemit/steemgosdk@v0.0.8
go mod tidy

Your existing CustomJson calls will now work correctly without any code modifications.


Breaking Changes

None. Both releases are backward compatible.


Acknowledgments

This fix was identified through detailed comparison with the steem-js reference implementation, ensuring protocol-level compatibility across all Steem SDK implementations.


Full Changelog: See the respective repository release pages for detailed commit history.

Any Issue

Sort:  

Upvoted! Thank you for supporting witness @jswit.