Post
Topic
Board Bitcoin Technical Support
Re: mempool / electrs install, can load transactions but not addresses
by
szeco
on 12/12/2021, 02:46:56 UTC
Looks like I might be getting somewhere..

Quote
# bitcoin-cli getaddressinfo 1MDkeWhcTzvnZdqPbJDtPgrLp6QHJeAPNm
error code: -18
error message:
No wallet is loaded. Load a wallet using loadwallet or create a new one with createwallet. (Note: A default wallet is no longer automatically created)

Looks like the bitcoin-d install didn't include a wallet and that is required in order to query addresses?? I ran createwallet and it looks OK now.

Quote
# bitcoin-cli createwallet "testwallet"
{
  "name": "testwallet",
  "warning": ""
}

# bitcoin-cli getaddressinfo 1MDkeWhcTzvnZdqPbJDtPgrLp6QHJeAPNm
{
  "address": "1MDkeWhcTzvnZdqPbJDtPgrLp6QHJeAPNm",
  "scriptPubKey": "76a914ddcbf1131395a90e772396e0e5bad51cc2923c7388ac",
  "ismine": false,
  "solvable": false,
  "iswatchonly": false,
  "isscript": false,
  "iswitness": false,
  "ischange": false,
  "labels": [
  ]
}

Inspecting the URL via the Browser dev tools console gets me the same HTTP 500 error
Quote
Request URL: http://mempool.myserver.com/api/address/1MDkeWhcTzvnZdqPbJDtPgrLp6QHJeAPNm
Request Method: GET
Status Code: 500 Internal Server Error
Remote Address: 127.0.0.1:61274
Referrer Policy: strict-origin-when-cross-origin
Access-Control-Allow-Origin: *
Connection: keep-alive
Content-Length: 5
Content-Type: text/html; charset=utf-8
Date: Sun, 12 Dec 2021 00:35:02 GMT
ETag: W/"5-fy9qFc+NorJ+Wkr0e1jnrXHAs9k"
Server: nginx
X-Powered-By: Express
Accept: application/json, text/plain, */*
Accept-Encoding: gzip, deflate
Accept-Language: en-US,en;q=0.9
Connection: keep-alive
Host: mempool.myserver.com
Referer: http://mempool.myserver.com/address/1MDkeWhcTzvnZdqPbJDtPgrLp6QHJeAPNm
Sec-GPC: 1
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.69 Safari/537.36