The new vin feature in api/tx introduced in API version 1.2 doesn't work unless you have Bitcoin Core 22 or newer.
Environment (please complete the following information):
Bitcoin Core / Node Version [e.g. 0.16.3]
Core 21.2 or earlier (also reproduced with 19 and 20)
NodeJS Version [e.g. 9.x]
v16
Browser [e.g. chrome, safari]
Any
Code Version / Commit [e.g. ab6cde8]
cf982d340c
Installation Method [e.g. "npm" or "source code"]
npm start
Configuration file content
Not important
To Reproduce
Steps to reproduce the behavior:
Use any recent tx id and call the api/tx endpoint
Additional context
It's not clear to me where in the code the problem is. I have noticed that Bitcoin Core 22 has some changes to the rpc responses for relevant methods like getrawtransaction. So, the code is probably looking for the address in the wrong location in the json response from Core.
I'm not implying this needs to be fixed. It's more informational for others who might be wondering why the input addresses are not returned by the api/tx endpoint.
Describe the bug
The new vin feature in api/tx introduced in API version 1.2 doesn't work unless you have Bitcoin Core 22 or newer.
Environment (please complete the following information):
Configuration file content Not important
To Reproduce
Steps to reproduce the behavior:
Additional context It's not clear to me where in the code the problem is. I have noticed that Bitcoin Core 22 has some changes to the rpc responses for relevant methods like getrawtransaction. So, the code is probably looking for the address in the wrong location in the json response from Core.