james-rms 758ec96d6d beacon-chain: fix segfault (#7822)
Observed this segfault running all tests on mater, occurring
in around 2-3 out of 10 test runs.

```
FAIL: //beacon-chain/sync:go_default_test (shard 3 of 4, run 1 of 10) (see /home/j/.cache/bazel/_bazel_j/1ba834ca9d49f27aeb8f0bbb6f28fdf3/execroot/prysm/bazel-out/k8-fastbuild/testlogs/beacon-chain/sync/go_default_test/shard_3_of_4_run_1_of_10/test.log)
INFO: From Testing //beacon-chain/sync:go_default_test (shard 3 of 4, run 1 of 10):
==================== Test output for //beacon-chain/sync:go_default_test (shard 3 of 4, run 1 of 10):
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x138eea6]

goroutine 1660 [running]:
github.com/prysmaticlabs/prysm/shared/abool.(*AtomicBool).IsSet(...)
	shared/abool/abool.go:39
github.com/prysmaticlabs/prysm/beacon-chain/sync.(*Service).subscribeStaticWithSubnets.func1(0xc002dd4400, 0xc002990940, 0x17bca26, 0x1e)
	beacon-chain/sync/subscriber.go:207 +0xe6
created by github.com/prysmaticlabs/prysm/beacon-chain/sync.(*Service).subscribeStaticWithSubnets
	beacon-chain/sync/subscriber.go:200 +0x172
================================================================================
```

TestStaticSubnets was testing a Service with an uninitialized
chainStarted value. This commit initializes chainStarted explicitly
in all tests that construct a Service. This reduces the observed flake
rate to 0/10 runs. This was verified with:

```
./bazel.sh test //beacon-chain/sync:go_default_test --runs_per_test 10
```
2020-11-16 12:10:34 +01:00
2020-11-10 03:01:56 +00:00
2020-11-13 01:00:05 +00:00
2020-11-10 03:01:56 +00:00
2020-10-26 21:17:07 +00:00
2020-11-10 03:01:56 +00:00
2020-10-08 18:37:12 +00:00
2019-07-22 14:10:17 -05:00
2020-03-06 17:43:06 +00:00
2020-11-13 14:52:27 +00:00
2020-11-13 14:52:27 +00:00
2020-11-13 14:52:27 +00:00
2020-01-25 06:25:58 -08:00
2018-07-20 10:23:48 -05:00
2020-11-11 14:40:24 +00:00
2019-10-23 17:53:33 +08:00
2019-07-19 19:16:10 -05:00

Prysm: An Ethereum 2.0 Client Written in Go

Build status Go Report Card ETH2.0_Spec_Version 0.12.3 Discord

This is the core repository for Prysm, a Golang implementation of the Ethereum 2.0 client specifications developed by Prysmatic Labs.

Getting Started

A detailed set of installation and usage instructions as well as breakdowns of each individual component are available in the official documentation portal. If you still have questions, feel free to stop by our Discord.

Come join the testnet!

Participation is now open to the public for our Ethereum 2.0 phase 0 testnet release. Visit prylabs.net for more information on the project or to sign up as a validator on the network. You can visualize the nodes in the network on eth2stats.io, explore validator rewards/penalties via Bitfly's block explorer: beaconcha.in, and follow the latest blocks added to the chain on beaconscan.

Contributing

Want to get involved? Check out our Contribution Guide to learn more!

License

GNU General Public License v3.0

Description
No description provided
Readme 886 MiB
Languages
Go 95.3%
Starlark 4.1%
Shell 0.4%
Smarty 0.1%