From e46f0e2444d0408ce4647abbb02a8f4746e22da2 Mon Sep 17 00:00:00 2001 From: Victor Shyba <victor1984@riseup.net> Date: Mon, 17 Sep 2018 17:31:44 -0300 Subject: [PATCH] fix namespace lbryschema->lbrynet.schema --- lbrynet/core/system_info.py | 4 +-- lbrynet/core/utils.py | 2 +- lbrynet/daemon/Components.py | 4 +-- lbrynet/daemon/Daemon.py | 18 +++++----- lbrynet/daemon/Downloader.py | 2 +- lbrynet/database/migrator/migrate5to6.py | 2 +- lbrynet/database/storage.py | 4 +-- lbrynet/schema/address.py | 18 +++++----- lbrynet/schema/base.py | 6 ++-- lbrynet/schema/claim.py | 20 +++++------ lbrynet/schema/decode.py | 6 ++-- lbrynet/schema/encoding.py | 8 ++--- lbrynet/schema/fee.py | 8 ++--- lbrynet/schema/legacy/migrate.py | 4 +-- lbrynet/schema/proto/certificate_pb2.py | 8 ++--- lbrynet/schema/proto/claim.proto | 6 ++-- lbrynet/schema/proto/claim_pb2.py | 22 ++++++------ lbrynet/schema/proto/fee_pb2.py | 8 ++--- lbrynet/schema/proto/metadata.proto | 2 +- lbrynet/schema/proto/metadata_pb2.py | 14 ++++---- lbrynet/schema/proto/signature.proto | 2 +- lbrynet/schema/proto/signature_pb2.py | 14 ++++---- lbrynet/schema/proto/source_pb2.py | 8 ++--- lbrynet/schema/proto/stream.proto | 4 +-- lbrynet/schema/proto/stream_pb2.py | 18 +++++----- lbrynet/schema/schema/certificate.py | 8 ++--- lbrynet/schema/schema/claim.py | 12 +++---- lbrynet/schema/schema/fee.py | 6 ++-- lbrynet/schema/schema/metadata.py | 8 ++--- lbrynet/schema/schema/signature.py | 6 ++-- lbrynet/schema/schema/source.py | 8 ++--- lbrynet/schema/schema/stream.py | 10 +++--- lbrynet/schema/signer.py | 14 ++++---- lbrynet/schema/uri.py | 2 +- lbrynet/schema/validator.py | 4 +-- lbrynet/wallet/account.py | 4 +-- lbrynet/wallet/ledger.py | 4 +-- lbrynet/wallet/manager.py | 2 +- lbrynet/wallet/resolve.py | 12 +++---- lbrynet/wallet/transaction.py | 4 +-- tests/integration/wallet/test_commands.py | 4 +-- tests/integration/wallet/test_transactions.py | 6 ++-- tests/unit/core/test_Wallet.py | 2 +- tests/unit/lbrynet_daemon/test_Daemon.py | 2 +- .../test_ExchangeRateManager.py | 2 +- tests/unit/schema/test_lbryschema.py | 36 +++++++++---------- tests/unit/wallet/test_claim_proofs.py | 2 +- 47 files changed, 185 insertions(+), 185 deletions(-) diff --git a/lbrynet/core/system_info.py b/lbrynet/core/system_info.py index 6209b78b9..bcc645d81 100644 --- a/lbrynet/core/system_info.py +++ b/lbrynet/core/system_info.py @@ -5,7 +5,7 @@ import os from six.moves.urllib import request from six.moves.urllib.error import URLError -from lbryschema import __version__ as lbryschema_version +from lbrynet.schema import __version__ as schema_version from lbrynet import build_type, __version__ as lbrynet_version from lbrynet.conf import ROOT_DIR import logging.handlers @@ -35,7 +35,7 @@ def get_platform(get_ip: bool = True) -> dict: "os_release": platform.release(), "os_system": platform.system(), "lbrynet_version": get_lbrynet_version(), - "lbryschema_version": lbryschema_version, + "lbryschema_version": schema_version, "build": build_type.BUILD, # CI server sets this during build step } if p["os_system"] == "Linux": diff --git a/lbrynet/core/utils.py b/lbrynet/core/utils.py index db4f430d2..4e9f8e9ab 100644 --- a/lbrynet/core/utils.py +++ b/lbrynet/core/utils.py @@ -11,7 +11,7 @@ import logging import pkg_resources from twisted.python.failure import Failure from twisted.internet import defer -from lbryschema.claim import ClaimDict +from lbrynet.schema.claim import ClaimDict from lbrynet.core.cryptoutils import get_lbry_hash_obj log = logging.getLogger(__name__) diff --git a/lbrynet/daemon/Components.py b/lbrynet/daemon/Components.py index f5e16a919..d3fbd7b0c 100644 --- a/lbrynet/daemon/Components.py +++ b/lbrynet/daemon/Components.py @@ -7,7 +7,7 @@ import binascii from hashlib import sha256 from types import SimpleNamespace from twisted.internet import defer, threads, reactor, error, task -import lbryschema +import lbrynet.schema from aioupnp import __version__ as aioupnp_version from aioupnp.upnp import UPnP from aioupnp.fault import UPnPError @@ -353,7 +353,7 @@ class WalletComponent(Component): conf.settings.ensure_wallet_dir() log.info("Starting torba wallet") storage = self.component_manager.get_component(DATABASE_COMPONENT) - lbryschema.BLOCKCHAIN_NAME = conf.settings['blockchain_name'] + lbrynet.schema.BLOCKCHAIN_NAME = conf.settings['blockchain_name'] self.wallet_manager = yield f2d(LbryWalletManager.from_lbrynet_config(conf.settings, storage)) self.wallet_manager.old_db = storage yield f2d(self.wallet_manager.start()) diff --git a/lbrynet/daemon/Daemon.py b/lbrynet/daemon/Daemon.py index 1b4953526..b9bbce012 100644 --- a/lbrynet/daemon/Daemon.py +++ b/lbrynet/daemon/Daemon.py @@ -17,12 +17,12 @@ from twisted.python.failure import Failure from torba.client.constants import COIN from torba.client.baseaccount import SingleKey, HierarchicalDeterministic -from lbryschema.claim import ClaimDict -from lbryschema.uri import parse_lbry_uri -from lbryschema.error import URIParseError, DecodeError -from lbryschema.validator import validate_claim_id -from lbryschema.address import decode_address -from lbryschema.decode import smart_decode +from lbrynet.schema.claim import ClaimDict +from lbrynet.schema.uri import parse_lbry_uri +from lbrynet.schema.error import URIParseError, DecodeError +from lbrynet.schema.validator import validate_claim_id +from lbrynet.schema.address import decode_address +from lbrynet.schema.decode import smart_decode # TODO: importing this when internet is disabled raises a socket.gaierror from lbrynet.core.system_info import get_lbrynet_version @@ -820,7 +820,7 @@ class Daemon(AuthJSONRPCServer): 'ip': (str) remote ip, if available, 'lbrynet_version': (str) lbrynet_version, 'lbryum_version': (str) lbryum_version, - 'lbryschema_version': (str) lbryschema_version, + 'lbrynet.schema_version': (str) lbrynet.schema_version, 'os_release': (str) os release string 'os_system': (str) os name 'platform': (str) platform string @@ -2271,7 +2271,7 @@ class Daemon(AuthJSONRPCServer): } } - # this will be used to verify the format with lbryschema + # this will be used to verify the format with lbrynet.schema claim_copy = deepcopy(claim_dict) if sources is not None: claim_dict['stream']['source'] = sources @@ -2292,7 +2292,7 @@ class Daemon(AuthJSONRPCServer): raise Exception("no source provided to publish") try: ClaimDict.load_dict(claim_copy) - # the metadata to use in the claim can be serialized by lbryschema + # the metadata to use in the claim can be serialized by lbrynet.schema except DecodeError as err: # there was a problem with a metadata field, raise an error here rather than # waiting to find out when we go to publish the claim (after having made the stream) diff --git a/lbrynet/daemon/Downloader.py b/lbrynet/daemon/Downloader.py index f9b6b38d9..622701327 100644 --- a/lbrynet/daemon/Downloader.py +++ b/lbrynet/daemon/Downloader.py @@ -4,7 +4,7 @@ from twisted.internet import defer from twisted.internet.task import LoopingCall from lbrynet.daemon.Components import f2d -from lbryschema.fee import Fee +from lbrynet.schema.fee import Fee from lbrynet.core.Error import InsufficientFundsError, KeyFeeAboveMaxAllowed, InvalidStreamDescriptorError from lbrynet.core.Error import DownloadDataTimeout, DownloadCanceledError, DownloadSDTimeout diff --git a/lbrynet/database/migrator/migrate5to6.py b/lbrynet/database/migrator/migrate5to6.py index ca03d3fc8..017aa965f 100644 --- a/lbrynet/database/migrator/migrate5to6.py +++ b/lbrynet/database/migrator/migrate5to6.py @@ -2,7 +2,7 @@ import sqlite3 import os import json import logging -from lbryschema.decode import smart_decode +from lbrynet.schema.decode import smart_decode from lbrynet import conf log = logging.getLogger(__name__) diff --git a/lbrynet/database/storage.py b/lbrynet/database/storage.py index 4e931238a..da9fae7b0 100644 --- a/lbrynet/database/storage.py +++ b/lbrynet/database/storage.py @@ -7,8 +7,8 @@ from decimal import Decimal from twisted.internet import defer, task, threads from twisted.enterprise import adbapi -from lbryschema.claim import ClaimDict -from lbryschema.decode import smart_decode +from lbrynet.schema.claim import ClaimDict +from lbrynet.schema.decode import smart_decode from lbrynet import conf from lbrynet.cryptstream.CryptBlob import CryptBlobInfo from lbrynet.dht.constants import dataExpireTimeout diff --git a/lbrynet/schema/address.py b/lbrynet/schema/address.py index 4b92ab2ca..35c31588d 100644 --- a/lbrynet/schema/address.py +++ b/lbrynet/schema/address.py @@ -1,9 +1,9 @@ import six -import lbryschema -from lbryschema.base import b58encode, b58decode, validate_b58_checksum -from lbryschema.hashing import double_sha256, hash160 -from lbryschema.error import InvalidAddress -from lbryschema.schema import ADDRESS_LENGTH, ADDRESS_PREFIXES, PUBKEY_ADDRESS, SCRIPT_ADDRESS +import lbrynet.schema +from lbrynet.schema.base import b58encode, b58decode, validate_b58_checksum +from lbrynet.schema.hashing import double_sha256, hash160 +from lbrynet.schema.error import InvalidAddress +from lbrynet.schema.schema import ADDRESS_LENGTH, ADDRESS_PREFIXES, PUBKEY_ADDRESS, SCRIPT_ADDRESS def validate_address_length(addr_bytes): @@ -16,7 +16,7 @@ def validate_address_prefix(addr_bytes): prefix = addr_bytes[0] else: prefix = ord(addr_bytes[0]) - if prefix not in ADDRESS_PREFIXES[lbryschema.BLOCKCHAIN_NAME].values(): + if prefix not in ADDRESS_PREFIXES[lbrynet.schema.BLOCKCHAIN_NAME].values(): raise InvalidAddress("Invalid address prefix: %.2X" % prefix) @@ -40,9 +40,9 @@ def encode_address(addr_bytes): def hash_160_bytes_to_address(h160, addrtype=PUBKEY_ADDRESS): if addrtype == PUBKEY_ADDRESS: - prefix = chr(ADDRESS_PREFIXES[lbryschema.BLOCKCHAIN_NAME][PUBKEY_ADDRESS]) + prefix = chr(ADDRESS_PREFIXES[lbrynet.schema.BLOCKCHAIN_NAME][PUBKEY_ADDRESS]) elif addrtype == SCRIPT_ADDRESS: - prefix = chr(ADDRESS_PREFIXES[lbryschema.BLOCKCHAIN_NAME][SCRIPT_ADDRESS]) + prefix = chr(ADDRESS_PREFIXES[lbrynet.schema.BLOCKCHAIN_NAME][SCRIPT_ADDRESS]) else: raise Exception("Invalid address prefix") return b58encode(prefix + h160 + double_sha256(prefix + h160)[0:4]) @@ -55,7 +55,7 @@ def public_key_to_address(public_key): def address_to_hash_160(addr): bytes = decode_address(addr) prefix, pubkey_bytes, addr_checksum = bytes[0], bytes[1:21], bytes[21:] - if prefix == chr(ADDRESS_PREFIXES[lbryschema.BLOCKCHAIN_NAME][PUBKEY_ADDRESS]): + if prefix == chr(ADDRESS_PREFIXES[lbrynet.schema.BLOCKCHAIN_NAME][PUBKEY_ADDRESS]): return PUBKEY_ADDRESS, pubkey_bytes return SCRIPT_ADDRESS, pubkey_bytes diff --git a/lbrynet/schema/base.py b/lbrynet/schema/base.py index aa4745d77..3bdbd5df1 100644 --- a/lbrynet/schema/base.py +++ b/lbrynet/schema/base.py @@ -1,7 +1,7 @@ import six -from lbryschema.schema import ADDRESS_CHECKSUM_LENGTH -from lbryschema.hashing import double_sha256 -from lbryschema.error import InvalidAddress +from lbrynet.schema.schema import ADDRESS_CHECKSUM_LENGTH +from lbrynet.schema.hashing import double_sha256 +from lbrynet.schema.error import InvalidAddress alphabet = b'123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz' diff --git a/lbrynet/schema/claim.py b/lbrynet/schema/claim.py index 22027a7b7..25215543b 100644 --- a/lbrynet/schema/claim.py +++ b/lbrynet/schema/claim.py @@ -5,14 +5,14 @@ from google.protobuf.message import DecodeError as DecodeError_pb # pylint: dis from collections import OrderedDict -from lbryschema.schema.claim import Claim -from lbryschema.proto import claim_pb2 -from lbryschema.validator import get_validator -from lbryschema.signer import get_signer -from lbryschema.schema import NIST256p, CURVE_NAMES, CLAIM_TYPE_NAMES -from lbryschema.encoding import decode_fields, decode_b64_fields, encode_fields -from lbryschema.error import DecodeError -from lbryschema.fee import Fee +from lbrynet.schema.schema.claim import Claim +from lbrynet.schema.proto import claim_pb2 +from lbrynet.schema.validator import get_validator +from lbrynet.schema.signer import get_signer +from lbrynet.schema.schema import NIST256p, CURVE_NAMES, CLAIM_TYPE_NAMES +from lbrynet.schema.encoding import decode_fields, decode_b64_fields, encode_fields +from lbrynet.schema.error import DecodeError +from lbrynet.schema.fee import Fee class ClaimDict(OrderedDict): @@ -180,10 +180,10 @@ class ClaimDict(OrderedDict): def get_validator(self, certificate_id): """ - Get a lbryschema.validator.Validator object for a certificate claim + Get a lbrynet.schema.validator.Validator object for a certificate claim :param certificate_id: claim id of this certificate claim - :return: None or lbryschema.validator.Validator object + :return: None or lbrynet.schema.validator.Validator object """ claim = self.protobuf diff --git a/lbrynet/schema/decode.py b/lbrynet/schema/decode.py index 62db08ecc..95aa18a5b 100644 --- a/lbrynet/schema/decode.py +++ b/lbrynet/schema/decode.py @@ -3,9 +3,9 @@ import binascii import six -from lbryschema.error import DecodeError, InvalidAddress -from lbryschema.legacy.migrate import migrate as schema_migrator -from lbryschema.claim import ClaimDict +from lbrynet.schema.error import DecodeError, InvalidAddress +from lbrynet.schema.legacy.migrate import migrate as schema_migrator +from lbrynet.schema.claim import ClaimDict from google.protobuf import json_format # pylint: disable=no-name-in-module diff --git a/lbrynet/schema/encoding.py b/lbrynet/schema/encoding.py index 8090f5780..9d8aea4a4 100644 --- a/lbrynet/schema/encoding.py +++ b/lbrynet/schema/encoding.py @@ -1,9 +1,9 @@ import base64, binascii from copy import deepcopy -from lbryschema.address import decode_address, encode_address -from lbryschema.schema import CLAIM_TYPES, CLAIM_TYPE, STREAM_TYPE, CERTIFICATE_TYPE -from lbryschema.schema import SIGNATURE -from lbryschema.error import DecodeError, InvalidAddress +from lbrynet.schema.address import decode_address, encode_address +from lbrynet.schema.schema import CLAIM_TYPES, CLAIM_TYPE, STREAM_TYPE, CERTIFICATE_TYPE +from lbrynet.schema.schema import SIGNATURE +from lbrynet.schema.error import DecodeError, InvalidAddress def encode_fields(claim_dictionary): diff --git a/lbrynet/schema/fee.py b/lbrynet/schema/fee.py index d327d5441..4c3bb3447 100644 --- a/lbrynet/schema/fee.py +++ b/lbrynet/schema/fee.py @@ -1,9 +1,9 @@ from collections import OrderedDict -from lbryschema.address import encode_address, decode_address -from lbryschema.schema import CURRENCY_NAMES, CURRENCY_MAP -from lbryschema.schema.fee import Fee as FeeHelper -from lbryschema.proto import fee_pb2 +from lbrynet.schema.address import encode_address, decode_address +from lbrynet.schema.schema import CURRENCY_NAMES, CURRENCY_MAP +from lbrynet.schema.schema.fee import Fee as FeeHelper +from lbrynet.schema.proto import fee_pb2 def migrate(fee): diff --git a/lbrynet/schema/legacy/migrate.py b/lbrynet/schema/legacy/migrate.py index 006947a2d..3b515c5be 100644 --- a/lbrynet/schema/legacy/migrate.py +++ b/lbrynet/schema/legacy/migrate.py @@ -2,8 +2,8 @@ migrate claim json schema (0.0.1-3) to protobuf (0.1.0) """ -from lbryschema.legacy import metadata_schemas -from lbryschema.claim import ClaimDict +from lbrynet.schema.legacy import metadata_schemas +from lbrynet.schema.claim import ClaimDict from .StructuredDict import StructuredDict diff --git a/lbrynet/schema/proto/certificate_pb2.py b/lbrynet/schema/proto/certificate_pb2.py index c9dc6c79f..644991c7a 100644 --- a/lbrynet/schema/proto/certificate_pb2.py +++ b/lbrynet/schema/proto/certificate_pb2.py @@ -1,5 +1,5 @@ # Generated by the protocol buffer compiler. DO NOT EDIT! -# source: lbryschema/proto/certificate.proto +# source: lbrynet.schema/proto/certificate.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) @@ -17,9 +17,9 @@ _sym_db = _symbol_database.Default() DESCRIPTOR = _descriptor.FileDescriptor( - name='lbryschema/proto/certificate.proto', + name='lbrynet.schema/proto/certificate.proto', package='', - serialized_pb=_b('\n\"lbryschema/proto/certificate.proto\"\x8e\x01\n\x0b\x43\x65rtificate\x12%\n\x07version\x18\x01 \x02(\x0e\x32\x14.Certificate.Version\x12\x19\n\x07keyType\x18\x02 \x02(\x0e\x32\x08.KeyType\x12\x11\n\tpublicKey\x18\x04 \x02(\x0c\"*\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01*Q\n\x07KeyType\x12\x1b\n\x17UNKNOWN_PUBLIC_KEY_TYPE\x10\x00\x12\x0c\n\x08NIST256p\x10\x01\x12\x0c\n\x08NIST384p\x10\x02\x12\r\n\tSECP256k1\x10\x03') + serialized_pb=_b('\n\"lbrynet.schema/proto/certificate.proto\"\x8e\x01\n\x0b\x43\x65rtificate\x12%\n\x07version\x18\x01 \x02(\x0e\x32\x14.Certificate.Version\x12\x19\n\x07keyType\x18\x02 \x02(\x0e\x32\x08.KeyType\x12\x11\n\tpublicKey\x18\x04 \x02(\x0c\"*\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01*Q\n\x07KeyType\x12\x1b\n\x17UNKNOWN_PUBLIC_KEY_TYPE\x10\x00\x12\x0c\n\x08NIST256p\x10\x01\x12\x0c\n\x08NIST384p\x10\x02\x12\r\n\tSECP256k1\x10\x03') ) _sym_db.RegisterFileDescriptor(DESCRIPTOR) @@ -135,7 +135,7 @@ DESCRIPTOR.enum_types_by_name['KeyType'] = _KEYTYPE Certificate = _reflection.GeneratedProtocolMessageType('Certificate', (_message.Message,), dict( DESCRIPTOR = _CERTIFICATE, - __module__ = 'lbryschema.proto.certificate_pb2' + __module__ = 'lbrynet.schema.proto.certificate_pb2' # @@protoc_insertion_point(class_scope:Certificate) )) _sym_db.RegisterMessage(Certificate) diff --git a/lbrynet/schema/proto/claim.proto b/lbrynet/schema/proto/claim.proto index 5557a30f6..6467e91be 100644 --- a/lbrynet/schema/proto/claim.proto +++ b/lbrynet/schema/proto/claim.proto @@ -1,8 +1,8 @@ syntax = "proto2"; -import "lbryschema/proto/stream.proto"; -import "lbryschema/proto/certificate.proto"; -import "lbryschema/proto/signature.proto"; +import "lbrynet.schema/proto/stream.proto"; +import "lbrynet.schema/proto/certificate.proto"; +import "lbrynet.schema/proto/signature.proto"; message Claim { enum Version { diff --git a/lbrynet/schema/proto/claim_pb2.py b/lbrynet/schema/proto/claim_pb2.py index 457bd17d5..703912184 100644 --- a/lbrynet/schema/proto/claim_pb2.py +++ b/lbrynet/schema/proto/claim_pb2.py @@ -1,5 +1,5 @@ # Generated by the protocol buffer compiler. DO NOT EDIT! -# source: lbryschema/proto/claim.proto +# source: lbrynet.schema/proto/claim.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) @@ -13,17 +13,17 @@ from google.protobuf import descriptor_pb2 _sym_db = _symbol_database.Default() -import lbryschema.proto.stream_pb2 -import lbryschema.proto.certificate_pb2 -import lbryschema.proto.signature_pb2 +import lbrynet.schema.proto.stream_pb2 +import lbrynet.schema.proto.certificate_pb2 +import lbrynet.schema.proto.signature_pb2 DESCRIPTOR = _descriptor.FileDescriptor( - name='lbryschema/proto/claim.proto', + name='lbrynet.schema/proto/claim.proto', package='', - serialized_pb=_b('\n\x1clbryschema/proto/claim.proto\x1a\x1dlbryschema/proto/stream.proto\x1a\"lbryschema/proto/certificate.proto\x1a lbryschema/proto/signature.proto\"\xa7\x02\n\x05\x43laim\x12\x1f\n\x07version\x18\x01 \x02(\x0e\x32\x0e.Claim.Version\x12#\n\tclaimType\x18\x02 \x02(\x0e\x32\x10.Claim.ClaimType\x12\x17\n\x06stream\x18\x03 \x01(\x0b\x32\x07.Stream\x12!\n\x0b\x63\x65rtificate\x18\x04 \x01(\x0b\x32\x0c.Certificate\x12&\n\x12publisherSignature\x18\x05 \x01(\x0b\x32\n.Signature\"*\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01\"H\n\tClaimType\x12\x16\n\x12UNKNOWN_CLAIM_TYPE\x10\x00\x12\x0e\n\nstreamType\x10\x01\x12\x13\n\x0f\x63\x65rtificateType\x10\x02') + serialized_pb=_b('\n\x1clbrynet.schema/proto/claim.proto\x1a\x1dlbrynet.schema/proto/stream.proto\x1a\"lbrynet.schema/proto/certificate.proto\x1a lbrynet.schema/proto/signature.proto\"\xa7\x02\n\x05\x43laim\x12\x1f\n\x07version\x18\x01 \x02(\x0e\x32\x0e.Claim.Version\x12#\n\tclaimType\x18\x02 \x02(\x0e\x32\x10.Claim.ClaimType\x12\x17\n\x06stream\x18\x03 \x01(\x0b\x32\x07.Stream\x12!\n\x0b\x63\x65rtificate\x18\x04 \x01(\x0b\x32\x0c.Certificate\x12&\n\x12publisherSignature\x18\x05 \x01(\x0b\x32\n.Signature\"*\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01\"H\n\tClaimType\x12\x16\n\x12UNKNOWN_CLAIM_TYPE\x10\x00\x12\x0e\n\nstreamType\x10\x01\x12\x13\n\x0f\x63\x65rtificateType\x10\x02') , - dependencies=[lbryschema.proto.stream_pb2.DESCRIPTOR,lbryschema.proto.certificate_pb2.DESCRIPTOR,lbryschema.proto.signature_pb2.DESCRIPTOR,]) + dependencies=[lbrynet.schema.proto.stream_pb2.DESCRIPTOR,lbrynet.schema.proto.certificate_pb2.DESCRIPTOR,lbrynet.schema.proto.signature_pb2.DESCRIPTOR,]) _sym_db.RegisterFileDescriptor(DESCRIPTOR) @@ -138,16 +138,16 @@ _CLAIM = _descriptor.Descriptor( _CLAIM.fields_by_name['version'].enum_type = _CLAIM_VERSION _CLAIM.fields_by_name['claimType'].enum_type = _CLAIM_CLAIMTYPE -_CLAIM.fields_by_name['stream'].message_type = lbryschema.proto.stream_pb2._STREAM -_CLAIM.fields_by_name['certificate'].message_type = lbryschema.proto.certificate_pb2._CERTIFICATE -_CLAIM.fields_by_name['publisherSignature'].message_type = lbryschema.proto.signature_pb2._SIGNATURE +_CLAIM.fields_by_name['stream'].message_type = lbrynet.schema.proto.stream_pb2._STREAM +_CLAIM.fields_by_name['certificate'].message_type = lbrynet.schema.proto.certificate_pb2._CERTIFICATE +_CLAIM.fields_by_name['publisherSignature'].message_type = lbrynet.schema.proto.signature_pb2._SIGNATURE _CLAIM_VERSION.containing_type = _CLAIM _CLAIM_CLAIMTYPE.containing_type = _CLAIM DESCRIPTOR.message_types_by_name['Claim'] = _CLAIM Claim = _reflection.GeneratedProtocolMessageType('Claim', (_message.Message,), dict( DESCRIPTOR = _CLAIM, - __module__ = 'lbryschema.proto.claim_pb2' + __module__ = 'lbrynet.schema.proto.claim_pb2' # @@protoc_insertion_point(class_scope:Claim) )) _sym_db.RegisterMessage(Claim) diff --git a/lbrynet/schema/proto/fee_pb2.py b/lbrynet/schema/proto/fee_pb2.py index 55493f761..8316878dc 100644 --- a/lbrynet/schema/proto/fee_pb2.py +++ b/lbrynet/schema/proto/fee_pb2.py @@ -1,5 +1,5 @@ # Generated by the protocol buffer compiler. DO NOT EDIT! -# source: lbryschema/proto/fee.proto +# source: lbrynet.schema/proto/fee.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) @@ -16,9 +16,9 @@ _sym_db = _symbol_database.Default() DESCRIPTOR = _descriptor.FileDescriptor( - name='lbryschema/proto/fee.proto', + name='lbrynet.schema/proto/fee.proto', package='', - serialized_pb=_b('\n\x1albryschema/proto/fee.proto\"\xcf\x01\n\x03\x46\x65\x65\x12\x1d\n\x07version\x18\x01 \x02(\x0e\x32\x0c.Fee.Version\x12\x1f\n\x08\x63urrency\x18\x02 \x02(\x0e\x32\r.Fee.Currency\x12\x0f\n\x07\x61\x64\x64ress\x18\x03 \x02(\x0c\x12\x0e\n\x06\x61mount\x18\x04 \x02(\x02\"*\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01\";\n\x08\x43urrency\x12\x14\n\x10UNKNOWN_CURRENCY\x10\x00\x12\x07\n\x03LBC\x10\x01\x12\x07\n\x03\x42TC\x10\x02\x12\x07\n\x03USD\x10\x03') + serialized_pb=_b('\n\x1albrynet.schema/proto/fee.proto\"\xcf\x01\n\x03\x46\x65\x65\x12\x1d\n\x07version\x18\x01 \x02(\x0e\x32\x0c.Fee.Version\x12\x1f\n\x08\x63urrency\x18\x02 \x02(\x0e\x32\r.Fee.Currency\x12\x0f\n\x07\x61\x64\x64ress\x18\x03 \x02(\x0c\x12\x0e\n\x06\x61mount\x18\x04 \x02(\x02\"*\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01\";\n\x08\x43urrency\x12\x14\n\x10UNKNOWN_CURRENCY\x10\x00\x12\x07\n\x03LBC\x10\x01\x12\x07\n\x03\x42TC\x10\x02\x12\x07\n\x03USD\x10\x03') ) _sym_db.RegisterFileDescriptor(DESCRIPTOR) @@ -137,7 +137,7 @@ DESCRIPTOR.message_types_by_name['Fee'] = _FEE Fee = _reflection.GeneratedProtocolMessageType('Fee', (_message.Message,), dict( DESCRIPTOR = _FEE, - __module__ = 'lbryschema.proto.fee_pb2' + __module__ = 'lbrynet.schema.proto.fee_pb2' # @@protoc_insertion_point(class_scope:Fee) )) _sym_db.RegisterMessage(Fee) diff --git a/lbrynet/schema/proto/metadata.proto b/lbrynet/schema/proto/metadata.proto index a9485485a..69026c877 100644 --- a/lbrynet/schema/proto/metadata.proto +++ b/lbrynet/schema/proto/metadata.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lbryschema/proto/fee.proto"; +import "lbrynet.schema/proto/fee.proto"; message Metadata { enum Version { diff --git a/lbrynet/schema/proto/metadata_pb2.py b/lbrynet/schema/proto/metadata_pb2.py index 4f000c757..d3bd10778 100644 --- a/lbrynet/schema/proto/metadata_pb2.py +++ b/lbrynet/schema/proto/metadata_pb2.py @@ -1,5 +1,5 @@ # Generated by the protocol buffer compiler. DO NOT EDIT! -# source: lbryschema/proto/metadata.proto +# source: lbrynet.schema/proto/metadata.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) @@ -13,15 +13,15 @@ from google.protobuf import descriptor_pb2 _sym_db = _symbol_database.Default() -import lbryschema.proto.fee_pb2 +import lbrynet.schema.proto.fee_pb2 DESCRIPTOR = _descriptor.FileDescriptor( - name='lbryschema/proto/metadata.proto', + name='lbrynet.schema/proto/metadata.proto', package='', - serialized_pb=_b('\n\x1flbryschema/proto/metadata.proto\x1a\x1albryschema/proto/fee.proto\"\xde\x0e\n\x08Metadata\x12\"\n\x07version\x18\x01 \x02(\x0e\x32\x11.Metadata.Version\x12$\n\x08language\x18\x02 \x02(\x0e\x32\x12.Metadata.Language\x12\r\n\x05title\x18\x03 \x02(\t\x12\x13\n\x0b\x64\x65scription\x18\x04 \x02(\t\x12\x0e\n\x06\x61uthor\x18\x05 \x02(\t\x12\x0f\n\x07license\x18\x06 \x02(\t\x12\x0c\n\x04nsfw\x18\x07 \x02(\x08\x12\x11\n\x03\x66\x65\x65\x18\x08 \x01(\x0b\x32\x04.Fee\x12\x11\n\tthumbnail\x18\t \x01(\t\x12\x0f\n\x07preview\x18\n \x01(\t\x12\x12\n\nlicenseUrl\x18\x0b \x01(\t\"N\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01\x12\n\n\x06_0_0_2\x10\x02\x12\n\n\x06_0_0_3\x10\x03\x12\n\n\x06_0_1_0\x10\x04\"\x99\x0c\n\x08Language\x12\x14\n\x10UNKNOWN_LANGUAGE\x10\x00\x12\x06\n\x02\x65n\x10\x01\x12\x06\n\x02\x61\x61\x10\x02\x12\x06\n\x02\x61\x62\x10\x03\x12\x06\n\x02\x61\x65\x10\x04\x12\x06\n\x02\x61\x66\x10\x05\x12\x06\n\x02\x61k\x10\x06\x12\x06\n\x02\x61m\x10\x07\x12\x06\n\x02\x61n\x10\x08\x12\x06\n\x02\x61r\x10\t\x12\x06\n\x02\x61s\x10\n\x12\x06\n\x02\x61v\x10\x0b\x12\x06\n\x02\x61y\x10\x0c\x12\x06\n\x02\x61z\x10\r\x12\x06\n\x02\x62\x61\x10\x0e\x12\x06\n\x02\x62\x65\x10\x0f\x12\x06\n\x02\x62g\x10\x10\x12\x06\n\x02\x62h\x10\x11\x12\x06\n\x02\x62i\x10\x12\x12\x06\n\x02\x62m\x10\x13\x12\x06\n\x02\x62n\x10\x14\x12\x06\n\x02\x62o\x10\x15\x12\x06\n\x02\x62r\x10\x16\x12\x06\n\x02\x62s\x10\x17\x12\x06\n\x02\x63\x61\x10\x18\x12\x06\n\x02\x63\x65\x10\x19\x12\x06\n\x02\x63h\x10\x1a\x12\x06\n\x02\x63o\x10\x1b\x12\x06\n\x02\x63r\x10\x1c\x12\x06\n\x02\x63s\x10\x1d\x12\x06\n\x02\x63u\x10\x1e\x12\x06\n\x02\x63v\x10\x1f\x12\x06\n\x02\x63y\x10 \x12\x06\n\x02\x64\x61\x10!\x12\x06\n\x02\x64\x65\x10\"\x12\x06\n\x02\x64v\x10#\x12\x06\n\x02\x64z\x10$\x12\x06\n\x02\x65\x65\x10%\x12\x06\n\x02\x65l\x10&\x12\x06\n\x02\x65o\x10\'\x12\x06\n\x02\x65s\x10(\x12\x06\n\x02\x65t\x10)\x12\x06\n\x02\x65u\x10*\x12\x06\n\x02\x66\x61\x10+\x12\x06\n\x02\x66\x66\x10,\x12\x06\n\x02\x66i\x10-\x12\x06\n\x02\x66j\x10.\x12\x06\n\x02\x66o\x10/\x12\x06\n\x02\x66r\x10\x30\x12\x06\n\x02\x66y\x10\x31\x12\x06\n\x02ga\x10\x32\x12\x06\n\x02gd\x10\x33\x12\x06\n\x02gl\x10\x34\x12\x06\n\x02gn\x10\x35\x12\x06\n\x02gu\x10\x36\x12\x06\n\x02gv\x10\x37\x12\x06\n\x02ha\x10\x38\x12\x06\n\x02he\x10\x39\x12\x06\n\x02hi\x10:\x12\x06\n\x02ho\x10;\x12\x06\n\x02hr\x10<\x12\x06\n\x02ht\x10=\x12\x06\n\x02hu\x10>\x12\x06\n\x02hy\x10?\x12\x06\n\x02hz\x10@\x12\x06\n\x02ia\x10\x41\x12\x06\n\x02id\x10\x42\x12\x06\n\x02ie\x10\x43\x12\x06\n\x02ig\x10\x44\x12\x06\n\x02ii\x10\x45\x12\x06\n\x02ik\x10\x46\x12\x06\n\x02io\x10G\x12\x06\n\x02is\x10H\x12\x06\n\x02it\x10I\x12\x06\n\x02iu\x10J\x12\x06\n\x02ja\x10K\x12\x06\n\x02jv\x10L\x12\x06\n\x02ka\x10M\x12\x06\n\x02kg\x10N\x12\x06\n\x02ki\x10O\x12\x06\n\x02kj\x10P\x12\x06\n\x02kk\x10Q\x12\x06\n\x02kl\x10R\x12\x06\n\x02km\x10S\x12\x06\n\x02kn\x10T\x12\x06\n\x02ko\x10U\x12\x06\n\x02kr\x10V\x12\x06\n\x02ks\x10W\x12\x06\n\x02ku\x10X\x12\x06\n\x02kv\x10Y\x12\x06\n\x02kw\x10Z\x12\x06\n\x02ky\x10[\x12\x06\n\x02la\x10\\\x12\x06\n\x02lb\x10]\x12\x06\n\x02lg\x10^\x12\x06\n\x02li\x10_\x12\x06\n\x02ln\x10`\x12\x06\n\x02lo\x10\x61\x12\x06\n\x02lt\x10\x62\x12\x06\n\x02lu\x10\x63\x12\x06\n\x02lv\x10\x64\x12\x06\n\x02mg\x10\x65\x12\x06\n\x02mh\x10\x66\x12\x06\n\x02mi\x10g\x12\x06\n\x02mk\x10h\x12\x06\n\x02ml\x10i\x12\x06\n\x02mn\x10j\x12\x06\n\x02mr\x10k\x12\x06\n\x02ms\x10l\x12\x06\n\x02mt\x10m\x12\x06\n\x02my\x10n\x12\x06\n\x02na\x10o\x12\x06\n\x02nb\x10p\x12\x06\n\x02nd\x10q\x12\x06\n\x02ne\x10r\x12\x06\n\x02ng\x10s\x12\x06\n\x02nl\x10t\x12\x06\n\x02nn\x10u\x12\x06\n\x02no\x10v\x12\x06\n\x02nr\x10w\x12\x06\n\x02nv\x10x\x12\x06\n\x02ny\x10y\x12\x06\n\x02oc\x10z\x12\x06\n\x02oj\x10{\x12\x06\n\x02om\x10|\x12\x06\n\x02or\x10}\x12\x06\n\x02os\x10~\x12\x06\n\x02pa\x10\x7f\x12\x07\n\x02pi\x10\x80\x01\x12\x07\n\x02pl\x10\x81\x01\x12\x07\n\x02ps\x10\x82\x01\x12\x07\n\x02pt\x10\x83\x01\x12\x07\n\x02qu\x10\x84\x01\x12\x07\n\x02rm\x10\x85\x01\x12\x07\n\x02rn\x10\x86\x01\x12\x07\n\x02ro\x10\x87\x01\x12\x07\n\x02ru\x10\x88\x01\x12\x07\n\x02rw\x10\x89\x01\x12\x07\n\x02sa\x10\x8a\x01\x12\x07\n\x02sc\x10\x8b\x01\x12\x07\n\x02sd\x10\x8c\x01\x12\x07\n\x02se\x10\x8d\x01\x12\x07\n\x02sg\x10\x8e\x01\x12\x07\n\x02si\x10\x8f\x01\x12\x07\n\x02sk\x10\x90\x01\x12\x07\n\x02sl\x10\x91\x01\x12\x07\n\x02sm\x10\x92\x01\x12\x07\n\x02sn\x10\x93\x01\x12\x07\n\x02so\x10\x94\x01\x12\x07\n\x02sq\x10\x95\x01\x12\x07\n\x02sr\x10\x96\x01\x12\x07\n\x02ss\x10\x97\x01\x12\x07\n\x02st\x10\x98\x01\x12\x07\n\x02su\x10\x99\x01\x12\x07\n\x02sv\x10\x9a\x01\x12\x07\n\x02sw\x10\x9b\x01\x12\x07\n\x02ta\x10\x9c\x01\x12\x07\n\x02te\x10\x9d\x01\x12\x07\n\x02tg\x10\x9e\x01\x12\x07\n\x02th\x10\x9f\x01\x12\x07\n\x02ti\x10\xa0\x01\x12\x07\n\x02tk\x10\xa1\x01\x12\x07\n\x02tl\x10\xa2\x01\x12\x07\n\x02tn\x10\xa3\x01\x12\x07\n\x02to\x10\xa4\x01\x12\x07\n\x02tr\x10\xa5\x01\x12\x07\n\x02ts\x10\xa6\x01\x12\x07\n\x02tt\x10\xa7\x01\x12\x07\n\x02tw\x10\xa8\x01\x12\x07\n\x02ty\x10\xa9\x01\x12\x07\n\x02ug\x10\xaa\x01\x12\x07\n\x02uk\x10\xab\x01\x12\x07\n\x02ur\x10\xac\x01\x12\x07\n\x02uz\x10\xad\x01\x12\x07\n\x02ve\x10\xae\x01\x12\x07\n\x02vi\x10\xaf\x01\x12\x07\n\x02vo\x10\xb0\x01\x12\x07\n\x02wa\x10\xb1\x01\x12\x07\n\x02wo\x10\xb2\x01\x12\x07\n\x02xh\x10\xb3\x01\x12\x07\n\x02yi\x10\xb4\x01\x12\x07\n\x02yo\x10\xb5\x01\x12\x07\n\x02za\x10\xb6\x01\x12\x07\n\x02zh\x10\xb7\x01\x12\x07\n\x02zu\x10\xb8\x01') + serialized_pb=_b('\n\x1flbrynet.schema/proto/metadata.proto\x1a\x1albrynet.schema/proto/fee.proto\"\xde\x0e\n\x08Metadata\x12\"\n\x07version\x18\x01 \x02(\x0e\x32\x11.Metadata.Version\x12$\n\x08language\x18\x02 \x02(\x0e\x32\x12.Metadata.Language\x12\r\n\x05title\x18\x03 \x02(\t\x12\x13\n\x0b\x64\x65scription\x18\x04 \x02(\t\x12\x0e\n\x06\x61uthor\x18\x05 \x02(\t\x12\x0f\n\x07license\x18\x06 \x02(\t\x12\x0c\n\x04nsfw\x18\x07 \x02(\x08\x12\x11\n\x03\x66\x65\x65\x18\x08 \x01(\x0b\x32\x04.Fee\x12\x11\n\tthumbnail\x18\t \x01(\t\x12\x0f\n\x07preview\x18\n \x01(\t\x12\x12\n\nlicenseUrl\x18\x0b \x01(\t\"N\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01\x12\n\n\x06_0_0_2\x10\x02\x12\n\n\x06_0_0_3\x10\x03\x12\n\n\x06_0_1_0\x10\x04\"\x99\x0c\n\x08Language\x12\x14\n\x10UNKNOWN_LANGUAGE\x10\x00\x12\x06\n\x02\x65n\x10\x01\x12\x06\n\x02\x61\x61\x10\x02\x12\x06\n\x02\x61\x62\x10\x03\x12\x06\n\x02\x61\x65\x10\x04\x12\x06\n\x02\x61\x66\x10\x05\x12\x06\n\x02\x61k\x10\x06\x12\x06\n\x02\x61m\x10\x07\x12\x06\n\x02\x61n\x10\x08\x12\x06\n\x02\x61r\x10\t\x12\x06\n\x02\x61s\x10\n\x12\x06\n\x02\x61v\x10\x0b\x12\x06\n\x02\x61y\x10\x0c\x12\x06\n\x02\x61z\x10\r\x12\x06\n\x02\x62\x61\x10\x0e\x12\x06\n\x02\x62\x65\x10\x0f\x12\x06\n\x02\x62g\x10\x10\x12\x06\n\x02\x62h\x10\x11\x12\x06\n\x02\x62i\x10\x12\x12\x06\n\x02\x62m\x10\x13\x12\x06\n\x02\x62n\x10\x14\x12\x06\n\x02\x62o\x10\x15\x12\x06\n\x02\x62r\x10\x16\x12\x06\n\x02\x62s\x10\x17\x12\x06\n\x02\x63\x61\x10\x18\x12\x06\n\x02\x63\x65\x10\x19\x12\x06\n\x02\x63h\x10\x1a\x12\x06\n\x02\x63o\x10\x1b\x12\x06\n\x02\x63r\x10\x1c\x12\x06\n\x02\x63s\x10\x1d\x12\x06\n\x02\x63u\x10\x1e\x12\x06\n\x02\x63v\x10\x1f\x12\x06\n\x02\x63y\x10 \x12\x06\n\x02\x64\x61\x10!\x12\x06\n\x02\x64\x65\x10\"\x12\x06\n\x02\x64v\x10#\x12\x06\n\x02\x64z\x10$\x12\x06\n\x02\x65\x65\x10%\x12\x06\n\x02\x65l\x10&\x12\x06\n\x02\x65o\x10\'\x12\x06\n\x02\x65s\x10(\x12\x06\n\x02\x65t\x10)\x12\x06\n\x02\x65u\x10*\x12\x06\n\x02\x66\x61\x10+\x12\x06\n\x02\x66\x66\x10,\x12\x06\n\x02\x66i\x10-\x12\x06\n\x02\x66j\x10.\x12\x06\n\x02\x66o\x10/\x12\x06\n\x02\x66r\x10\x30\x12\x06\n\x02\x66y\x10\x31\x12\x06\n\x02ga\x10\x32\x12\x06\n\x02gd\x10\x33\x12\x06\n\x02gl\x10\x34\x12\x06\n\x02gn\x10\x35\x12\x06\n\x02gu\x10\x36\x12\x06\n\x02gv\x10\x37\x12\x06\n\x02ha\x10\x38\x12\x06\n\x02he\x10\x39\x12\x06\n\x02hi\x10:\x12\x06\n\x02ho\x10;\x12\x06\n\x02hr\x10<\x12\x06\n\x02ht\x10=\x12\x06\n\x02hu\x10>\x12\x06\n\x02hy\x10?\x12\x06\n\x02hz\x10@\x12\x06\n\x02ia\x10\x41\x12\x06\n\x02id\x10\x42\x12\x06\n\x02ie\x10\x43\x12\x06\n\x02ig\x10\x44\x12\x06\n\x02ii\x10\x45\x12\x06\n\x02ik\x10\x46\x12\x06\n\x02io\x10G\x12\x06\n\x02is\x10H\x12\x06\n\x02it\x10I\x12\x06\n\x02iu\x10J\x12\x06\n\x02ja\x10K\x12\x06\n\x02jv\x10L\x12\x06\n\x02ka\x10M\x12\x06\n\x02kg\x10N\x12\x06\n\x02ki\x10O\x12\x06\n\x02kj\x10P\x12\x06\n\x02kk\x10Q\x12\x06\n\x02kl\x10R\x12\x06\n\x02km\x10S\x12\x06\n\x02kn\x10T\x12\x06\n\x02ko\x10U\x12\x06\n\x02kr\x10V\x12\x06\n\x02ks\x10W\x12\x06\n\x02ku\x10X\x12\x06\n\x02kv\x10Y\x12\x06\n\x02kw\x10Z\x12\x06\n\x02ky\x10[\x12\x06\n\x02la\x10\\\x12\x06\n\x02lb\x10]\x12\x06\n\x02lg\x10^\x12\x06\n\x02li\x10_\x12\x06\n\x02ln\x10`\x12\x06\n\x02lo\x10\x61\x12\x06\n\x02lt\x10\x62\x12\x06\n\x02lu\x10\x63\x12\x06\n\x02lv\x10\x64\x12\x06\n\x02mg\x10\x65\x12\x06\n\x02mh\x10\x66\x12\x06\n\x02mi\x10g\x12\x06\n\x02mk\x10h\x12\x06\n\x02ml\x10i\x12\x06\n\x02mn\x10j\x12\x06\n\x02mr\x10k\x12\x06\n\x02ms\x10l\x12\x06\n\x02mt\x10m\x12\x06\n\x02my\x10n\x12\x06\n\x02na\x10o\x12\x06\n\x02nb\x10p\x12\x06\n\x02nd\x10q\x12\x06\n\x02ne\x10r\x12\x06\n\x02ng\x10s\x12\x06\n\x02nl\x10t\x12\x06\n\x02nn\x10u\x12\x06\n\x02no\x10v\x12\x06\n\x02nr\x10w\x12\x06\n\x02nv\x10x\x12\x06\n\x02ny\x10y\x12\x06\n\x02oc\x10z\x12\x06\n\x02oj\x10{\x12\x06\n\x02om\x10|\x12\x06\n\x02or\x10}\x12\x06\n\x02os\x10~\x12\x06\n\x02pa\x10\x7f\x12\x07\n\x02pi\x10\x80\x01\x12\x07\n\x02pl\x10\x81\x01\x12\x07\n\x02ps\x10\x82\x01\x12\x07\n\x02pt\x10\x83\x01\x12\x07\n\x02qu\x10\x84\x01\x12\x07\n\x02rm\x10\x85\x01\x12\x07\n\x02rn\x10\x86\x01\x12\x07\n\x02ro\x10\x87\x01\x12\x07\n\x02ru\x10\x88\x01\x12\x07\n\x02rw\x10\x89\x01\x12\x07\n\x02sa\x10\x8a\x01\x12\x07\n\x02sc\x10\x8b\x01\x12\x07\n\x02sd\x10\x8c\x01\x12\x07\n\x02se\x10\x8d\x01\x12\x07\n\x02sg\x10\x8e\x01\x12\x07\n\x02si\x10\x8f\x01\x12\x07\n\x02sk\x10\x90\x01\x12\x07\n\x02sl\x10\x91\x01\x12\x07\n\x02sm\x10\x92\x01\x12\x07\n\x02sn\x10\x93\x01\x12\x07\n\x02so\x10\x94\x01\x12\x07\n\x02sq\x10\x95\x01\x12\x07\n\x02sr\x10\x96\x01\x12\x07\n\x02ss\x10\x97\x01\x12\x07\n\x02st\x10\x98\x01\x12\x07\n\x02su\x10\x99\x01\x12\x07\n\x02sv\x10\x9a\x01\x12\x07\n\x02sw\x10\x9b\x01\x12\x07\n\x02ta\x10\x9c\x01\x12\x07\n\x02te\x10\x9d\x01\x12\x07\n\x02tg\x10\x9e\x01\x12\x07\n\x02th\x10\x9f\x01\x12\x07\n\x02ti\x10\xa0\x01\x12\x07\n\x02tk\x10\xa1\x01\x12\x07\n\x02tl\x10\xa2\x01\x12\x07\n\x02tn\x10\xa3\x01\x12\x07\n\x02to\x10\xa4\x01\x12\x07\n\x02tr\x10\xa5\x01\x12\x07\n\x02ts\x10\xa6\x01\x12\x07\n\x02tt\x10\xa7\x01\x12\x07\n\x02tw\x10\xa8\x01\x12\x07\n\x02ty\x10\xa9\x01\x12\x07\n\x02ug\x10\xaa\x01\x12\x07\n\x02uk\x10\xab\x01\x12\x07\n\x02ur\x10\xac\x01\x12\x07\n\x02uz\x10\xad\x01\x12\x07\n\x02ve\x10\xae\x01\x12\x07\n\x02vi\x10\xaf\x01\x12\x07\n\x02vo\x10\xb0\x01\x12\x07\n\x02wa\x10\xb1\x01\x12\x07\n\x02wo\x10\xb2\x01\x12\x07\n\x02xh\x10\xb3\x01\x12\x07\n\x02yi\x10\xb4\x01\x12\x07\n\x02yo\x10\xb5\x01\x12\x07\n\x02za\x10\xb6\x01\x12\x07\n\x02zh\x10\xb7\x01\x12\x07\n\x02zu\x10\xb8\x01') , - dependencies=[lbryschema.proto.fee_pb2.DESCRIPTOR,]) + dependencies=[lbrynet.schema.proto.fee_pb2.DESCRIPTOR,]) _sym_db.RegisterFileDescriptor(DESCRIPTOR) @@ -918,14 +918,14 @@ _METADATA = _descriptor.Descriptor( _METADATA.fields_by_name['version'].enum_type = _METADATA_VERSION _METADATA.fields_by_name['language'].enum_type = _METADATA_LANGUAGE -_METADATA.fields_by_name['fee'].message_type = lbryschema.proto.fee_pb2._FEE +_METADATA.fields_by_name['fee'].message_type = lbrynet.schema.proto.fee_pb2._FEE _METADATA_VERSION.containing_type = _METADATA _METADATA_LANGUAGE.containing_type = _METADATA DESCRIPTOR.message_types_by_name['Metadata'] = _METADATA Metadata = _reflection.GeneratedProtocolMessageType('Metadata', (_message.Message,), dict( DESCRIPTOR = _METADATA, - __module__ = 'lbryschema.proto.metadata_pb2' + __module__ = 'lbrynet.schema.proto.metadata_pb2' # @@protoc_insertion_point(class_scope:Metadata) )) _sym_db.RegisterMessage(Metadata) diff --git a/lbrynet/schema/proto/signature.proto b/lbrynet/schema/proto/signature.proto index 1830a7733..3621c2b77 100644 --- a/lbrynet/schema/proto/signature.proto +++ b/lbrynet/schema/proto/signature.proto @@ -1,6 +1,6 @@ syntax = "proto2"; -import "lbryschema/proto/certificate.proto"; +import "lbrynet.schema/proto/certificate.proto"; message Signature { enum Version { diff --git a/lbrynet/schema/proto/signature_pb2.py b/lbrynet/schema/proto/signature_pb2.py index 64b9cc13f..a5859181f 100644 --- a/lbrynet/schema/proto/signature_pb2.py +++ b/lbrynet/schema/proto/signature_pb2.py @@ -1,5 +1,5 @@ # Generated by the protocol buffer compiler. DO NOT EDIT! -# source: lbryschema/proto/signature.proto +# source: lbrynet.schema/proto/signature.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) @@ -13,15 +13,15 @@ from google.protobuf import descriptor_pb2 _sym_db = _symbol_database.Default() -import lbryschema.proto.certificate_pb2 +import lbrynet.schema.proto.certificate_pb2 DESCRIPTOR = _descriptor.FileDescriptor( - name='lbryschema/proto/signature.proto', + name='lbrynet.schema/proto/signature.proto', package='', - serialized_pb=_b('\n lbryschema/proto/signature.proto\x1a\"lbryschema/proto/certificate.proto\"\xa7\x01\n\tSignature\x12#\n\x07version\x18\x01 \x02(\x0e\x32\x12.Signature.Version\x12\x1f\n\rsignatureType\x18\x02 \x02(\x0e\x32\x08.KeyType\x12\x11\n\tsignature\x18\x03 \x02(\x0c\x12\x15\n\rcertificateId\x18\x04 \x02(\x0c\"*\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01') + serialized_pb=_b('\n lbrynet.schema/proto/signature.proto\x1a\"lbrynet.schema/proto/certificate.proto\"\xa7\x01\n\tSignature\x12#\n\x07version\x18\x01 \x02(\x0e\x32\x12.Signature.Version\x12\x1f\n\rsignatureType\x18\x02 \x02(\x0e\x32\x08.KeyType\x12\x11\n\tsignature\x18\x03 \x02(\x0c\x12\x15\n\rcertificateId\x18\x04 \x02(\x0c\"*\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01') , - dependencies=[lbryschema.proto.certificate_pb2.DESCRIPTOR,]) + dependencies=[lbrynet.schema.proto.certificate_pb2.DESCRIPTOR,]) _sym_db.RegisterFileDescriptor(DESCRIPTOR) @@ -101,13 +101,13 @@ _SIGNATURE = _descriptor.Descriptor( ) _SIGNATURE.fields_by_name['version'].enum_type = _SIGNATURE_VERSION -_SIGNATURE.fields_by_name['signatureType'].enum_type = lbryschema.proto.certificate_pb2._KEYTYPE +_SIGNATURE.fields_by_name['signatureType'].enum_type = lbrynet.schema.proto.certificate_pb2._KEYTYPE _SIGNATURE_VERSION.containing_type = _SIGNATURE DESCRIPTOR.message_types_by_name['Signature'] = _SIGNATURE Signature = _reflection.GeneratedProtocolMessageType('Signature', (_message.Message,), dict( DESCRIPTOR = _SIGNATURE, - __module__ = 'lbryschema.proto.signature_pb2' + __module__ = 'lbrynet.schema.proto.signature_pb2' # @@protoc_insertion_point(class_scope:Signature) )) _sym_db.RegisterMessage(Signature) diff --git a/lbrynet/schema/proto/source_pb2.py b/lbrynet/schema/proto/source_pb2.py index 211b36b73..0c3f15293 100644 --- a/lbrynet/schema/proto/source_pb2.py +++ b/lbrynet/schema/proto/source_pb2.py @@ -1,5 +1,5 @@ # Generated by the protocol buffer compiler. DO NOT EDIT! -# source: lbryschema/proto/source.proto +# source: lbrynet.schema/proto/source.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) @@ -16,9 +16,9 @@ _sym_db = _symbol_database.Default() DESCRIPTOR = _descriptor.FileDescriptor( - name='lbryschema/proto/source.proto', + name='lbrynet.schema/proto/source.proto', package='', - serialized_pb=_b('\n\x1dlbryschema/proto/source.proto\"\xde\x01\n\x06Source\x12 \n\x07version\x18\x01 \x02(\x0e\x32\x0f.Source.Version\x12\'\n\nsourceType\x18\x02 \x02(\x0e\x32\x13.Source.SourceTypes\x12\x0e\n\x06source\x18\x03 \x02(\x0c\x12\x13\n\x0b\x63ontentType\x18\x04 \x02(\t\"*\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01\"8\n\x0bSourceTypes\x12\x17\n\x13UNKNOWN_SOURCE_TYPE\x10\x00\x12\x10\n\x0clbry_sd_hash\x10\x01') + serialized_pb=_b('\n\x1dlbrynet.schema/proto/source.proto\"\xde\x01\n\x06Source\x12 \n\x07version\x18\x01 \x02(\x0e\x32\x0f.Source.Version\x12\'\n\nsourceType\x18\x02 \x02(\x0e\x32\x13.Source.SourceTypes\x12\x0e\n\x06source\x18\x03 \x02(\x0c\x12\x13\n\x0b\x63ontentType\x18\x04 \x02(\t\"*\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01\"8\n\x0bSourceTypes\x12\x17\n\x13UNKNOWN_SOURCE_TYPE\x10\x00\x12\x10\n\x0clbry_sd_hash\x10\x01') ) _sym_db.RegisterFileDescriptor(DESCRIPTOR) @@ -129,7 +129,7 @@ DESCRIPTOR.message_types_by_name['Source'] = _SOURCE Source = _reflection.GeneratedProtocolMessageType('Source', (_message.Message,), dict( DESCRIPTOR = _SOURCE, - __module__ = 'lbryschema.proto.source_pb2' + __module__ = 'lbrynet.schema.proto.source_pb2' # @@protoc_insertion_point(class_scope:Source) )) _sym_db.RegisterMessage(Source) diff --git a/lbrynet/schema/proto/stream.proto b/lbrynet/schema/proto/stream.proto index 3866ca1c2..097c1bb6c 100644 --- a/lbrynet/schema/proto/stream.proto +++ b/lbrynet/schema/proto/stream.proto @@ -1,7 +1,7 @@ syntax = "proto2"; -import "lbryschema/proto/metadata.proto"; -import "lbryschema/proto/source.proto"; +import "lbrynet.schema/proto/metadata.proto"; +import "lbrynet.schema/proto/source.proto"; message Stream { diff --git a/lbrynet/schema/proto/stream_pb2.py b/lbrynet/schema/proto/stream_pb2.py index 88b79a64c..b2c92d2e3 100644 --- a/lbrynet/schema/proto/stream_pb2.py +++ b/lbrynet/schema/proto/stream_pb2.py @@ -1,5 +1,5 @@ # Generated by the protocol buffer compiler. DO NOT EDIT! -# source: lbryschema/proto/stream.proto +# source: lbrynet.schema/proto/stream.proto import sys _b=sys.version_info[0]<3 and (lambda x:x) or (lambda x:x.encode('latin1')) @@ -13,16 +13,16 @@ from google.protobuf import descriptor_pb2 _sym_db = _symbol_database.Default() -import lbryschema.proto.metadata_pb2 -import lbryschema.proto.source_pb2 +import lbrynet.schema.proto.metadata_pb2 +import lbrynet.schema.proto.source_pb2 DESCRIPTOR = _descriptor.FileDescriptor( - name='lbryschema/proto/stream.proto', + name='lbrynet.schema/proto/stream.proto', package='', - serialized_pb=_b('\n\x1dlbryschema/proto/stream.proto\x1a\x1flbryschema/proto/metadata.proto\x1a\x1dlbryschema/proto/source.proto\"\x8c\x01\n\x06Stream\x12 \n\x07version\x18\x01 \x02(\x0e\x32\x0f.Stream.Version\x12\x1b\n\x08metadata\x18\x02 \x02(\x0b\x32\t.Metadata\x12\x17\n\x06source\x18\x03 \x02(\x0b\x32\x07.Source\"*\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01') + serialized_pb=_b('\n\x1dlbrynet.schema/proto/stream.proto\x1a\x1flbrynet.schema/proto/metadata.proto\x1a\x1dlbrynet.schema/proto/source.proto\"\x8c\x01\n\x06Stream\x12 \n\x07version\x18\x01 \x02(\x0e\x32\x0f.Stream.Version\x12\x1b\n\x08metadata\x18\x02 \x02(\x0b\x32\t.Metadata\x12\x17\n\x06source\x18\x03 \x02(\x0b\x32\x07.Source\"*\n\x07Version\x12\x13\n\x0fUNKNOWN_VERSION\x10\x00\x12\n\n\x06_0_0_1\x10\x01') , - dependencies=[lbryschema.proto.metadata_pb2.DESCRIPTOR,lbryschema.proto.source_pb2.DESCRIPTOR,]) + dependencies=[lbrynet.schema.proto.metadata_pb2.DESCRIPTOR,lbrynet.schema.proto.source_pb2.DESCRIPTOR,]) _sym_db.RegisterFileDescriptor(DESCRIPTOR) @@ -95,14 +95,14 @@ _STREAM = _descriptor.Descriptor( ) _STREAM.fields_by_name['version'].enum_type = _STREAM_VERSION -_STREAM.fields_by_name['metadata'].message_type = lbryschema.proto.metadata_pb2._METADATA -_STREAM.fields_by_name['source'].message_type = lbryschema.proto.source_pb2._SOURCE +_STREAM.fields_by_name['metadata'].message_type = lbrynet.schema.proto.metadata_pb2._METADATA +_STREAM.fields_by_name['source'].message_type = lbrynet.schema.proto.source_pb2._SOURCE _STREAM_VERSION.containing_type = _STREAM DESCRIPTOR.message_types_by_name['Stream'] = _STREAM Stream = _reflection.GeneratedProtocolMessageType('Stream', (_message.Message,), dict( DESCRIPTOR = _STREAM, - __module__ = 'lbryschema.proto.stream_pb2' + __module__ = 'lbrynet.schema.proto.stream_pb2' # @@protoc_insertion_point(class_scope:Stream) )) _sym_db.RegisterMessage(Stream) diff --git a/lbrynet/schema/schema/certificate.py b/lbrynet/schema/schema/certificate.py index 03031baa0..5bdaf2a35 100644 --- a/lbrynet/schema/schema/certificate.py +++ b/lbrynet/schema/schema/certificate.py @@ -1,9 +1,9 @@ from copy import deepcopy -from lbryschema.proto import certificate_pb2 as cert_pb -from lbryschema.schema.schema import Schema -from lbryschema.schema import VERSION_MAP, V_0_0_1, ECDSA_CURVES, CURVE_NAMES -from lbryschema.validator import get_key_type_from_dem +from lbrynet.schema.proto import certificate_pb2 as cert_pb +from lbrynet.schema.schema.schema import Schema +from lbrynet.schema.schema import VERSION_MAP, V_0_0_1, ECDSA_CURVES, CURVE_NAMES +from lbrynet.schema.validator import get_key_type_from_dem class _ECDSAKeyHelper(object): diff --git a/lbrynet/schema/schema/claim.py b/lbrynet/schema/schema/claim.py index 919032fd2..0e9052e7d 100644 --- a/lbrynet/schema/schema/claim.py +++ b/lbrynet/schema/schema/claim.py @@ -1,11 +1,11 @@ from copy import deepcopy -from lbryschema.proto import claim_pb2 as claim_pb -from lbryschema.schema import VERSION_MAP -from lbryschema.schema.signature import Signature -from lbryschema.schema.certificate import Certificate -from lbryschema.schema.schema import Schema -from lbryschema.schema.stream import Stream +from lbrynet.schema.proto import claim_pb2 as claim_pb +from lbrynet.schema.schema import VERSION_MAP +from lbrynet.schema.schema.signature import Signature +from lbrynet.schema.schema.certificate import Certificate +from lbrynet.schema.schema.schema import Schema +from lbrynet.schema.schema.stream import Stream class Claim(Schema): diff --git a/lbrynet/schema/schema/fee.py b/lbrynet/schema/schema/fee.py index c2be46196..f91389455 100644 --- a/lbrynet/schema/schema/fee.py +++ b/lbrynet/schema/schema/fee.py @@ -1,8 +1,8 @@ from copy import deepcopy -from lbryschema.schema.schema import Schema -from lbryschema.proto import fee_pb2 as fee_pb -from lbryschema.schema import VERSION_MAP, CURRENCY_MAP +from lbrynet.schema.schema.schema import Schema +from lbrynet.schema.proto import fee_pb2 as fee_pb +from lbrynet.schema.schema import VERSION_MAP, CURRENCY_MAP class Fee(Schema): diff --git a/lbrynet/schema/schema/metadata.py b/lbrynet/schema/schema/metadata.py index cb65bb276..edbf298a9 100644 --- a/lbrynet/schema/schema/metadata.py +++ b/lbrynet/schema/schema/metadata.py @@ -1,8 +1,8 @@ from copy import deepcopy -from lbryschema.proto import metadata_pb2 as metadata_pb -from lbryschema.schema.fee import Fee -from lbryschema.schema.schema import Schema -from lbryschema.schema import VERSION_MAP +from lbrynet.schema.proto import metadata_pb2 as metadata_pb +from lbrynet.schema.schema.fee import Fee +from lbrynet.schema.schema.schema import Schema +from lbrynet.schema.schema import VERSION_MAP class Metadata(Schema): diff --git a/lbrynet/schema/schema/signature.py b/lbrynet/schema/schema/signature.py index e4c35e212..90190a142 100644 --- a/lbrynet/schema/schema/signature.py +++ b/lbrynet/schema/schema/signature.py @@ -1,8 +1,8 @@ from copy import deepcopy -from lbryschema.proto import signature_pb2 as signature_pb -from lbryschema.schema import VERSION_MAP, ECDSA_CURVES -from lbryschema.schema.schema import Schema +from lbrynet.schema.proto import signature_pb2 as signature_pb +from lbrynet.schema.schema import VERSION_MAP, ECDSA_CURVES +from lbrynet.schema.schema.schema import Schema class Signature(Schema): diff --git a/lbrynet/schema/schema/source.py b/lbrynet/schema/schema/source.py index 550127b39..0b90b4eab 100644 --- a/lbrynet/schema/schema/source.py +++ b/lbrynet/schema/schema/source.py @@ -1,8 +1,8 @@ from copy import deepcopy -from lbryschema.proto import source_pb2 as source_pb -from lbryschema.schema import SOURCE_TYPES, LBRY_SD_HASH_LENGTH, VERSION_MAP -from lbryschema.schema.schema import Schema -from lbryschema.error import InvalidSourceHashLength +from lbrynet.schema.proto import source_pb2 as source_pb +from lbrynet.schema.schema import SOURCE_TYPES, LBRY_SD_HASH_LENGTH, VERSION_MAP +from lbrynet.schema.schema.schema import Schema +from lbrynet.schema.error import InvalidSourceHashLength class Source(Schema): diff --git a/lbrynet/schema/schema/stream.py b/lbrynet/schema/schema/stream.py index 77a62db4e..2fe955c4b 100644 --- a/lbrynet/schema/schema/stream.py +++ b/lbrynet/schema/schema/stream.py @@ -1,10 +1,10 @@ from copy import deepcopy -from lbryschema.schema.source import Source -from lbryschema.proto import stream_pb2 as stream_pb -from lbryschema.schema import VERSION_MAP -from lbryschema.schema.metadata import Metadata -from lbryschema.schema.schema import Schema +from lbrynet.schema.schema.source import Source +from lbrynet.schema.proto import stream_pb2 as stream_pb +from lbrynet.schema.schema import VERSION_MAP +from lbrynet.schema.schema.metadata import Metadata +from lbrynet.schema.schema.schema import Schema class Stream(Schema): diff --git a/lbrynet/schema/signer.py b/lbrynet/schema/signer.py index b4294d37f..4132c70c1 100644 --- a/lbrynet/schema/signer.py +++ b/lbrynet/schema/signer.py @@ -1,13 +1,13 @@ import ecdsa import hashlib import binascii -from lbryschema.address import decode_address -from lbryschema.encoding import decode_b64_fields -from lbryschema.schema.certificate import Certificate -from lbryschema.schema.claim import Claim -from lbryschema.validator import validate_claim_id -from lbryschema.schema import V_0_0_1, CLAIM_TYPE, CLAIM_TYPES, CERTIFICATE_TYPE, VERSION -from lbryschema.schema import NIST256p, NIST384p, SECP256k1, SHA256, SHA384 +from lbrynet.schema.address import decode_address +from lbrynet.schema.encoding import decode_b64_fields +from lbrynet.schema.schema.certificate import Certificate +from lbrynet.schema.schema.claim import Claim +from lbrynet.schema.validator import validate_claim_id +from lbrynet.schema.schema import V_0_0_1, CLAIM_TYPE, CLAIM_TYPES, CERTIFICATE_TYPE, VERSION +from lbrynet.schema.schema import NIST256p, NIST384p, SECP256k1, SHA256, SHA384 class NIST_ECDSASigner(object): diff --git a/lbrynet/schema/uri.py b/lbrynet/schema/uri.py index 03de691e8..cc9596bee 100644 --- a/lbrynet/schema/uri.py +++ b/lbrynet/schema/uri.py @@ -1,5 +1,5 @@ import re -from lbryschema.error import URIParseError +from lbrynet.schema.error import URIParseError PROTOCOL = 'lbry://' CHANNEL_CHAR = '@' diff --git a/lbrynet/schema/validator.py b/lbrynet/schema/validator.py index 6a766f842..68830adb7 100644 --- a/lbrynet/schema/validator.py +++ b/lbrynet/schema/validator.py @@ -13,8 +13,8 @@ from cryptography.hazmat.primitives.asymmetric.utils import Prehashed from cryptography.exceptions import InvalidSignature from ecdsa.util import sigencode_der -from lbryschema.address import decode_address -from lbryschema.schema import NIST256p, NIST384p, SECP256k1, ECDSA_CURVES, CURVE_NAMES +from lbrynet.schema.address import decode_address +from lbrynet.schema.schema import NIST256p, NIST384p, SECP256k1, ECDSA_CURVES, CURVE_NAMES def validate_claim_id(claim_id): diff --git a/lbrynet/wallet/account.py b/lbrynet/wallet/account.py index 3640a8f47..df73c4a46 100644 --- a/lbrynet/wallet/account.py +++ b/lbrynet/wallet/account.py @@ -4,8 +4,8 @@ import logging from torba.client.baseaccount import BaseAccount from torba.client.basetransaction import TXORef -from lbryschema.claim import ClaimDict -from lbryschema.signer import SECP256k1, get_signer +from lbrynet.schema.claim import ClaimDict +from lbrynet.schema.signer import SECP256k1, get_signer log = logging.getLogger(__name__) diff --git a/lbrynet/wallet/ledger.py b/lbrynet/wallet/ledger.py index d9dfb591d..4e087fafb 100644 --- a/lbrynet/wallet/ledger.py +++ b/lbrynet/wallet/ledger.py @@ -2,8 +2,8 @@ import asyncio import logging from binascii import unhexlify -from lbryschema.error import URIParseError -from lbryschema.uri import parse_lbry_uri +from lbrynet.schema.error import URIParseError +from lbrynet.schema.uri import parse_lbry_uri from torba.client.baseledger import BaseLedger from .resolve import Resolver diff --git a/lbrynet/wallet/manager.py b/lbrynet/wallet/manager.py index ef1f4e172..d7e5c0419 100644 --- a/lbrynet/wallet/manager.py +++ b/lbrynet/wallet/manager.py @@ -12,7 +12,7 @@ from twisted.internet import defer from lbryschema.schema import SECP256k1 from torba.client.basemanager import BaseWalletManager -from lbryschema.claim import ClaimDict +from lbrynet.schema.claim import ClaimDict from .ledger import MainNetLedger from .account import BaseAccount, generate_certificate diff --git a/lbrynet/wallet/resolve.py b/lbrynet/wallet/resolve.py index 060a9ea58..e0bb1043f 100644 --- a/lbrynet/wallet/resolve.py +++ b/lbrynet/wallet/resolve.py @@ -4,11 +4,11 @@ from ecdsa import BadSignatureError from binascii import unhexlify, hexlify from lbrynet.core.Error import UnknownNameError, UnknownClaimID, UnknownURI, UnknownOutpoint -from lbryschema.address import is_address -from lbryschema.claim import ClaimDict -from lbryschema.decode import smart_decode -from lbryschema.error import DecodeError -from lbryschema.uri import parse_lbry_uri +from lbrynet.schema.address import is_address +from lbrynet.schema.claim import ClaimDict +from lbrynet.schema.decode import smart_decode +from lbrynet.schema.error import DecodeError +from lbrynet.schema.uri import parse_lbry_uri from .claim_proofs import verify_proof, InvalidProofError log = logging.getLogger(__name__) @@ -235,7 +235,7 @@ class Resolver: # these results can include those where `signature_is_valid` is False. if they are skipped, # page indexing becomes tricky, as the number of results isn't known until after having # processed them. - # TODO: fix ^ in lbryschema + # TODO: fix ^ in lbrynet.schema async def iter_validate_channel_claims(): formatted_claims = [] diff --git a/lbrynet/wallet/transaction.py b/lbrynet/wallet/transaction.py index 006cc87b7..8c101cd39 100644 --- a/lbrynet/wallet/transaction.py +++ b/lbrynet/wallet/transaction.py @@ -2,12 +2,12 @@ import struct from binascii import hexlify, unhexlify from typing import List, Iterable, Optional -from lbryschema.decode import smart_decode +from lbrynet.schema.decode import smart_decode from .account import Account from torba.client.basetransaction import BaseTransaction, BaseInput, BaseOutput from torba.client.hash import hash160 -from lbryschema.claim import ClaimDict +from lbrynet.schema.claim import ClaimDict from .script import InputScript, OutputScript diff --git a/tests/integration/wallet/test_commands.py b/tests/integration/wallet/test_commands.py index 702c4770b..1fd6c1aa8 100644 --- a/tests/integration/wallet/test_commands.py +++ b/tests/integration/wallet/test_commands.py @@ -10,8 +10,8 @@ from twisted.internet.utils import runWithWarningsSuppressed as originalRunWith from torba.testcase import IntegrationTestCase as BaseIntegrationTestCase -import lbryschema -lbryschema.BLOCKCHAIN_NAME = 'lbrycrd_regtest' +import lbrynet.schema +lbrynet.schema.BLOCKCHAIN_NAME = 'lbrycrd_regtest' from lbrynet import conf as lbry_conf from lbrynet.dht.node import Node diff --git a/tests/integration/wallet/test_transactions.py b/tests/integration/wallet/test_transactions.py index 3a583d94b..5353924b7 100644 --- a/tests/integration/wallet/test_transactions.py +++ b/tests/integration/wallet/test_transactions.py @@ -2,13 +2,13 @@ import logging import asyncio from torba.testcase import IntegrationTestCase -from lbryschema.claim import ClaimDict +from lbrynet.schema.claim import ClaimDict from lbrynet.wallet.transaction import Transaction from lbrynet.wallet.account import generate_certificate from lbrynet.wallet.dewies import dewies_to_lbc as d2l, lbc_to_dewies as l2d -import lbryschema -lbryschema.BLOCKCHAIN_NAME = 'lbrycrd_regtest' +import lbrynet.schema +lbrynet.schema.BLOCKCHAIN_NAME = 'lbrycrd_regtest' example_claim_dict = { diff --git a/tests/unit/core/test_Wallet.py b/tests/unit/core/test_Wallet.py index 2f21c1e3a..729fa01d0 100644 --- a/tests/unit/core/test_Wallet.py +++ b/tests/unit/core/test_Wallet.py @@ -13,7 +13,7 @@ from lbrynet.core.Error import InsufficientFundsError #from lbrynet.core.Wallet import LBRYumWallet, ReservedPoints #from lbryum.commands import Commands #from lbryum.simple_config import SimpleConfig -from lbryschema.claim import ClaimDict +from lbrynet.schema.claim import ClaimDict test_metadata = { 'license': 'NASA', diff --git a/tests/unit/lbrynet_daemon/test_Daemon.py b/tests/unit/lbrynet_daemon/test_Daemon.py index 814442829..acf182990 100644 --- a/tests/unit/lbrynet_daemon/test_Daemon.py +++ b/tests/unit/lbrynet_daemon/test_Daemon.py @@ -8,7 +8,7 @@ from twisted.trial import unittest from faker import Faker -from lbryschema.decode import smart_decode +from lbrynet.schema.decode import smart_decode from lbrynet import conf from lbrynet.database.storage import SQLiteStorage from lbrynet.daemon.ComponentManager import ComponentManager diff --git a/tests/unit/lbrynet_daemon/test_ExchangeRateManager.py b/tests/unit/lbrynet_daemon/test_ExchangeRateManager.py index c1f703821..f507b201e 100644 --- a/tests/unit/lbrynet_daemon/test_ExchangeRateManager.py +++ b/tests/unit/lbrynet_daemon/test_ExchangeRateManager.py @@ -1,4 +1,4 @@ -from lbryschema.fee import Fee +from lbrynet.schema.fee import Fee from lbrynet.daemon import ExchangeRateManager from lbrynet.core.Error import InvalidExchangeRateResponse from twisted.trial import unittest diff --git a/tests/unit/schema/test_lbryschema.py b/tests/unit/schema/test_lbryschema.py index 350650fcb..8394ed742 100644 --- a/tests/unit/schema/test_lbryschema.py +++ b/tests/unit/schema/test_lbryschema.py @@ -6,22 +6,22 @@ import binascii from copy import deepcopy import unittest -from test_data import example_003, example_010, example_010_serialized -from test_data import claim_id_1, claim_address_1, claim_address_2 -from test_data import binary_claim, expected_binary_claim_decoded -from test_data import nist256p_private_key, claim_010_signed_nist256p, nist256p_cert -from test_data import nist384p_private_key, claim_010_signed_nist384p, nist384p_cert -from test_data import secp256k1_private_key, claim_010_signed_secp256k1, secp256k1_cert -from test_data import hex_encoded_003, decoded_hex_encoded_003, malformed_secp256k1_cert -import lbryschema -from lbryschema.claim import ClaimDict -from lbryschema.schema import NIST256p, NIST384p, SECP256k1 -from lbryschema.legacy.migrate import migrate -from lbryschema.signer import get_signer -from lbryschema.uri import URI, URIParseError -from lbryschema.decode import smart_decode -from lbryschema.error import DecodeError, InvalidAddress -from lbryschema.address import decode_address, encode_address +from .test_data import example_003, example_010, example_010_serialized +from .test_data import claim_id_1, claim_address_1, claim_address_2 +from .test_data import binary_claim, expected_binary_claim_decoded +from .test_data import nist256p_private_key, claim_010_signed_nist256p, nist256p_cert +from .test_data import nist384p_private_key, claim_010_signed_nist384p, nist384p_cert +from .test_data import secp256k1_private_key, claim_010_signed_secp256k1, secp256k1_cert +from .test_data import hex_encoded_003, decoded_hex_encoded_003, malformed_secp256k1_cert +from lbrynet import schema +from lbrynet.schema.claim import ClaimDict +from lbrynet.schema.schema import NIST256p, NIST384p, SECP256k1 +from lbrynet.schema.legacy.migrate import migrate +from lbrynet.schema.signer import get_signer +from lbrynet.schema.uri import URI, URIParseError +from lbrynet.schema.decode import smart_decode +from lbrynet.schema.error import DecodeError, InvalidAddress +from lbrynet.schema.address import decode_address, encode_address parsed_uri_matches = [ @@ -372,10 +372,10 @@ class TestMainnetAddressValidation(UnitTest): class TestRegtestAddressValidation(UnitTest): def setUp(self): - lbryschema.BLOCKCHAIN_NAME = "lbrycrd_regtest" + schema.BLOCKCHAIN_NAME = "lbrycrd_regtest" def tearDown(self): - lbryschema.BLOCKCHAIN_NAME = "lbrycrd_main" + schema.BLOCKCHAIN_NAME = "lbrycrd_main" def test_regtest_address_encode_decode(self): valid_addr_hex = "6fcdac187757dbf05500f613ada6fdd953d59b9acbf3c9343f" diff --git a/tests/unit/wallet/test_claim_proofs.py b/tests/unit/wallet/test_claim_proofs.py index 158ea33f7..af0052c2c 100644 --- a/tests/unit/wallet/test_claim_proofs.py +++ b/tests/unit/wallet/test_claim_proofs.py @@ -2,7 +2,7 @@ import unittest from binascii import hexlify, unhexlify from lbrynet.wallet.claim_proofs import get_hash_for_outpoint, verify_proof -from lbryschema.hashing import double_sha256 +from lbrynet.schema.hashing import double_sha256 class ClaimProofsTestCase(unittest.TestCase):