From 5b9d41fd5ca310d40fc5ebf54c4b0a1a4cbb4c56 Mon Sep 17 00:00:00 2001 From: Lex Berezhny Date: Sun, 24 Mar 2019 21:47:04 -0400 Subject: [PATCH] regeneate script after modifying protobufs --- lbrynet/extras/daemon/Daemon.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/lbrynet/extras/daemon/Daemon.py b/lbrynet/extras/daemon/Daemon.py index 36165a379..d89e85665 100644 --- a/lbrynet/extras/daemon/Daemon.py +++ b/lbrynet/extras/daemon/Daemon.py @@ -1775,6 +1775,8 @@ class Daemon(metaclass=JSONRPCServerType): else: new_txo.private_key = old_txo.private_key + new_txo.script.generate() + if not preview: await tx.sign([account]) await account.ledger.broadcast(tx) @@ -1923,14 +1925,16 @@ class Daemon(metaclass=JSONRPCServerType): ) claim = Claim() - file_stream = await self.stream_manager.create_stream(file_path) - claim.stream.update(file_path=file_path, hash=file_stream.sd_hash, **kwargs) + claim.stream.update(file_path=file_path, hash='0'*96, **kwargs) tx = await Transaction.claim_create( name, claim, amount, claim_address, [account], account, channel ) new_txo = tx.outputs[0] if not preview: + file_stream = await self.stream_manager.create_stream(file_path) + claim.stream.hash = file_stream.sd_hash + new_txo.script.generate() if channel: new_txo.sign(channel) await tx.sign([account]) @@ -2043,6 +2047,7 @@ class Daemon(metaclass=JSONRPCServerType): if file_path is not None: file_stream = await self.stream_manager.create_stream(file_path) new_txo.claim.stream.hash = file_stream.sd_hash + new_txo.script.generate() if channel: new_txo.sign(channel) await tx.sign([account])