Open mrfelton opened 3 years ago
Grpc.Core hasn't been released since that PR was merged, as far as I can tell - so I don't think there's anything we can do at the moment. (Once it has been released, you don't need to wait for an update to this library - you can just add an explicit dependency on the latest version of Grpc.Core in your project.)
<PackageReference Include="Grpc.Core" Version="2.33.1" />
@jskeet you say mean like this?
@Newp: Exactly, but I didn't think it was fixed in 2.33.1...
I can confirm that it isn't. @jskeet any estimate when the fix will be released? Thanks
No, I don't work on gRPC. I suggest you ask on the linked issue.
Meanwhile, you can work around the issue by installing libc-dev:
sudo apt update && sudo apt install -y libc-dev
And for CentOS:
yum -y install glibc-devel
I'm using Google.Cloud.Diagnostics.AspNetCore and I'm also getting the same mentioned exception on top when calling services.AddGoogleExceptionLogging after I switched to dotnet 5.0.
As a fix also mentioned here I have installed separately Grpc.Core package of version 2.35.0 and now I'm getting this exception
---> System.IO.FileLoadException: Could not load file or assembly 'Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed'. The located assembly's manifest definition does not match the assembly reference. (0x80131040)
at Google.Api.Gax.GkePlatformDetails.TryLoad(String metadataJson, KubernetesData kubernetesData)
at Google.Api.Gax.Platform.LoadInstanceAsync()
at System.Threading.Tasks.Task1.GetResultCore(Boolean waitCompletionNotification) at System.Threading.Tasks.Task
1.get_Result()
at Google.Api.Gax.Platform.Instance()
at Google.Api.Gax.Grpc.MonitoredResourceBuilder.FromPlatform()
at Google.Cloud.Diagnostics.Common.EventTarget.ForLogging(LogTarget logTarget, String logName, LoggingServiceV2Client loggingClient, MonitoredResource monitoredResource)
at Google.Cloud.Diagnostics.Common.EventTarget.ForLogging(String projectId, String logName, LoggingServiceV2Client loggingClient, MonitoredResource monitoredResource)
at Google.Cloud.Diagnostics.Common.ErrorReportingOptions.Create(String projectId, BufferOptions bufferOptions, RetryOptions retryOptions)
at Google.Cloud.Diagnostics.Common.ErrorReportingContextExceptionLogger.Create(String projectId, String serviceName, String version, ErrorReportingOptions options)
at Google.Cloud.Diagnostics.Common.ContextExceptionLogger.Create(String projectId, String serviceName, String version, ErrorReportingOptions options)
at Google.Cloud.Diagnostics.AspNetCore.ErrorReportingExceptionLoggerExtension.AddGoogleExceptionLogging(IServiceCollection services, Action`1 setupAction)
...
@sergiutugulschi: Please file a new issue with more details, given that the expected workaround isn't working for you. Additionally, unless you're actually using one of the packages in this repo, please file the issue in https://github.com/googleapis/google-cloud-dotnet rather than here.
Got the same error. These two below worked for me.
<PackageReference Include="Google.Cloud.Diagnostics.AspNetCore3" Version="4.2.0" /> <PackageReference Include="Grpc.Core" Version="2.36.4" />
In my case this error was caused by a reference to an older version of Google.Cloud.SecretManager.V1
. Upgrading from 1.0.0
to 1.4.0
fixed the problem.
Getting the following error when running in a docker images that uses
mcr.microsoft.com/dotnet/sdk:5.0
.I think the grpc dependency needs updating.
See https://github.com/grpc/grpc/pull/24485