trontxsize


Nametrontxsize JSON
Version 1.0.6 PyPI version JSON
download
home_pagehttps://github.com/bitcart/trontxsize
SummaryCalculate tron transaction size (bandwidth)
upload_time2024-01-10 21:16:24
maintainer
docs_urlNone
authorMrNaif2018
requires_python>=3.8
licenseMIT
keywords tron trx bitcart bandwidth
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # trontxsize - Calculate tron transaction size in bytes

[![CircleCI](https://circleci.com/gh/bitcart/trontxsize.svg?style=svg)](https://circleci.com/gh/bitcart/trontxsize)
[![Codecov](https://img.shields.io/codecov/c/github/bitcart/trontxsize?style=flat-square)](https://codecov.io/gh/bitcart/trontxsize)
[![PyPI version](https://img.shields.io/pypi/v/trontxsize.svg?style=flat-square)](https://pypi.python.org/pypi/trontxsize/)

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:

```python
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](LICENSE)

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/bitcart/trontxsize",
    "name": "trontxsize",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": "",
    "keywords": "tron,trx,bitcart,bandwidth",
    "author": "MrNaif2018",
    "author_email": "chuff184@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/72/06/f70c46c056d8eaa71acebf08883b254537cf19a53ae0d6b1951be7c78c05/trontxsize-1.0.6.tar.gz",
    "platform": null,
    "description": "# trontxsize - Calculate tron transaction size in bytes\n\n[![CircleCI](https://circleci.com/gh/bitcart/trontxsize.svg?style=svg)](https://circleci.com/gh/bitcart/trontxsize)\n[![Codecov](https://img.shields.io/codecov/c/github/bitcart/trontxsize?style=flat-square)](https://codecov.io/gh/bitcart/trontxsize)\n[![PyPI version](https://img.shields.io/pypi/v/trontxsize.svg?style=flat-square)](https://pypi.python.org/pypi/trontxsize/)\n\nIn Tron (TRX) network, fee calculation algorithm is complex. And the most complex part of it is that it depends on transaction size.\n\nBut there's no method existing to calculate it\n\nThis library does just this:\n\n```python\nimport trontxsize\n\nprint(trontxsize.get_tx_size({\"raw_data\": ..., \"signatures\": [...])) # matches bandwidth you see in block explorer\n```\n\nHow does it work? The library pre-compiled a trimmed-down version of Tron protobuf and uses it directly to calculate transaction size\n\n## Copyright and License\n\nCopyright (C) 2022 MrNaif2018\n\nLicensed under the [MIT License](LICENSE)\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Calculate tron transaction size (bandwidth)",
    "version": "1.0.6",
    "project_urls": {
        "Homepage": "https://github.com/bitcart/trontxsize"
    },
    "split_keywords": [
        "tron",
        "trx",
        "bitcart",
        "bandwidth"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "837f770a526e1600ea6b58984b492fb94661aa68508da4ef6ff6499bd453ba21",
                "md5": "836beb9456e04ad3b37c95a36f618c91",
                "sha256": "35995eba52482139ce4f548d2c4cd135d0604e6b27f3c6ef846f336251978de1"
            },
            "downloads": -1,
            "filename": "trontxsize-1.0.6-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "836beb9456e04ad3b37c95a36f618c91",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 5344,
            "upload_time": "2024-01-10T21:16:22",
            "upload_time_iso_8601": "2024-01-10T21:16:22.864523Z",
            "url": "https://files.pythonhosted.org/packages/83/7f/770a526e1600ea6b58984b492fb94661aa68508da4ef6ff6499bd453ba21/trontxsize-1.0.6-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "7206f70c46c056d8eaa71acebf08883b254537cf19a53ae0d6b1951be7c78c05",
                "md5": "43a61acd6238097d98dab8277143b58e",
                "sha256": "87ae657d3a7634b6145b514be40607a9f34198390ec22eb7418bd38054752979"
            },
            "downloads": -1,
            "filename": "trontxsize-1.0.6.tar.gz",
            "has_sig": false,
            "md5_digest": "43a61acd6238097d98dab8277143b58e",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 6291,
            "upload_time": "2024-01-10T21:16:24",
            "upload_time_iso_8601": "2024-01-10T21:16:24.436029Z",
            "url": "https://files.pythonhosted.org/packages/72/06/f70c46c056d8eaa71acebf08883b254537cf19a53ae0d6b1951be7c78c05/trontxsize-1.0.6.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-01-10 21:16:24",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "bitcart",
    "github_project": "trontxsize",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "circle": true,
    "lcname": "trontxsize"
}
        
Elapsed time: 0.16405s