Explorer 2: "MultiChain is not running: unknown url type: 127.0.0.1" exception

+1 vote

Hello,

I am having an issue with multichain explorer 2. The chain is running and the multichaincli too (tested those). The configuration files were edited as explained in github but I am runinng into the issue that the status of the chain (named chain1) is displaying "no connection" and the exception "MultiChain is not running: unknown url type: 127.0.0.1" appears when I click chain1. (both the chain and the explorer are running in the same machine)

Edit1: We have the exception:

Exception occurred during processing of request from ('127.0.0.1', 44180)
Traceback (most recent call last):
  File "/usr/lib/python3.10/socketserver.py", line 316, in _handle_request_noblock
    self.process_request(request, client_address)
  File "/usr/lib/python3.10/socketserver.py", line 347, in process_request
    self.finish_request(request, client_address)
  File "/usr/lib/python3.10/socketserver.py", line 360, in finish_request
    self.RequestHandlerClass(request, client_address, self)
  File "/usr/lib/python3.10/socketserver.py", line 747, in __init__
    self.handle()
  File "/usr/lib/python3.10/http/server.py", line 432, in handle
    self.handle_one_request()
  File "/usr/lib/python3.10/http/server.py", line 420, in handle_one_request
    method()
  File "/home/shereen/Downloads/multichain-explorer-2-master/server.py", line 94, in do_GET
    content=self.handler(self.chain,self.params,self.nparams)
  File "/home/shereen/Downloads/multichain-explorer-2-master/data.py", line 383, in handle_chains
    response=chain.request("getchaintotals",[])
  File "/home/shereen/Downloads/multichain-explorer-2-master/multichain.py", line 137, in request
    req_json=json.loads(resp.decode('utf-8'))
  File "/usr/lib/python3.10/json/__init__.py", line 346, in loads
    return _default_decoder.decode(s)
  File "/usr/lib/python3.10/json/decoder.py", line 337, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "/usr/lib/python3.10/json/decoder.py", line 355, in raw_decode
    raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

The exception text is: HTTP Error 401: Unauthorized

asked Nov 16 by engshereenismail

1 Answer

0 votes

Assuming that the node is running on a different server to the Explorer, you need to use a setting in the node's configuration to allow access from the other server's IP address. Search this forum for rpcallowip and you'll find lots of answers.

answered Nov 17 by MultiChain
...