karask / python-bitcoin-utils

Library to interact with the Bitcoin network. Ideal for low-level learning and experimenting.
MIT License
271 stars 102 forks source link

OverflowError: int too big to convert #36

Closed tomjeannesson closed 1 year ago

tomjeannesson commented 1 year ago

Hello! I'm am getting the following error when signing larger text messages (arround 600 characters), when testing my signatures with this tool.

message_size = len(message).to_bytes(1, byteorder='big')
OverflowError: int too big to convert

Is there a workaround to this (I am new to blockchain)? Thanks for your time!

tomjeannesson commented 1 year ago

Shouldn't this be taken into account? Variable_length_integer

karask commented 1 year ago

Hi @tomjeannesson

Yes, it should be varint. Just updated in 0.5.9.

Thanks for the feedback.

tomjeannesson commented 1 year ago

Hi @tomjeannesson

Yes, it should be varint. Just updated in 0.5.9.

Thanks for the feedback.

Thanks for the quick fix!