mirror of
https://github.com/planetmint/planetmint.git
synced 2025-11-24 14:35:45 +00:00
fixed doc-build
Signed-off-by: Jürgen Eckel <juergen@riddleandcode.com>
This commit is contained in:
parent
1331ef1ed2
commit
c2e09d03b9
@ -54,13 +54,13 @@ import sphinx_rtd_theme
|
|||||||
|
|
||||||
extensions = [
|
extensions = [
|
||||||
"myst_parser",
|
"myst_parser",
|
||||||
|
"sphinx.ext.napoleon",
|
||||||
"sphinx.ext.autosectionlabel",
|
"sphinx.ext.autosectionlabel",
|
||||||
"sphinx.ext.autodoc",
|
"sphinx.ext.autodoc",
|
||||||
"sphinx.ext.intersphinx",
|
"sphinx.ext.intersphinx",
|
||||||
"sphinx.ext.coverage",
|
"sphinx.ext.coverage",
|
||||||
"sphinx.ext.viewcode",
|
"sphinx.ext.viewcode",
|
||||||
"sphinx.ext.todo",
|
"sphinx.ext.todo",
|
||||||
"sphinx.ext.napoleon",
|
|
||||||
"sphinxcontrib.httpdomain",
|
"sphinxcontrib.httpdomain",
|
||||||
"aafigure.sphinxext",
|
"aafigure.sphinxext",
|
||||||
#'sphinx_toolbox.collapse',
|
#'sphinx_toolbox.collapse',
|
||||||
|
|||||||
@ -4,7 +4,7 @@ Content-Type: application/json
|
|||||||
{
|
{
|
||||||
"assets": "/assets/",
|
"assets": "/assets/",
|
||||||
"blocks": "/blocks/",
|
"blocks": "/blocks/",
|
||||||
"docs": "https://docs.planetmint.io/projects/server/en/v1.3.1/http-client-server-api.html",
|
"docs": "https://docs.planetmint.io/projects/server/en/v1.4.1/http-client-server-api.html",
|
||||||
"metadata": "/metadata/",
|
"metadata": "/metadata/",
|
||||||
"outputs": "/outputs/",
|
"outputs": "/outputs/",
|
||||||
"streamedblocks": "ws://localhost:9985/api/v1/streams/valid_blocks",
|
"streamedblocks": "ws://localhost:9985/api/v1/streams/valid_blocks",
|
||||||
|
|||||||
@ -7,15 +7,13 @@ Content-Type: application/json
|
|||||||
{
|
{
|
||||||
"assets": [
|
"assets": [
|
||||||
{
|
{
|
||||||
"data": {
|
"data": "QmQP5C3PmhH9oB84n7YqSY4WVqmYatdoo1BdwhH4zmcwqM"
|
||||||
"msg": "Hello Planetmint!"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": "61e1312b80705e0dabb948c9d78dae7f62d64832abda822b13d89c4a7305d4ac",
|
"id": "0fdeb547670bbea980389df53cf5a91e60159339084c6b0b5cc0b5494a679530",
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{
|
{
|
||||||
"fulfillment": "pGSAIDE5i63cn4X8T8N1sZ2mGkJD5lNRnBM4PZgI_zvzbr-cgUCWcUaLa2U-nkmZ6oYj14aeV6B4TJH2NvZ8k2ZTwcGiaiCGXDQT2dEPfMCFwM8lwSousafCu4c7EgVZ1GzUDjsN",
|
"fulfillment": "pGSAIDE5i63cn4X8T8N1sZ2mGkJD5lNRnBM4PZgI_zvzbr-cgUDklzRb5aUQz9slbaqSWap1AfC-cacTCN3CGtFy2LPK7JKEqKG2b0KQXnUcFksk_KH_v6ImFXHsclKSp1OJkIEI",
|
||||||
"fulfills": null,
|
"fulfills": null,
|
||||||
"owners_before": [
|
"owners_before": [
|
||||||
"4K9sWUMFwTgaDGPfdynrbxWqWS6sWmKbZoTjxLtVUibD"
|
"4K9sWUMFwTgaDGPfdynrbxWqWS6sWmKbZoTjxLtVUibD"
|
||||||
@ -39,7 +37,7 @@ Content-Type: application/json
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"version": "2.0"
|
"version": "3.0"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,3 +1,3 @@
|
|||||||
GET /api/v1/blocks?transaction_id=61e1312b80705e0dabb948c9d78dae7f62d64832abda822b13d89c4a7305d4ac HTTP/1.1
|
GET /api/v1/blocks?transaction_id=0fdeb547670bbea980389df53cf5a91e60159339084c6b0b5cc0b5494a679530 HTTP/1.1
|
||||||
Host: example.com
|
Host: example.com
|
||||||
|
|
||||||
|
|||||||
@ -1,3 +1,3 @@
|
|||||||
GET /api/v1/transactions?operation=TRANSFER&asset_id=61e1312b80705e0dabb948c9d78dae7f62d64832abda822b13d89c4a7305d4ac HTTP/1.1
|
GET /api/v1/transactions?operation=TRANSFER&asset_id=0fdeb547670bbea980389df53cf5a91e60159339084c6b0b5cc0b5494a679530 HTTP/1.1
|
||||||
Host: example.com
|
Host: example.com
|
||||||
|
|
||||||
|
|||||||
@ -4,16 +4,16 @@ Content-Type: application/json
|
|||||||
[{
|
[{
|
||||||
"assets": [
|
"assets": [
|
||||||
{
|
{
|
||||||
"id": "61e1312b80705e0dabb948c9d78dae7f62d64832abda822b13d89c4a7305d4ac"
|
"id": "0fdeb547670bbea980389df53cf5a91e60159339084c6b0b5cc0b5494a679530"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": "b6e1ab3d48bbbbb0e40b952e70ec5d439b2745e0ba0c44b4ee877657e9ac33f0",
|
"id": "8d11fe2bd91c4747a41e0c3dbe1400c511175be42f008d6cff92cbfa9e04f799",
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{
|
{
|
||||||
"fulfillment": "pGSAIDE5i63cn4X8T8N1sZ2mGkJD5lNRnBM4PZgI_zvzbr-cgUA4BB4fxDXK3CQTbKpH5gTAN76NG-iopNuuDEfBbZ1Fl-ipNU46t8VCvK9ghm9Q53aFRW6DDiW5wcWXxY0sS4EJ",
|
"fulfillment": "pGSAIDE5i63cn4X8T8N1sZ2mGkJD5lNRnBM4PZgI_zvzbr-cgUCh-rpO-xqDm2fngjzxnKc39G16FpFMo0y50sHT7_uo1Itzvh4jsxnSGco2HjG6ZF-lSiGsASZ4uIIHuPM57yUI",
|
||||||
"fulfills": {
|
"fulfills": {
|
||||||
"output_index": 0,
|
"output_index": 0,
|
||||||
"transaction_id": "61e1312b80705e0dabb948c9d78dae7f62d64832abda822b13d89c4a7305d4ac"
|
"transaction_id": "0fdeb547670bbea980389df53cf5a91e60159339084c6b0b5cc0b5494a679530"
|
||||||
},
|
},
|
||||||
"owners_before": [
|
"owners_before": [
|
||||||
"4K9sWUMFwTgaDGPfdynrbxWqWS6sWmKbZoTjxLtVUibD"
|
"4K9sWUMFwTgaDGPfdynrbxWqWS6sWmKbZoTjxLtVUibD"
|
||||||
@ -37,21 +37,21 @@ Content-Type: application/json
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"version": "2.0"
|
"version": "3.0"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"assets": [
|
"assets": [
|
||||||
{
|
{
|
||||||
"id": "61e1312b80705e0dabb948c9d78dae7f62d64832abda822b13d89c4a7305d4ac"
|
"id": "0fdeb547670bbea980389df53cf5a91e60159339084c6b0b5cc0b5494a679530"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": "e43d3f93d90d22ef11c21607e3415bfcda4e0c7dd60412fbb55daf32978a3126",
|
"id": "45c929b66d1b10db6c3c3e6b1adddc0778b473fced4a1f403c2646b25f3fd983",
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{
|
{
|
||||||
"fulfillment": "pGSAICw7Ul-c2lG6NFbHp3FbKRC7fivQcNGO7GS4wV3A-1QggUBjj_XTjB3yJdG8JMNKnkkHvcX_BTOkl-YacRD4yKqxUCeL-VTgbrLgi5a3gGxNJcTkZP1gF0nsby8cgV4xmOcB",
|
"fulfillment": "pGSAICw7Ul-c2lG6NFbHp3FbKRC7fivQcNGO7GS4wV3A-1QggUAc6OAQcXppDxCazw0UK2nwghctKNiZYDDsSOkAn0eQE8QjZ7GLzJpVb92oGXw_4FF7cLE0gg3nNxu7taQ8xakE",
|
||||||
"fulfills": {
|
"fulfills": {
|
||||||
"output_index": 0,
|
"output_index": 0,
|
||||||
"transaction_id": "b6e1ab3d48bbbbb0e40b952e70ec5d439b2745e0ba0c44b4ee877657e9ac33f0"
|
"transaction_id": "8d11fe2bd91c4747a41e0c3dbe1400c511175be42f008d6cff92cbfa9e04f799"
|
||||||
},
|
},
|
||||||
"owners_before": [
|
"owners_before": [
|
||||||
"3yfQPHeWAa1MxTX9Zf9176QqcpcnWcanVZZbaHb8B3h9"
|
"3yfQPHeWAa1MxTX9Zf9176QqcpcnWcanVZZbaHb8B3h9"
|
||||||
@ -75,5 +75,5 @@ Content-Type: application/json
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"version": "2.0"
|
"version": "3.0"
|
||||||
}]
|
}]
|
||||||
|
|||||||
@ -1,3 +1,3 @@
|
|||||||
GET /api/v1/transactions/61e1312b80705e0dabb948c9d78dae7f62d64832abda822b13d89c4a7305d4ac HTTP/1.1
|
GET /api/v1/transactions/0fdeb547670bbea980389df53cf5a91e60159339084c6b0b5cc0b5494a679530 HTTP/1.1
|
||||||
Host: example.com
|
Host: example.com
|
||||||
|
|
||||||
|
|||||||
@ -4,15 +4,13 @@ Content-Type: application/json
|
|||||||
{
|
{
|
||||||
"assets": [
|
"assets": [
|
||||||
{
|
{
|
||||||
"data": {
|
"data": "QmQP5C3PmhH9oB84n7YqSY4WVqmYatdoo1BdwhH4zmcwqM"
|
||||||
"msg": "Hello Planetmint!"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": "61e1312b80705e0dabb948c9d78dae7f62d64832abda822b13d89c4a7305d4ac",
|
"id": "0fdeb547670bbea980389df53cf5a91e60159339084c6b0b5cc0b5494a679530",
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{
|
{
|
||||||
"fulfillment": "pGSAIDE5i63cn4X8T8N1sZ2mGkJD5lNRnBM4PZgI_zvzbr-cgUCWcUaLa2U-nkmZ6oYj14aeV6B4TJH2NvZ8k2ZTwcGiaiCGXDQT2dEPfMCFwM8lwSousafCu4c7EgVZ1GzUDjsN",
|
"fulfillment": "pGSAIDE5i63cn4X8T8N1sZ2mGkJD5lNRnBM4PZgI_zvzbr-cgUDklzRb5aUQz9slbaqSWap1AfC-cacTCN3CGtFy2LPK7JKEqKG2b0KQXnUcFksk_KH_v6ImFXHsclKSp1OJkIEI",
|
||||||
"fulfills": null,
|
"fulfills": null,
|
||||||
"owners_before": [
|
"owners_before": [
|
||||||
"4K9sWUMFwTgaDGPfdynrbxWqWS6sWmKbZoTjxLtVUibD"
|
"4K9sWUMFwTgaDGPfdynrbxWqWS6sWmKbZoTjxLtVUibD"
|
||||||
@ -36,5 +34,5 @@ Content-Type: application/json
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"version": "2.0"
|
"version": "3.0"
|
||||||
}
|
}
|
||||||
|
|||||||
@ -6,7 +6,7 @@ Content-Type: application/json
|
|||||||
"v1": {
|
"v1": {
|
||||||
"assets": "/api/v1/assets/",
|
"assets": "/api/v1/assets/",
|
||||||
"blocks": "/api/v1/blocks/",
|
"blocks": "/api/v1/blocks/",
|
||||||
"docs": "https://docs.planetmint.io/projects/server/en/v1.2.2/http-client-server-api.html",
|
"docs": "https://docs.planetmint.io/projects/server/en/v1.4.1/http-client-server-api.html",
|
||||||
"metadata": "/api/v1/metadata/",
|
"metadata": "/api/v1/metadata/",
|
||||||
"outputs": "/api/v1/outputs/",
|
"outputs": "/api/v1/outputs/",
|
||||||
"streamedblocks": "ws://localhost:9985/api/v1/streams/valid_blocks",
|
"streamedblocks": "ws://localhost:9985/api/v1/streams/valid_blocks",
|
||||||
@ -15,7 +15,7 @@ Content-Type: application/json
|
|||||||
"validators": "/api/v1/validators"
|
"validators": "/api/v1/validators"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"docs": "https://docs.planetmint.io/projects/server/en/v1.2.2/",
|
"docs": "https://docs.planetmint.io/projects/server/en/v1.4.1/",
|
||||||
"software": "Planetmint",
|
"software": "Planetmint",
|
||||||
"version": "1.3.1"
|
"version": "1.4.1"
|
||||||
}
|
}
|
||||||
|
|||||||
@ -5,15 +5,13 @@ Content-Type: application/json
|
|||||||
{
|
{
|
||||||
"assets": [
|
"assets": [
|
||||||
{
|
{
|
||||||
"data": {
|
"data": "QmQP5C3PmhH9oB84n7YqSY4WVqmYatdoo1BdwhH4zmcwqM"
|
||||||
"msg": "Hello Planetmint!"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": "61e1312b80705e0dabb948c9d78dae7f62d64832abda822b13d89c4a7305d4ac",
|
"id": "0fdeb547670bbea980389df53cf5a91e60159339084c6b0b5cc0b5494a679530",
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{
|
{
|
||||||
"fulfillment": "pGSAIDE5i63cn4X8T8N1sZ2mGkJD5lNRnBM4PZgI_zvzbr-cgUCWcUaLa2U-nkmZ6oYj14aeV6B4TJH2NvZ8k2ZTwcGiaiCGXDQT2dEPfMCFwM8lwSousafCu4c7EgVZ1GzUDjsN",
|
"fulfillment": "pGSAIDE5i63cn4X8T8N1sZ2mGkJD5lNRnBM4PZgI_zvzbr-cgUDklzRb5aUQz9slbaqSWap1AfC-cacTCN3CGtFy2LPK7JKEqKG2b0KQXnUcFksk_KH_v6ImFXHsclKSp1OJkIEI",
|
||||||
"fulfills": null,
|
"fulfills": null,
|
||||||
"owners_before": [
|
"owners_before": [
|
||||||
"4K9sWUMFwTgaDGPfdynrbxWqWS6sWmKbZoTjxLtVUibD"
|
"4K9sWUMFwTgaDGPfdynrbxWqWS6sWmKbZoTjxLtVUibD"
|
||||||
@ -37,5 +35,5 @@ Content-Type: application/json
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"version": "2.0"
|
"version": "3.0"
|
||||||
}
|
}
|
||||||
|
|||||||
@ -4,15 +4,13 @@ Content-Type: application/json
|
|||||||
{
|
{
|
||||||
"assets": [
|
"assets": [
|
||||||
{
|
{
|
||||||
"data": {
|
"data": "QmQP5C3PmhH9oB84n7YqSY4WVqmYatdoo1BdwhH4zmcwqM"
|
||||||
"msg": "Hello Planetmint!"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"id": "61e1312b80705e0dabb948c9d78dae7f62d64832abda822b13d89c4a7305d4ac",
|
"id": "0fdeb547670bbea980389df53cf5a91e60159339084c6b0b5cc0b5494a679530",
|
||||||
"inputs": [
|
"inputs": [
|
||||||
{
|
{
|
||||||
"fulfillment": "pGSAIDE5i63cn4X8T8N1sZ2mGkJD5lNRnBM4PZgI_zvzbr-cgUCWcUaLa2U-nkmZ6oYj14aeV6B4TJH2NvZ8k2ZTwcGiaiCGXDQT2dEPfMCFwM8lwSousafCu4c7EgVZ1GzUDjsN",
|
"fulfillment": "pGSAIDE5i63cn4X8T8N1sZ2mGkJD5lNRnBM4PZgI_zvzbr-cgUDklzRb5aUQz9slbaqSWap1AfC-cacTCN3CGtFy2LPK7JKEqKG2b0KQXnUcFksk_KH_v6ImFXHsclKSp1OJkIEI",
|
||||||
"fulfills": null,
|
"fulfills": null,
|
||||||
"owners_before": [
|
"owners_before": [
|
||||||
"4K9sWUMFwTgaDGPfdynrbxWqWS6sWmKbZoTjxLtVUibD"
|
"4K9sWUMFwTgaDGPfdynrbxWqWS6sWmKbZoTjxLtVUibD"
|
||||||
@ -36,5 +34,5 @@ Content-Type: application/json
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"version": "2.0"
|
"version": "3.0"
|
||||||
}
|
}
|
||||||
|
|||||||
@ -3,14 +3,12 @@
|
|||||||
# SPDX-License-Identifier: (Apache-2.0 AND CC-BY-4.0)
|
# SPDX-License-Identifier: (Apache-2.0 AND CC-BY-4.0)
|
||||||
# Code is Apache-2.0 and docs are CC-BY-4.0
|
# Code is Apache-2.0 and docs are CC-BY-4.0
|
||||||
|
|
||||||
import tarantool
|
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
from itertools import repeat
|
from itertools import repeat
|
||||||
from importlib import import_module
|
from importlib import import_module
|
||||||
from transactions.common.exceptions import ConfigurationError
|
from transactions.common.exceptions import ConfigurationError
|
||||||
from planetmint.config import Config
|
from planetmint.config import Config
|
||||||
from planetmint.backend.exceptions import ConnectionError
|
|
||||||
|
|
||||||
BACKENDS = {
|
BACKENDS = {
|
||||||
"tarantool_db": "planetmint.backend.tarantool.connection.TarantoolDBConnection",
|
"tarantool_db": "planetmint.backend.tarantool.connection.TarantoolDBConnection",
|
||||||
@ -69,6 +67,7 @@ class DBConnection(metaclass=DBSingleton):
|
|||||||
**kwargs
|
**kwargs
|
||||||
):
|
):
|
||||||
"""Create a new :class:`~.Connection` instance.
|
"""Create a new :class:`~.Connection` instance.
|
||||||
|
|
||||||
Args:
|
Args:
|
||||||
host (str): the host to connect to.
|
host (str): the host to connect to.
|
||||||
port (int): the port to connect to.
|
port (int): the port to connect to.
|
||||||
|
|||||||
@ -27,7 +27,7 @@ def store_asset(asset: dict, connection):
|
|||||||
@singledispatch
|
@singledispatch
|
||||||
def store_assets(assets: list, connection):
|
def store_assets(assets: list, connection):
|
||||||
"""Write a list of assets to the assets table.
|
"""Write a list of assets to the assets table.
|
||||||
backend
|
|
||||||
Args:
|
Args:
|
||||||
assets (list): a list of assets to write.
|
assets (list): a list of assets to write.
|
||||||
|
|
||||||
@ -193,6 +193,7 @@ def get_metadata(connection, transaction_ids):
|
|||||||
@singledispatch
|
@singledispatch
|
||||||
def get_assets(connection, asset_ids) -> list:
|
def get_assets(connection, asset_ids) -> list:
|
||||||
"""Get a list of assets from the assets table.
|
"""Get a list of assets from the assets table.
|
||||||
|
|
||||||
Args:
|
Args:
|
||||||
asset_ids (list): a list of ids for the assets to be retrieved from
|
asset_ids (list): a list of ids for the assets to be retrieved from
|
||||||
the database.
|
the database.
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user