diff --git a/DistTestCore/Marketplace/GethInfoExtractor.cs b/DistTestCore/Marketplace/GethInfoExtractor.cs index 59725ec..7151a60 100644 --- a/DistTestCore/Marketplace/GethInfoExtractor.cs +++ b/DistTestCore/Marketplace/GethInfoExtractor.cs @@ -40,7 +40,7 @@ namespace DistTestCore.Marketplace private string Retry(Func fetch) { - var result = fetch(); + var result = Catch(fetch); if (string.IsNullOrEmpty(result)) { Thread.Sleep(TimeSpan.FromSeconds(5)); @@ -49,6 +49,18 @@ namespace DistTestCore.Marketplace return result; } + private string Catch(Func fetch) + { + try + { + return fetch(); + } + catch + { + return string.Empty; + } + } + private string FetchGenesisJson() { return workflow.ExecuteCommand(container, "cat", GethContainerRecipe.GenesisFilename);