Would it be useful to add base58Prefixes and other consensus/chainparams in an rpc (getblockchaininfo or other)? This could help people building external applications that connect to a bitcoin node and avoid having to hardcode all these parameters.
-
nkostoulas commented at 4:47 PM on December 10, 2019: contributor
- nkostoulas added the label Feature on Dec 10, 2019
- MarcoFalke added the label RPC/REST/ZMQ on Dec 10, 2019
-
MarcoFalke commented at 4:59 PM on December 10, 2019: member
No objection, but also not sure if it makes sense to serve static const data over a remote call
-
laanwj commented at 12:49 PM on December 11, 2019: member
but also not sure if it makes sense to serve static const data over a remote call
Agree. I think hardcoding (or at least, having your own constants for these in your applications) these things makes a lot of sense because they're not going to change without a reason you probably need to be aware of!
(Say, in the unlikely case that there would be a new kind of base58 address format, you wouldn't want your application to silently start accepting them without at least having looked over it. Doing so might lead to funds loss.)
-
nkostoulas commented at 1:45 PM on December 11, 2019: contributor
Well I believe there are applications where you don't really care about the value changing, you just need to be sure that the address/key you are deriving or using will be later accepted by a bitcoin node. But I guess you are right it's just a couple of consts that never change. I kinda envisioned that more on the Elements case to be honest, where you could end up with multiple chains and you needed to avoid hardcoding everything all over again.
-
MarcoFalke commented at 10:45 PM on April 26, 2020: member
The feature request didn't seem to attract much attention in the past. Also, the issue seems not important enough right now to keep it sitting around idle in the list of open issues.
Closing due to lack of interest. Pull requests with improvements are always welcome.
- MarcoFalke closed this on Apr 26, 2020
- DrahtBot locked this on Feb 15, 2022