Page MenuHomePhabricator

[electrum] avoid unneccessary bytes <-> hex conversion for block header
ClosedPublic

Authored by PiRK on Oct 2 2023, 11:41.

Details

Summary

Make serialize_header return bytes to avoid converting to bytes at all callsites.

Depends on D14569

Test Plan

python test_runner.py

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

PiRK requested review of this revision.Oct 2 2023, 11:41
electrum/electrumabc/blockchain.py
140 ↗(On Diff #42477)

After that, rev_hex and int_to_le_hex are needed only in keystore.py (which still uses hex strings for keys)

This revision is now accepted and ready to land.Oct 2 2023, 14:01