You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/msbuild/errors/msb3277.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -26,15 +26,15 @@ This article describes the MSB3277 error code.
26
26
27
27
## Description
28
28
29
-
This error occurs during a build when more than one version of the same dependent assembly is referenced in a build of the same project. In a .NET build, all assemblies that are referenced, directly or indirectly through other referenced assemblies, have to resolve to the same version. You can't reference two different and conflicting versions of the same assembly when building the same binary. The error is emitted by the [ResolveAssemblyReference task](../resolveassemblyreference-task.md), which looks at all the referenced assemblies, and all assemblies referenced indirectly by those assemblies, and so on, until all assembly references are resolved.
29
+
This error occurs during a build when more than one version of the same dependent assembly is referenced in a build of the same project. In a .NET build, all assemblies that are referenced, directly or indirectly through other referenced assemblies, have to resolve to the same version. You can't reference two different and conflicting versions of the same assembly when building the same binary. The [ResolveAssemblyReference task](../resolveassemblyreference-task.md) emits this error. The task inspects all the referenced assemblies, and all assemblies referenced indirectly by those assemblies, and so on. The task works through the process until all assembly references are resolved.
30
30
31
31
## Diagnose the error
32
32
33
33
To diagnose the error, first enable diagnostic log output by using the `-verbosity:diag` command-line switch, and then check the MSBuild log file with the full diagnostics output. For longer output logs on large projects, consider using the binary log `-bl` command-line switch and the [MSBuild Structured Log Viewer](https://msbuildlog.com/) to view the output more easily.
34
34
35
-
In MSBuild 16.x or later, the specific assembly versions in conflict are written to the log file. In earlier versions of MSBuild, the content isn't added to the log file. Instead, follow the assembly dependency chain to locate the conflicting reference. Look at each assembly that your project references, and then the assemblies that the initial assemblies reference, and so on. Follow this process until you identify the conflicting assembly version(s).
35
+
In MSBuild 16.x or later, the specific assembly versions in conflict are written to the log file. In earlier versions of MSBuild, the content isn't added to the log file. Instead, follow the assembly dependency chain to locate the conflicting reference. Look at each assembly that your project references, and then the assemblies that the initial assemblies reference, and so on. Follow this process until you identify the conflicting assembly versions.
36
36
37
-
The diagnostics log should identify the specific assembly version(s) that are in conflict and the reason for the conflict(s). For example, a reference to *assembly1.dll*, which references *assembly2.dll* version **x**, but also references *assembly2.dll* version **y**. MSBuild can't determine which version to use for the assembly.
37
+
The diagnostics log should identify the specific assembly versions that are in conflict and the reasons for the conflicts. For example, a reference to *assembly1.dll*, which references *assembly2.dll* version **x**, but also references *assembly2.dll* version **y**. MSBuild can't determine which version to use for the assembly.
38
38
39
39
The following example is an excerpt from a diagnostic log showing a conflict between two versions of `StreamJsonRpc`:
40
40
@@ -84,11 +84,11 @@ How you resolve this issue depends on your project configuration and assembly de
84
84
85
85
- Update the version of an assembly on disk by upgrading or reinstalling a NuGet package or SDK.
86
86
- Update all packages to the latest versions with the `Update-Package -reinstall` command in the Package Manager Console for Visual Studio. For more information, see [Reinstalling and updating packages](/nuget/consume-packages/reinstalling-and-updating-packages).
87
-
- For projects with multiple versions of a referenced assembly on disk, update the projec or the dependencies to reference the latest version of the installed conflicting assembly. The Global Assembly Cache (GAC) might also be a source of a potential conflict, in cases where you reference a specific version of an assembly, but the GAC overrides it. For more information, see [Global Assembly Cache](/dotnet/framework/app-domains/gac).
87
+
- For projects with multiple versions of a referenced assembly on disk, update the project or the dependencies to reference the latest version of the installed conflicting assembly. The Global Assembly Cache (GAC) might also be a source of a potential conflict, in cases where you reference a specific version of an assembly, but the GAC overrides it. For more information, see [Global Assembly Cache](/dotnet/framework/app-domains/gac).
88
88
89
89
## External components
90
90
91
-
If the conflict is in a non-Microsoft component, the component might not be supported with the version of the conflicting assembly you're using in your project. Look to the provider of the other component to see if they offer an updated, compatible version. If a fix isn't available, the solution might be to downgrade the version of the conflicting assembly you're referencing to match the version that the other component uses.
91
+
If the conflict is in a non-Microsoft component, the component might not be supported with the version of the conflicting assembly you're using in your project. Check the provider of the other component to see if they offer an updated, compatible version. If a fix isn't available, the solution might be to downgrade the version of the conflicting assembly you're referencing to match the version that the other component uses.
Copy file name to clipboardExpand all lines: docs/msbuild/errors/msb3305.md
+1-4Lines changed: 1 addition & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -43,10 +43,7 @@ As a temporary measure, you can silence the warning by adding the following valu
43
43
```
44
44
45
45
> [!WARNING]
46
-
> As you work to resolve this MSBuild error, avoid some common techniques that can cause you to miss vital information:
47
-
>
48
-
> - Suppression of MSBuild diagnostic information
49
-
> - Use of the `ResolveComReferenceSilent` property to hide the MSB3305 warning
46
+
> We don't recommend suppressing MSBuild diagnostic information. Eliminating the warning doesn't address the underlying problem. Using the ResolveComReferenceSilent property to hide the warning might also hide other COM reference warnings you don't intend to suppress.
50
47
51
48
For more information, see [Add references to type libraries](/dotnet/framework/interop/how-to-add-references-to-type-libraries).
0 commit comments