Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for testnet4 #136

Merged
merged 2 commits into from
Aug 22, 2024
Merged

Add support for testnet4 #136

merged 2 commits into from
Aug 22, 2024

Conversation

sstone
Copy link
Member

@sstone sstone commented Aug 21, 2024

See bitcoin/bitcoin#29775.
It basically adds a new genesis block the testnet4 (addresses uses the same prefixes/encoding as testnet3).

@sstone sstone mentioned this pull request Aug 21, 2024
@sstone sstone added this to the 0.20.0 milestone Aug 21, 2024
Copy link
Member

@t-bast t-bast left a comment

Choose a reason for hiding this comment

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

If I understand correctly, we're waiting for a release of Bitcoin Core that includes testnet4 to merge this, right?

src/commonMain/kotlin/fr/acinq/bitcoin/Block.kt Outdated Show resolved Hide resolved
@sstone
Copy link
Member Author

sstone commented Aug 22, 2024

If I understand correctly, we're waiting for a release of Bitcoin Core that includes testnet4 to merge this, right?

Bitcoin core's master branch already includes support for testnet4, there are testnet4 explorers and electrum servers, and it's unlikely that the testnet4 genesis block will change so we could also merge now. There would not be much of a LN testnet4 network so we'd probably need to keep running a testnet3 node for a while, but it would help a lot to have a testnet4 version of Phoenix for our own tests.

@t-bast
Copy link
Member

t-bast commented Aug 22, 2024

There would not be much of a LN testnet4 network so we'd probably need to keep running a testnet3 node for a while, but it would help a lot to have a testnet4 version of Phoenix for our own tests.

I don't understand how it can help with our tests: we require a trampoline node for phoenix and phoenixd, and that trampoline node requires a Bitcoin Core node. So we'd need a Bitcoin Core node that supports testnet4, right? The Bitcoin Core master branch is notoriously buggy, we're going to have issues unrelated to lightning if we run with a non-released version (Richard tried that recently and had coin selection issues that made eclair unusable), so it's not going to help us much? Or do you want to try that option anyway and run a testnet4 node based on Bitcoin Core master?

This is a breaking change as it will force uses to explicitly select which testnet network they want to use, but it's cleaner this way.
@sstone
Copy link
Member Author

sstone commented Aug 22, 2024

There would not be much of a LN testnet4 network so we'd probably need to keep running a testnet3 node for a while, but it would help a lot to have a testnet4 version of Phoenix for our own tests.

I don't understand how it can help with our tests: we require a trampoline node for phoenix and phoenixd, and that trampoline node requires a Bitcoin Core node. So we'd need a Bitcoin Core node that supports testnet4, right? The Bitcoin Core master branch is notoriously buggy, we're going to have issues unrelated to lightning if we run with a non-released version (Richard tried that recently and had coin selection issues that made eclair unusable), so it's not going to help us much? Or do you want to try that option anyway and run a testnet4 node based on Bitcoin Core master?

Yes most LN tests would be done on testnet3, but for specific phoenix tests we'd run Bitcoin Core's master branch with all the caveats you mentioned.

@sstone sstone marked this pull request as ready for review August 22, 2024 09:16
Copy link
Member

@t-bast t-bast left a comment

Choose a reason for hiding this comment

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

Sounds good, let's do that then 👍

@sstone sstone merged commit 70d7fee into master Aug 22, 2024
4 checks passed
@sstone sstone deleted the snapshot/testnet4 branch August 22, 2024 09:47
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.

2 participants