Skip to content

Commit

Permalink
bump version & docs update
Browse files Browse the repository at this point in the history
  • Loading branch information
popenta committed Nov 29, 2024
1 parent e53b49c commit acac0d8
Show file tree
Hide file tree
Showing 8 changed files with 82 additions and 5 deletions.
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
project = 'multiversx-sdk'
copyright = '2024, MultiversX'
author = 'MultiversX'
release = '0.11.0'
release = '0.19.0'

# -- General configuration ---------------------------------------------------
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration
Expand Down
16 changes: 16 additions & 0 deletions docs/multiversx_sdk.abi.rst
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,14 @@ multiversx\_sdk.abi.bytes\_value module
:undoc-members:
:show-inheritance:

multiversx\_sdk.abi.code\_metadata\_value module
------------------------------------------------

.. automodule:: multiversx_sdk.abi.code_metadata_value
:members:
:undoc-members:
:show-inheritance:

multiversx\_sdk.abi.codec module
--------------------------------

Expand All @@ -92,6 +100,14 @@ multiversx\_sdk.abi.enum\_value module
:undoc-members:
:show-inheritance:

multiversx\_sdk.abi.explicit\_enum\_value module
------------------------------------------------

.. automodule:: multiversx_sdk.abi.explicit_enum_value
:members:
:undoc-members:
:show-inheritance:

multiversx\_sdk.abi.fields module
---------------------------------

Expand Down
8 changes: 8 additions & 0 deletions docs/multiversx_sdk.core.rst
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,14 @@ multiversx\_sdk.core.codec module
:undoc-members:
:show-inheritance:

multiversx\_sdk.core.config module
----------------------------------

.. automodule:: multiversx_sdk.core.config
:members:
:undoc-members:
:show-inheritance:

multiversx\_sdk.core.contract\_query module
-------------------------------------------

Expand Down
8 changes: 8 additions & 0 deletions docs/multiversx_sdk.network_providers.rst
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,14 @@ multiversx\_sdk.network\_providers.transactions module
:undoc-members:
:show-inheritance:

multiversx\_sdk.network\_providers.user\_agent module
-----------------------------------------------------

.. automodule:: multiversx_sdk.network_providers.user_agent
:members:
:undoc-members:
:show-inheritance:

multiversx\_sdk.network\_providers.utils module
-----------------------------------------------

Expand Down
43 changes: 42 additions & 1 deletion examples/Cookbook.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,47 @@
"print(\"Is contract:\", address.is_smart_contract())"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"### Changing the default hrp\n",
"\n",
"We have a configuration class, called `LibraryConfig`, that only stores the **default hrp** of the addresses. The default value is `erd`. The hrp can be changed when instantiating an address, or it can be changed in the `LibraryConfig` class, and all the addresses created will have the newly set hrp. "
]
},
{
"cell_type": "code",
"execution_count": 2,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"erd\n",
"erd1qyu5wthldzr8wx5c9ucg8kjagg0jfs53s8nr3zpz3hypefsdd8ssycr6th\n",
"test1qyu5wthldzr8wx5c9ucg8kjagg0jfs53s8nr3zpz3hypefsdd8ss5hqhtr\n"
]
}
],
"source": [
"from multiversx_sdk import Address\n",
"from multiversx_sdk import LibraryConfig\n",
"\n",
"\n",
"print(LibraryConfig.default_address_hrp)\n",
"address = Address.new_from_hex(\"0139472eff6886771a982f3083da5d421f24c29181e63888228dc81ca60d69e1\")\n",
"print(address.to_bech32())\n",
"\n",
"LibraryConfig.default_address_hrp = \"test\"\n",
"address = Address.new_from_hex(\"0139472eff6886771a982f3083da5d421f24c29181e63888228dc81ca60d69e1\")\n",
"print(address.to_bech32())\n",
"\n",
"# setting back the default value\n",
"LibraryConfig.default_address_hrp = \"erd\""
]
},
{
"cell_type": "markdown",
"metadata": {},
Expand Down Expand Up @@ -2249,7 +2290,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.4"
"version": "3.12.3"
},
"orig_nbformat": 4,
"vscode": {
Expand Down
4 changes: 3 additions & 1 deletion multiversx_sdk/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
from multiversx_sdk.core.address import (Address, AddressComputer,
AddressFactory)
from multiversx_sdk.core.code_metadata import CodeMetadata
from multiversx_sdk.core.config import LibraryConfig
from multiversx_sdk.core.contract_query import ContractQuery
from multiversx_sdk.core.contract_query_builder import ContractQueryBuilder
from multiversx_sdk.core.message import Message, MessageComputer
Expand Down Expand Up @@ -84,5 +85,6 @@
"UserWallet", "UserPEM", "QueryRunnerAdapter", "TransactionsConverter", "DelegationTransactionsOutcomeParser",
"find_events_by_identifier", "find_events_by_first_topic", "SmartContractTransactionsOutcomeParser", "TransactionAwaiter",
"SmartContractQueriesController", "SmartContractQuery", "SmartContractQueryResponse",
"TransactionDecoder", "TransactionMetadata", "TransactionEventsParser", "NetworkProviderConfig"
"TransactionDecoder", "TransactionMetadata", "TransactionEventsParser", "NetworkProviderConfig",
"LibraryConfig"
]
4 changes: 3 additions & 1 deletion multiversx_sdk/core/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
from multiversx_sdk.core.address import (Address, AddressComputer,
AddressFactory)
from multiversx_sdk.core.code_metadata import CodeMetadata
from multiversx_sdk.core.config import LibraryConfig
from multiversx_sdk.core.contract_query import ContractQuery
from multiversx_sdk.core.contract_query_builder import ContractQueryBuilder
from multiversx_sdk.core.message import Message, MessageComputer
Expand Down Expand Up @@ -54,5 +55,6 @@
"SmartContractTransactionsFactory", "TransferTransactionsFactory",
"RelayedTransactionsFactory", "AccountTransactionsFactory", "DelegationTransactionsOutcomeParser",
"find_events_by_identifier", "find_events_by_first_topic", "SmartContractTransactionsOutcomeParser",
"SmartContractQueriesController", "SmartContractQuery", "SmartContractQueryResponse", "TransactionEventsParser"
"SmartContractQueriesController", "SmartContractQuery", "SmartContractQueryResponse", "TransactionEventsParser",
"LibraryConfig"
]
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ allow-direct-references = true

[project]
name = "multiversx-sdk"
version = "0.18.0"
version = "0.19.0"
authors = [
{ name="MultiversX" },
]
Expand Down

0 comments on commit acac0d8

Please sign in to comment.