neo-go/pkg
Roman Khimov 92e3474f6e core: take an addblock lock on exit
Prevent this:

2021-08-12T15:24:00.750+0300    INFO    shutting down service   {"service": "Prometheus", "endpoint": ":2112"}
2021-08-12T15:24:00.752+0300    INFO    shutting down service   {"service": "Pprof", "endpoint": ":2113"}
2021-08-12T15:24:00.868+0300    INFO    blockchain persist completed    {"persistedBlocks": 14, "persistedKeys": 3145, "headerHeight": 7806078, "blockHeight": 7794173, "took": "652.243264ms"}
2021-08-12T15:24:00.974+0300    INFO    blockchain persist completed    {"persistedBlocks": 1, "persistedKeys": 259, "headerHeight": 7806078, "blockHeight": 7794174, "took": "221.955904ms"}
panic: assignment to entry in nil map

goroutine 132 [running]:
github.com/nspcc-dev/neo-go/pkg/core/storage.(*MemoryStore).drop(...)
        github.com/nspcc-dev/neo-go/pkg/core/storage/memory_store.go:71
github.com/nspcc-dev/neo-go/pkg/core/storage.(*MemoryStore).Delete(0xc0002889c0, 0xc022642060, 0x21, 0x30, 0x21, 0xc022642060)
        github.com/nspcc-dev/neo-go/pkg/core/storage/memory_store.go:79 +0x9c
github.com/nspcc-dev/neo-go/pkg/core/mpt.(*Trie).updateRefCount(0xc00029cd50, 0x70945b6e05b4ce98, 0xb058a7450d307de5, 0x660ef5aff9146084, 0x1293434e970256e5, 0xc000000001)
        github.com/nspcc-dev/neo-go/pkg/core/mpt/trie.go:410 +0x257
github.com/nspcc-dev/neo-go/pkg/core/mpt.(*Trie).Flush(0xc00029cd50)
        github.com/nspcc-dev/neo-go/pkg/core/mpt/trie.go:370 +0x23a
github.com/nspcc-dev/neo-go/pkg/core.(*Blockchain).storeBlock(0xc0002c6000, 0xc022476500, 0x0, 0xd6b100)
        github.com/nspcc-dev/neo-go/pkg/core/blockchain.go:869 +0x3ac5
github.com/nspcc-dev/neo-go/pkg/core.(*Blockchain).AddBlock(0xc0002c6000, 0xc022476500, 0x0, 0x0)
        github.com/nspcc-dev/neo-go/pkg/core/blockchain.go:446 +0xeb
github.com/nspcc-dev/neo-go/pkg/network.(*blockQueue).run(0xc0001e1ad0)
        github.com/nspcc-dev/neo-go/pkg/network/blockqueue.go:48 +0x168
created by github.com/nspcc-dev/neo-go/pkg/network.(*Server).Start
        github.com/nspcc-dev/neo-go/pkg/network/server.go:183 +0x25d

Which then leads to broken DB.
2021-08-12 16:49:29 +03:00
..
compiler Merge pull request #1096 from nspcc-dev/neox-2.x 2020-06-24 16:08:19 +03:00
config core: turn off GAS generation at 8M height 2021-08-04 17:00:13 +03:00
consensus consensus: flush previous proposal on new block 2021-02-18 15:45:34 +03:00
core core: take an addblock lock on exit 2021-08-12 16:49:29 +03:00
crypto keys: add support for uncompressed serialization in PublicKey 2020-06-10 19:17:08 +03:00
encoding *: move all packages from CityOfZion to nspcc-dev 2020-03-03 17:21:42 +03:00
internal random: make use or random package in tests 2020-03-27 10:27:46 +03:00
interop interop: fix key recovery functions documentation 2020-06-25 14:30:53 +03:00
io io: allow to restrict string size 2021-02-18 15:36:22 +03:00
network network: fix Ping messages 2021-08-06 11:31:31 +03:00
rpc result: fix confirmations count for blocks 2021-02-18 17:28:19 +03:00
smartcontract smartcontract: add JSON marshal/unmarshal for InteropType 2020-05-13 17:17:41 +03:00
util fixedn: always correctly unmarshal Fixed8 values 2021-02-18 15:38:02 +03:00
vm vmcli: return after error in break 2020-12-31 12:51:01 +03:00
wallet wallet: check for t.GetSignedPart() result correctness 2020-05-07 21:48:45 +03:00