[CSHARP-1863] Multiple custom attributes of the same type found error. Created: 06/Dec/16 Updated: 27/Oct/23 Resolved: 28/Apr/17 |
|
| Status: | Closed |
| Project: | C# Driver |
| Component/s: | None |
| Affects Version/s: | 2.4 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Ivan Fioravanti | Assignee: | Robert Stam |
| Resolution: | Works as Designed | Votes: | 1 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
Azure Cloud Service OS Family 5 |
||
| Description |
|
We are having a strange issue, probably related to bug
|
| Comments |
| Comment by Robert Stam [ 28/Apr/17 ] | |||||
|
Closing this as "Works as Designed" since the problem lies with components outside of the .NET Driver. | |||||
| Comment by Mikhail Belov [ 13/Feb/17 ] | |||||
|
Yes, swtiching off the diagnostincs tool helped, but I wouldn't call it "resolved" =). Hope, MS guys will be able to fix it ASAP. | |||||
| Comment by Peter Sunde [ 12/Feb/17 ] | |||||
|
Thanks for the tip Mikhail, uninstalling the application insights status monitor toolkit from all servers resolved the issue | |||||
| Comment by Mikhail Belov [ 11/Feb/17 ] | |||||
|
Application Insights may be the reason: https://github.com/Azure/autorest/issues/1542 Just in case someone else face with this. | |||||
| Comment by Mikhail Belov [ 11/Feb/17 ] | |||||
|
Hi, the same is actual for me too. I have ASP.NET MVC app and it works ok on my laptop on W10 x64 under IIS 10.0.10586.0). Also it works on Windows Server 2012 R2 Azure VM under IIS 8.5. But when I deploy my app to Azure cloud service it doesn't work. Target framework 4.5.2 Here is the stack trace: System.Reflection.AmbiguousMatchException: Multiple custom attributes of the same type found. | |||||
| Comment by Robert Stam [ 22/Dec/16 ] | |||||
|
Any more information on this issue and how to reproduce it? | |||||
| Comment by Robert Stam [ 06/Dec/16 ] | |||||
|
By way of a test, the following code does not throw an exception when run in a console application using .NET Framework 4.6:
| |||||
| Comment by Robert Stam [ 06/Dec/16 ] | |||||
|
Do you know the actual type of the exception? I'm assuming it must be an AmbiguousMatchException. https://msdn.microsoft.com/en-us/library/k7s8054x(v=vs.110).aspx#Exceptions | |||||
| Comment by Robert Stam [ 06/Dec/16 ] | |||||
|
That exception would appear to be coming from here: Could this be a bug in System.Runtime.InteropServices.RuntimeInformation? Why would GetCustomAttribute throw an exception on this line? Does the assembly that contains typeof(object) have multiple AssemblyFileVersionAttributess? |