quorum-data-py


Namequorum-data-py JSON
Version 1.2.7 PyPI version JSON
download
home_pagehttps://github.com/liujuanjuan1984/quorum_data_py
SummaryPython Data for Apps of QuoRum
upload_time2023-05-03 15:46:56
maintainer
docs_urlNone
authorliujuanjuan1984
requires_python>=3.7
license
keywords quorum_data_py rumsystem quorum
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Python Data for Apps of QuoRum

quorum 常用数据结构的 python 封装:

1、feed:

基于 quorum 新共识,目前被 rum app、feed、port、circle 等几款产品采用的数据结构

参考:

- https://docs.rumsystem.net/docs/data-format-and-examples

请留意,这只是推荐结构,并不是唯一标准。quorum chain 是非常开放的,客户端完全可以按照自己的需求来构造上链数据的结构。

2、converter:

基于 quorum 新共识,从旧链 trx 或从 新链 trx 转换为待发布的数据。目前主要用作数据迁移:从旧共识链迁移到新共识链;在新共识链之间迁移。

3、trx_type:

判断 trx 的类型。该方法所返回的结果,与 rum-app,feed 等产品的处理保持一致。

### Install


```sh
pip install quorum_data_py
```

### Examples

```python

from quorum_data_py import feed

# create a new post data 
data = feed.new_post(content='hello guys')

# create a like post data
data = feed.like('a-post-id')

```

适用于 fullnode 也适用于 lightnode,比如:

```python

from quorum_data_py import feed
from quorum_fullnode_py import FullNode 

jwt = "xxx"
url = "xxx"

fullnode = FullNode(url,jwt)
data = feed.new_post(content='hello guys')
fullnode.api.post_content(data)

```

```python

from quorum_data_py import feed
from quorum_mininode_py import MiniNode 

seed = "xxx"

mininode = MiniNode(seed)
data = feed.new_post(content='hello guys')
mininode.api.post_content(data)

```

### Source

- quorum fullnode sdk for python: https://github.com/liujuanjuan1984/quorum-fullnode-py 
- quorum mininode sdk for python: https://github.com/liujuanjuan1984/quorum-mininode-py 
- and more ...  https://github.com/okdaodine/awesome-quorum

### License

This work is released under the `MIT` license. A copy of the license is provided in the [LICENSE](https://github.com/liujuanjuan1984/quorum_data_py/blob/master/LICENSE) file.

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/liujuanjuan1984/quorum_data_py",
    "name": "quorum-data-py",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.7",
    "maintainer_email": "",
    "keywords": "quorum_data_py,rumsystem,quorum",
    "author": "liujuanjuan1984",
    "author_email": "qiaoanlu@163.com",
    "download_url": "https://files.pythonhosted.org/packages/b7/ca/753af29a77535d1a0e6dfa4260cf3fc1aea828763ed8b1e4b6cc4141b137/quorum_data_py-1.2.7.tar.gz",
    "platform": null,
    "description": "# Python Data for Apps of QuoRum\r\n\r\nquorum \u5e38\u7528\u6570\u636e\u7ed3\u6784\u7684 python \u5c01\u88c5\uff1a\r\n\r\n1\u3001feed\uff1a\r\n\r\n\u57fa\u4e8e quorum \u65b0\u5171\u8bc6\uff0c\u76ee\u524d\u88ab rum app\u3001feed\u3001port\u3001circle \u7b49\u51e0\u6b3e\u4ea7\u54c1\u91c7\u7528\u7684\u6570\u636e\u7ed3\u6784\r\n\r\n\u53c2\u8003\uff1a\r\n\r\n- https://docs.rumsystem.net/docs/data-format-and-examples\r\n\r\n\u8bf7\u7559\u610f\uff0c\u8fd9\u53ea\u662f\u63a8\u8350\u7ed3\u6784\uff0c\u5e76\u4e0d\u662f\u552f\u4e00\u6807\u51c6\u3002quorum chain \u662f\u975e\u5e38\u5f00\u653e\u7684\uff0c\u5ba2\u6237\u7aef\u5b8c\u5168\u53ef\u4ee5\u6309\u7167\u81ea\u5df1\u7684\u9700\u6c42\u6765\u6784\u9020\u4e0a\u94fe\u6570\u636e\u7684\u7ed3\u6784\u3002\r\n\r\n2\u3001converter\uff1a\r\n\r\n\u57fa\u4e8e quorum \u65b0\u5171\u8bc6\uff0c\u4ece\u65e7\u94fe trx \u6216\u4ece \u65b0\u94fe trx \u8f6c\u6362\u4e3a\u5f85\u53d1\u5e03\u7684\u6570\u636e\u3002\u76ee\u524d\u4e3b\u8981\u7528\u4f5c\u6570\u636e\u8fc1\u79fb\uff1a\u4ece\u65e7\u5171\u8bc6\u94fe\u8fc1\u79fb\u5230\u65b0\u5171\u8bc6\u94fe\uff1b\u5728\u65b0\u5171\u8bc6\u94fe\u4e4b\u95f4\u8fc1\u79fb\u3002\r\n\r\n3\u3001trx_type\uff1a\r\n\r\n\u5224\u65ad trx \u7684\u7c7b\u578b\u3002\u8be5\u65b9\u6cd5\u6240\u8fd4\u56de\u7684\u7ed3\u679c\uff0c\u4e0e rum-app\uff0cfeed \u7b49\u4ea7\u54c1\u7684\u5904\u7406\u4fdd\u6301\u4e00\u81f4\u3002\r\n\r\n### Install\r\n\r\n\r\n```sh\r\npip install quorum_data_py\r\n```\r\n\r\n### Examples\r\n\r\n```python\r\n\r\nfrom quorum_data_py import feed\r\n\r\n# create a new post data \r\ndata = feed.new_post(content='hello guys')\r\n\r\n# create a like post data\r\ndata = feed.like('a-post-id')\r\n\r\n```\r\n\r\n\u9002\u7528\u4e8e fullnode \u4e5f\u9002\u7528\u4e8e lightnode\uff0c\u6bd4\u5982\uff1a\r\n\r\n```python\r\n\r\nfrom quorum_data_py import feed\r\nfrom quorum_fullnode_py import FullNode \r\n\r\njwt = \"xxx\"\r\nurl = \"xxx\"\r\n\r\nfullnode = FullNode(url,jwt)\r\ndata = feed.new_post(content='hello guys')\r\nfullnode.api.post_content(data)\r\n\r\n```\r\n\r\n```python\r\n\r\nfrom quorum_data_py import feed\r\nfrom quorum_mininode_py import MiniNode \r\n\r\nseed = \"xxx\"\r\n\r\nmininode = MiniNode(seed)\r\ndata = feed.new_post(content='hello guys')\r\nmininode.api.post_content(data)\r\n\r\n```\r\n\r\n### Source\r\n\r\n- quorum fullnode sdk for python: https://github.com/liujuanjuan1984/quorum-fullnode-py \r\n- quorum mininode sdk for python: https://github.com/liujuanjuan1984/quorum-mininode-py \r\n- and more ...  https://github.com/okdaodine/awesome-quorum\r\n\r\n### License\r\n\r\nThis work is released under the `MIT` license. A copy of the license is provided in the [LICENSE](https://github.com/liujuanjuan1984/quorum_data_py/blob/master/LICENSE) file.\r\n",
    "bugtrack_url": null,
    "license": "",
    "summary": "Python Data for Apps of QuoRum",
    "version": "1.2.7",
    "project_urls": {
        "About Quorum": "https://github.com/rumsystem/quorum",
        "Bug Tracker": "https://github.com/liujuanjuan1984/quorum_data_py/issues",
        "Github Repo": "https://github.com/liujuanjuan1984/quorum_data_py",
        "Homepage": "https://github.com/liujuanjuan1984/quorum_data_py"
    },
    "split_keywords": [
        "quorum_data_py",
        "rumsystem",
        "quorum"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "3aa4a244334f181cd7b7e44c1510e38225b00210bde79a2bdd3943bef0f7142c",
                "md5": "ac3e12c920204614a3385ba2d4b3e22e",
                "sha256": "1dba06602f4e87e38a0e56f4b2f10c3c9feb81025bf3ebec276bd013f8fa83a1"
            },
            "downloads": -1,
            "filename": "quorum_data_py-1.2.7-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "ac3e12c920204614a3385ba2d4b3e22e",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.7",
            "size": 9473,
            "upload_time": "2023-05-03T15:46:54",
            "upload_time_iso_8601": "2023-05-03T15:46:54.537964Z",
            "url": "https://files.pythonhosted.org/packages/3a/a4/a244334f181cd7b7e44c1510e38225b00210bde79a2bdd3943bef0f7142c/quorum_data_py-1.2.7-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "b7ca753af29a77535d1a0e6dfa4260cf3fc1aea828763ed8b1e4b6cc4141b137",
                "md5": "bffc1bf70aca3b39394a65cd68f1a20a",
                "sha256": "36fa0e84304610d8e824159363cccda87d8b1af3a739f00ea7c815692e565949"
            },
            "downloads": -1,
            "filename": "quorum_data_py-1.2.7.tar.gz",
            "has_sig": false,
            "md5_digest": "bffc1bf70aca3b39394a65cd68f1a20a",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.7",
            "size": 9409,
            "upload_time": "2023-05-03T15:46:56",
            "upload_time_iso_8601": "2023-05-03T15:46:56.765505Z",
            "url": "https://files.pythonhosted.org/packages/b7/ca/753af29a77535d1a0e6dfa4260cf3fc1aea828763ed8b1e4b6cc4141b137/quorum_data_py-1.2.7.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-05-03 15:46:56",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "liujuanjuan1984",
    "github_project": "quorum_data_py",
    "github_not_found": true,
    "lcname": "quorum-data-py"
}
        
Elapsed time: 1.10891s