Network check
> Check whether RPC and GraphQL endpoints are sync and running same currency Same backend implementation, two different usage: - Runs in the background which can be disabled with `-d/--disable-check` general option. The executed command will fail in case of an issue - With `network-check` command to display a table (green or red fields) ### Checks - [x] Check the indexer and RPC endpoints are running the same currency by checking the genesis block hash - [x] Check the indexer and the RPC endpoint are sync: same block number and hash, one block late on the indexer is accepted and should be warned - [x] Indexer type and version compatibility ### Checks at start-up - [x] Run checks at start-up - [x] Checked by default, option to disable check When would a user want to disable the check? To get faster command execution in case we are sure the network is fine (ie checked earlier). Or if we want to hack around. Otherwise, being able to disable the check is convenient for the tests. The tests fails since requests are made twice on the indexer with same function (the network check, then the command it-self) which can be patch once. <!-- Having an optional option allows the user to take the risk to have a network issue or can decide to by-pass the check to have a faster command. --> ### Solution - run check only on `wot` and `money` group of commands - initial check not run on `about`, `licence`, `authentication` and `network-check` commands - `license` and `authentication` commands uses the network to know which currency it is, safe enough to have network issues for these commands to work without issues. - `network-check` commands would run the check twice
issue