Is there an existing issue for this?
- I have searched the existing issues
Current behaviour
Sometimes, it is possible to have trailing spaces in a Descriptor and sometimes not. For example:
getdescriptorinfo "wsh(multi(2, KzLnMBHHwTs7uUo9UfUxCboj5Urvigx2v7t6iAqhBk2PM4fBMcig , L1S2VZsNYexzyH76CPi1EvrNSoEHsiT12UaR4BTiycmCKqRnSqLY ))"
Output:
0{
1 "descriptor": "wsh(multi(2,03147a8994e451cb10891688c9db15aea6d62a2691c781678bf7fb3a36e58ccca6,0366b8ab537286e57187eaa8eff803621271500ec496e1e03ef40b9cca6c7a1d1c))#x3mm5nm9",
2 "checksum": "xxgjqes0",
3 "isrange": false,
4 "issolvable": true,
5 "hasprivatekeys": true
6}
getdescriptorinfo "wsh( multi(2, KzLnMBHHwTs7uUo9UfUxCboj5Urvigx2v7t6iAqhBk2PM4fBMcig , L1S2VZsNYexzyH76CPi1EvrNSoEHsiT12UaR4BTiycmCKqRnSqLY ) )"
Output:
0A function is needed within P2WSH (code -5)
getdescriptorinfo "wsh(multi(2, 03147a8994e451cb10891688c9db15aea6d62a2691c781678bf7fb3a36e58ccca6, 0366b8ab537286e57187eaa8eff803621271500ec496e1e03ef40b9cca6c7a1d1c))"
Output:
0Multi: key ' 03147a8994e451cb10891688c9db15aea6d62a2691c781678bf7fb3a36e58ccca6' is not valid (code -5)
Expected behaviour
Consistence: either never allow spaces, or always allow them, but not both.
Steps to reproduce
Open Bitcoin-Qt Console and run the commands above.
Relevant log output
No response
How did you obtain Bitcoin Core
Compiled from source
What version of Bitcoin Core are you using?
master@5f9fd11680af43b0d0d80a6aa4f315aa04afeac4
Operating system and version
Debian 12
Machine specifications
No response