diff --git a/source/Octopus.Tentacle.Client/TentacleClient.cs b/source/Octopus.Tentacle.Client/TentacleClient.cs index ad32af085..58b1f4580 100644 --- a/source/Octopus.Tentacle.Client/TentacleClient.cs +++ b/source/Octopus.Tentacle.Client/TentacleClient.cs @@ -37,8 +37,8 @@ public static void CacheServiceWasNotFoundResponseMessages(IHalibutRuntime halib var innerHandler = halibutRuntime.OverrideErrorResponseMessageCaching; halibutRuntime.OverrideErrorResponseMessageCaching = response => { - if (BackwardsCompatibleCapabilitiesV2Helper.ExceptionTypeLooksLikeTheServiceWasNotFound(response.Error.HalibutErrorType) || - BackwardsCompatibleCapabilitiesV2Helper.ExceptionMessageLooksLikeTheServiceWasNotFound(response.Error.Message)) + if (BackwardsCompatibleCapabilitiesV2Helper.ExceptionTypeLooksLikeTheServiceWasNotFound(response.Error!.HalibutErrorType!) || + BackwardsCompatibleCapabilitiesV2Helper.ExceptionMessageLooksLikeTheServiceWasNotFound(response.Error!.Message)) { return true; } diff --git a/source/Octopus.Tentacle/Communications/TentacleCommunicationsModule.cs b/source/Octopus.Tentacle/Communications/TentacleCommunicationsModule.cs index 1b3c3f114..efa17976e 100644 --- a/source/Octopus.Tentacle/Communications/TentacleCommunicationsModule.cs +++ b/source/Octopus.Tentacle/Communications/TentacleCommunicationsModule.cs @@ -36,7 +36,7 @@ protected override void Load(ContainerBuilder builder) var halibutRuntime = new HalibutRuntimeBuilder() .WithServiceFactory(services) - .WithServerCertificate(configuration.TentacleCertificate) + .WithServerCertificate(configuration.TentacleCertificate!) .WithMessageSerializer(serializerBuilder => serializerBuilder.WithLegacyContractSupport()) .WithHalibutTimeoutsAndLimits(halibutTimeoutsAndLimits) .Build(); diff --git a/source/Octopus.Tentacle/Configuration/ProxyConfigParser.cs b/source/Octopus.Tentacle/Configuration/ProxyConfigParser.cs index 3c4ee0f23..8f4ac1e68 100644 --- a/source/Octopus.Tentacle/Configuration/ProxyConfigParser.cs +++ b/source/Octopus.Tentacle/Configuration/ProxyConfigParser.cs @@ -59,12 +59,12 @@ public class ProxyConfigParser : IProxyConfigParser { log.Info($"Agent will use the octopus configured proxy at {config.CustomProxyHost}:{config.CustomProxyPort} for server at {destination}"); return string.IsNullOrWhiteSpace(config.CustomProxyUsername) - ? new ProxyDetails(config.CustomProxyHost, + ? new ProxyDetails(config.CustomProxyHost!, config.CustomProxyPort, ProxyType.HTTP, null, null) //Don't use default creds for custom proxy if user has not supplied any - : new ProxyDetails(config.CustomProxyHost, + : new ProxyDetails(config.CustomProxyHost!, config.CustomProxyPort, ProxyType.HTTP, config.CustomProxyUsername, diff --git a/source/Octopus.Tentacle/Services/FileTransfer/FileTransferService.cs b/source/Octopus.Tentacle/Services/FileTransfer/FileTransferService.cs index fe92c1f92..1331a9174 100644 --- a/source/Octopus.Tentacle/Services/FileTransfer/FileTransferService.cs +++ b/source/Octopus.Tentacle/Services/FileTransfer/FileTransferService.cs @@ -60,7 +60,7 @@ public async Task DownloadFileAsync(string remotePath, CancellationT public async Task UploadFileAsync(string remotePath, DataStream upload, CancellationToken cancellationToken) { - if (upload == null) + if (upload == null!) { log.Trace("Client requested a file upload, but no content stream was provided."); return new UploadResult(ResolvePath(remotePath), null!, 0);