diff --git a/setup.cfg b/setup.cfg index 9c59e617..604a5d43 100644 --- a/setup.cfg +++ b/setup.cfg @@ -30,7 +30,7 @@ package_dir = # DON'T CHANGE THE FOLLOWING LINE! IT WILL BE UPDATED BY PYSCAFFOLD! setup_requires = pyscaffold>=3.2a0,<3.3a0 # Add here dependencies of your project (semicolon/line-separated), e.g. -install_requires = +install_requires = coincurve; python_version<"3.11" coincurve>=17.0.0; python_version>="3.11" # Technically, this should be >=18.0.0 but there is a conflict with eciespy aiohttp>=3.8.3 @@ -38,7 +38,7 @@ install_requires = eciespy>=0.3.13; python_version>="3.11" typing_extensions typer - aleph-message~=0.3.1 + aleph-message~=0.3.2 eth_account>=0.4.0 # Required to fix a dependency issue with parsimonious and Python3.11 eth_abi==4.0.0b2; python_version>="3.11" diff --git a/src/aleph/sdk/chains/nuls1.py b/src/aleph/sdk/chains/nuls1.py index 56e34d23..c5629fb7 100644 --- a/src/aleph/sdk/chains/nuls1.py +++ b/src/aleph/sdk/chains/nuls1.py @@ -275,6 +275,8 @@ def serialize(self, with_length=False): return output def verify(self, message): + if not self.pub_key: + raise ValueError("Missing public key ") pub = PublicKey(self.pub_key) message = VarInt(len(message)).encode() + message # LOGGER.debug("Comparing with %r" % (MESSAGE_TEMPLATE.format(message).encode())) diff --git a/src/aleph/sdk/conf.py b/src/aleph/sdk/conf.py index 6fcb9ae7..264c8c9f 100644 --- a/src/aleph/sdk/conf.py +++ b/src/aleph/sdk/conf.py @@ -24,7 +24,6 @@ class Settings(BaseSettings): REMOTE_CRYPTO_UNIX_SOCKET: Optional[str] = None ADDRESS_TO_USE: Optional[str] = None - DEFAULT_CHANNEL: str = "TEST" DEFAULT_RUNTIME_ID: str = ( "bd79839bf96e595a06da5ac0b6ba51dea6f7e2591bb913deccded04d831d29f4" ) @@ -34,9 +33,6 @@ class Settings(BaseSettings): CODE_USES_SQUASHFS: bool = which("mksquashfs") is not None # True if command exists - VM_URL_PATH = "https://aleph.sh/vm/{hash}" - VM_URL_HOST = "https://{hash_base32}.aleph.sh" - class Config: env_prefix = "ALEPH_" case_sensitive = False diff --git a/src/aleph/sdk/types.py b/src/aleph/sdk/types.py index b104c506..67c0dda3 100644 --- a/src/aleph/sdk/types.py +++ b/src/aleph/sdk/types.py @@ -2,7 +2,7 @@ from enum import Enum from typing import Dict, Protocol, TypeVar -__all__ = ("StorageEnum", "Account", "AccountFromPrivateKey") +__all__ = ("StorageEnum", "Account", "AccountFromPrivateKey", "GenericMessage") from aleph_message.models import AlephMessage