Return-Path: Received: from smtp4.osuosl.org (smtp4.osuosl.org [IPv6:2605:bc80:3010::137]) by lists.linuxfoundation.org (Postfix) with ESMTP id AB91DC0001 for ; Tue, 18 May 2021 13:10:20 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp4.osuosl.org (Postfix) with ESMTP id A76E7405DF for ; Tue, 18 May 2021 13:10:20 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org X-Spam-Flag: NO X-Spam-Score: -2.299 X-Spam-Level: X-Spam-Status: No, score=-2.299 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, FROM_LOCAL_NOVOWEL=0.5, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no Authentication-Results: smtp4.osuosl.org (amavisd-new); dkim=pass (1024-bit key) header.d=protonmail.com Received: from smtp4.osuosl.org ([127.0.0.1]) by localhost (smtp4.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id nNza_I5exEH8 for ; Tue, 18 May 2021 13:10:18 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.8.0 Received: from mail-40140.protonmail.ch (mail-40140.protonmail.ch [185.70.40.140]) by smtp4.osuosl.org (Postfix) with ESMTPS id 922FF40266 for ; Tue, 18 May 2021 13:10:18 +0000 (UTC) Date: Tue, 18 May 2021 13:10:12 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail; t=1621343415; bh=kQl3Dosa1XslK8gCpENYH8hz2W3HDaTgj/MXyFRoXew=; h=Date:To:From:Cc:Reply-To:Subject:In-Reply-To:References:From; b=mfM6n2SzeyT77gYHFMx8S5BHJLt5+J/wPU5d9+Nwyh1x/9Ev9H6i/XASfFzi7cciw T9PqiLYvOVIQ5jBqJsdglhvrwjVeNosJ3jnGJrpx64v7RIayFr4wYFrRs42Grpi/cK 97uHU5jpfL3VJDvswYI3HdBeZpyKkyDPQTeJmO68= To: Prayank From: ZmnSCPxj Reply-To: ZmnSCPxj Message-ID: <0e_yUTTdaV57Dxzome846NEUsmp2MmrY19-7OWHGyNw0g5IKwkfTR3jN4xLLYNgy_PMya1BkutZLmfZEdsYyARFHM3zp5qZ_eH1DvefS8uw=@protonmail.com> In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Cc: Bitcoin Dev Subject: Re: [bitcoin-dev] Fee estimates and RBF X-BeenThere: bitcoin-dev@lists.linuxfoundation.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Bitcoin Protocol Discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 May 2021 13:10:20 -0000 Good morning Prayank, > But it will involve lot of exception handling. Yes, that is precisely the problem here. If you select a fixed feerate and then just broadcast-and-forget, you have = no real exceptions you have to handle --- but that means not using RBF at a= ll. Testing the handling of reorgs in particular is important, as a reorg might= use an older version of an RBFed transaction rather than a newer version. This also implies that further follow-up transactions might need to be recr= eated in such a case. As this is financial code, we need a lot of testing, and code that has a lo= t of branches due to having to handle a lot of possible exceptions and so f= orth is a headache to completely cover in testing. C-lightning supposedly supports RBF, in the sense that every transaction it= makes always signals RBF, but I am almost certain there are edge cases whe= re it might mishandle a replaced transaction and lose track of onchain fund= s, and it is difficult to support both "we can spend unconfirmed change out= puts" (a very common feature of nearly every onchain wallet) with "we can c= hange the feerate of unconfirmed transactions" (which changes the txid and = therefore the UTXO id of the change output spent by use of the previous fea= ture). Regards, ZmnSCPxj