diff --git a/tools/Kute/Nethermind.Tools.Kute/Program.cs b/tools/Kute/Nethermind.Tools.Kute/Program.cs index 6c640ab0f808..e4bd6d9bcfa1 100644 --- a/tools/Kute/Nethermind.Tools.Kute/Program.cs +++ b/tools/Kute/Nethermind.Tools.Kute/Program.cs @@ -14,6 +14,7 @@ using Nethermind.Tools.Kute.SecretProvider; using Nethermind.Tools.Kute.SystemClock; using System.CommandLine; +using System.Net; namespace Nethermind.Tools.Kute; @@ -56,7 +57,18 @@ private static IServiceProvider BuildServiceProvider(ParseResult parseResult) collection.AddSingleton(); collection.AddSingleton(); - collection.AddSingleton(); + collection.AddSingleton(_ => + { + // Disable proxy auto-detection to avoid timeout (~2s) on Windows. + // Each Kute invocation is a separate process, so the proxy lookup + // would otherwise be paid on every single measured request. + var handler = new SocketsHttpHandler + { + UseProxy = false, + AutomaticDecompression = DecompressionMethods.None, + }; + return new HttpClient(handler); + }); collection.AddSingleton(new FileSecretProvider(parseResult.GetValue(Config.JwtSecretFilePath)!)); collection.AddSingleton(provider => new TtlAuth(