Skip to content

protocol 1.7: outpoint subs#2

Open
SomberNight wants to merge 8 commits into
spesmilo:masterfrom
SomberNight:202502_protocol_next
Open

protocol 1.7: outpoint subs#2
SomberNight wants to merge 8 commits into
spesmilo:masterfrom
SomberNight:202502_protocol_next

Conversation

@SomberNight
Copy link
Copy Markdown
Member

@SomberNight SomberNight commented Feb 6, 2025

This defines a new protocol version: 1.7.

changes compared to 1.6:

  • the blockchain.scripthash.* methods are all replaced with blockchain.scriptpubkey.* methods
  • new RPCs: blockchain.outpoint.subscribe RPC (and related RPCs) to subscribe to a transaction
    outpoint, and get a notification when it gets spent.
  • server.ping can now also be sent as an unrequested notification, by both the client
    and the server. The request/response signature also changed.
  • standardize "history too large" error code for blockchain.scriptpubkey.* methods
  • new RPC: blockchain.transaction.testmempoolaccept
  • new RPC: mempool.recent to list a few of the latest txs just added to the mempool.

This proposal is less ambitious than previous versions of 1.7:

  • most notably witness SPV is postponed
  • the method_flavours field for the server.features response is also postponed,
    as I realised we are not clear re how to signal/negotiate optional features
  • blockchain.outpoint.subscribe requires spk_hint as an input param, to help server impls

We have a client implementation in spesmilo/electrum#10627,
and a server implementation in spesmilo/electrumx#303.

Armanidashh

This comment was marked as spam.

Comment thread docs/protocol-methods.rst
@SomberNight SomberNight force-pushed the 202502_protocol_next branch 2 times, most recently from d32a69e to c10f63f Compare February 17, 2025 17:03
@SomberNight SomberNight force-pushed the 202502_protocol_next branch 2 times, most recently from e74e0f1 to 9e02865 Compare February 21, 2025 17:23
@SomberNight SomberNight force-pushed the 202502_protocol_next branch from 1c30e19 to 337b006 Compare March 10, 2025 18:57
@SomberNight SomberNight modified the milestone: protocol 1.6 Jun 17, 2025
@SomberNight SomberNight force-pushed the 202502_protocol_next branch from f17061d to 7911396 Compare July 29, 2025 15:12
SomberNight added a commit to SomberNight/electrum-protocol that referenced this pull request Oct 22, 2025
This is a minimal changeset for a new protocol version.
The ideas for the less trivial changes are deferred a bit, just so we get something out.

ref spesmilo#2
ref spesmilo/electrumx#90
@SomberNight SomberNight changed the title protocol next (WIP) protocol 1.7 (WIP) Oct 22, 2025
Comment thread docs/protocol-methods.rst Outdated

**Signature**

.. function:: blockchain.outpoint.subscribe(tx_hash, txout_idx, spk_hint=None)
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note: bitcoin core added a txospenderindex, to be used with the gettxspendingprevout RPC.
ref bitcoin/bitcoin#24539

  • see what their API looks like and maybe adapt what we add to that
    • in particular we could put spender_blockhash in the response
    • they also have an option to put the full tx in the response

@SomberNight SomberNight force-pushed the 202502_protocol_next branch 2 times, most recently from 7efc355 to 7eb1d59 Compare April 30, 2026 16:22
Comment thread docs/protocol-methods.rst Outdated
@SomberNight SomberNight force-pushed the 202502_protocol_next branch 2 times, most recently from e4a702a to e3fd26e Compare May 22, 2026 16:27
@SomberNight SomberNight marked this pull request as ready for review May 22, 2026 17:00
@SomberNight SomberNight changed the title protocol 1.7 (WIP) protocol 1.7 May 23, 2026
@SomberNight SomberNight force-pushed the 202502_protocol_next branch from e3fd26e to 1116c35 Compare May 23, 2026 16:01
@SomberNight SomberNight force-pushed the 202502_protocol_next branch from 1116c35 to ed7724a Compare May 23, 2026 17:59
@SomberNight SomberNight force-pushed the 202502_protocol_next branch from ed7724a to acc7d16 Compare May 26, 2026 13:28
@SomberNight SomberNight changed the title protocol 1.7 protocol 1.7: outpoint subs May 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants