Calculate tron transaction size (bandwidth)
Project description
trontxsize - Calculate tron transaction size in bytes
In Tron (TRX) network, fee calculation algorithm is complex. And the most complex part of it is that it depends on transaction size.
But there's no method existing to calculate it
This library does just this:
import trontxsize
print(trontxsize.get_tx_size({"raw_data": ..., "signatures": [...])) # matches bandwidth you see in block explorer
How does it work? The library pre-compiled a trimmed-down version of Tron protobuf and uses it directly to calculate transaction size
Copyright and License
Copyright (C) 2022 MrNaif2018
Licensed under the MIT License
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
trontxsize-1.0.6.tar.gz
(6.3 kB
view details)
Built Distribution
File details
Details for the file trontxsize-1.0.6.tar.gz
.
File metadata
- Download URL: trontxsize-1.0.6.tar.gz
- Upload date:
- Size: 6.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.8.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 87ae657d3a7634b6145b514be40607a9f34198390ec22eb7418bd38054752979 |
|
MD5 | 43a61acd6238097d98dab8277143b58e |
|
BLAKE2b-256 | 7206f70c46c056d8eaa71acebf08883b254537cf19a53ae0d6b1951be7c78c05 |
File details
Details for the file trontxsize-1.0.6-py3-none-any.whl
.
File metadata
- Download URL: trontxsize-1.0.6-py3-none-any.whl
- Upload date:
- Size: 5.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.8.18
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 35995eba52482139ce4f548d2c4cd135d0604e6b27f3c6ef846f336251978de1 |
|
MD5 | 836beb9456e04ad3b37c95a36f618c91 |
|
BLAKE2b-256 | 837f770a526e1600ea6b58984b492fb94661aa68508da4ef6ff6499bd453ba21 |