-
Notifications
You must be signed in to change notification settings - Fork 7
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
chore: add btc wallet name to connection config #25
Conversation
walletcontroller/client.go
Outdated
@@ -75,6 +77,7 @@ func NewRpcWalletControllerFromArgs( | |||
// we use post mode as it sure it works with either bitcoind or btcwallet | |||
// we may need to re-consider it later if we need any notifications | |||
HTTPPostMode: true, | |||
Params: params.Name, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure if this was needed, but I saw during debug that it was going to the fallthrough option if not set
// btcd/rpcclient/infrastructure.go
// Default network is mainnet, no parameters are necessary but if mainnet
// is specified it will be the param
switch config.Params {
case "":
fallthrough
case chaincfg.MainNetParams.Name:
client.chainParams = &chaincfg.MainNetParams
case chaincfg.TestNet3Params.Name:
client.chainParams = &chaincfg.TestNet3Params
case chaincfg.RegressionNetParams.Name:
client.chainParams = &chaincfg.RegressionNetParams
case chaincfg.SimNetParams.Name:
client.chainParams = &chaincfg.SimNetParams
default:
return nil, fmt.Errorf("rpcclient.New: Unknown chain %s", config.Params)
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yea, the problem is the upstream btcd
, does not support signet
. So if:
- we do not specify it then for
signet
we will run with&chaincfg.MainNetParams
which for most cases is fine. Though it may, have some weird behaviour when decoding/encoding addresses - if we do specify it then for
signet
staker will not start
For now in most of our programs, we do not specify it so that we are always able to start the programs on signet.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
removed at c6d6b37
walletcontroller/client.go
Outdated
@@ -75,6 +77,7 @@ func NewRpcWalletControllerFromArgs( | |||
// we use post mode as it sure it works with either bitcoind or btcwallet | |||
// we may need to re-consider it later if we need any notifications | |||
HTTPPostMode: true, | |||
Params: params.Name, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yea, the problem is the upstream btcd
, does not support signet
. So if:
- we do not specify it then for
signet
we will run with&chaincfg.MainNetParams
which for most cases is fine. Though it may, have some weird behaviour when decoding/encoding addresses - if we do specify it then for
signet
staker will not start
For now in most of our programs, we do not specify it so that we are always able to start the programs on signet.
…ost url without wallet
No description provided.