subscan-explorer / subscan-essentials

Polkadot Substrate Explorer Subscan

Home Page:https://www.subscan.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

assignment to entry in nil map

joshtharakan opened this issue · comments

commented

Was working fine for the past week. Now cannot connect.

WSEndPoint to wss://rpc.polkadot.io/
Also tried with wss://service.elara.patract.io/Polkadot/xxxxxx (my own endpoint in elara)

WSEndPoint                = GetEnv("CHAIN_WS_ENDPOINT", "wss://rpc.polkadot.io/")
NetworkNode               = GetEnv("NETWORK_NODE", "polkadot")

Throws error:

○ → docker logs subscan_subscan-api_1
2021/10/15 17:36:03 start watch filepath: ../configs
panic: Can not find chain metadata, please check network
	panic: assignment to entry in nil map

goroutine 1 [running]:
github.com/itering/scale.go/types.regCustomKey(0xc00009d180, 0xe, 0xbfd180, 0xc00035af20)
	/go/pkg/mod/github.com/itering/scale.go@v1.1.17/types/customType.go:147 +0x4c9
github.com/itering/scale.go/types.RegCustomTypes(0xc000094c90)
	/go/pkg/mod/github.com/itering/scale.go@v1.1.17/types/customType.go:119 +0x25d
github.com/itering/substrate-api-rpc.RegCustomTypes(0xc0000ec000, 0xa41, 0xc41)
	/go/pkg/mod/github.com/itering/substrate-api-rpc@v0.4.3/types.go:9 +0x4d
github.com/itering/subscan/internal/service.(*Service).initSubRuntimeLatest.func1(0xc0004f7070)
	/subscan/internal/service/service.go:42 +0x60
panic(0xb45340, 0xd67af0)
	/usr/local/go/src/runtime/panic.go:969 +0x166
github.com/itering/subscan/internal/service.(*Service).initSubRuntimeLatest(0xc0004f7070)
	/subscan/internal/service/service.go:63 +0x24b
github.com/itering/subscan/internal/service.New(0x80)
	/subscan/internal/service/service.go:27 +0xa1
main.run()
	/subscan/cmd/main.go:82 +0x34
main.setupApp.func1(0xc0000bc000, 0x0, 0x0)
	/subscan/cmd/main.go:37 +0x20
github.com/urfave/cli.HandleAction(0xb554c0, 0xc9ea30, 0xc0000bc000, 0xc0000922a0, 0x0)
	/go/pkg/mod/github.com/urfave/cli@v1.20.0/app.go:490 +0xc8
github.com/urfave/cli.(*App).Run(0xc0000b4000, 0xc0000201e0, 0x1, 0x1, 0x0, 0x0)
	/go/pkg/mod/github.com/urfave/cli@v1.20.0/app.go:264 +0x5dd
main.main()
	/subscan/cmd/main.go:26 +0x71
chain metadata loc: ../configs/source/polkadot.json
commented

related to the recent 0.9.11 release ?

commented

if possible can someone share how to update the type registry to be compatible with the recent change?

commented

@joshtharakan I think it’s a network connection problem, try to use other node point