This repository has been archived by the owner on Jan 12, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 28
ApiIntersect - Ignore unresolved assemblies by default #163
Merged
kzu
merged 1 commit into
NuGet:dev
from
mrward:api-intersect-ignore-unresolved-assemblies
Aug 26, 2018
Merged
ApiIntersect - Ignore unresolved assemblies by default #163
kzu
merged 1 commit into
NuGet:dev
from
mrward:api-intersect-ignore-unresolved-assemblies
Aug 26, 2018
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Running ApiIntersect on an Android project will fail to resolve the MonoAndroid assembly. Since this assembly is not required and should not be included in the generated classes a new argument has been added to the ApiIntersect tool so unresolved assemblies can be ignored and the classes can be generated without an exception being thrown. This prevents the ApiIntersect.exe error on building: NuGet.Build.Packaging.ReferenceAssembly.targets(3,3): Error MSB6006: "ApiIntersect.exe" exited with code 1. (MSB6006) With verbose msbuild logging the ApiIntersect crash is: Unhandled Exception: System.Exception: Could not resolve Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=84e04ff9cfb79065 at ApiIntersect.FrameworkAssemblyResolver.Resolve (Mono.Cecil.AssemblyNameReference name, Mono.Cecil.ReaderParameters parameters) [0x0001b] in <aac3e0d5bcd4473a96e385115da49b96>:0 at ApiIntersect.FrameworkAssemblyResolver.Resolve (Mono.Cecil.AssemblyNameReference name) [0x00000] in <aac3e0d5bcd4473a96e385115da49b96>:0 at ICSharpCode.Decompiler.Ast.Transforms.IntroduceUsingDeclarations.Run (ICSharpCode.NRefactory.CSharp.AstNode compilationUnit) [0x00142] in <37b5ad8a7a94479fbc5b574a8fc6281a>:0 at ICSharpCode.Decompiler.Ast.Transforms.TransformationPipeline.RunTransformationsUntil (ICSharpCode.NRefactory.CSharp.AstNode node, System.Predicate`1[T] abortCondition, ICSharpCode.Decompiler.DecompilerContext context) [0x0002c] in <37b5ad8a7a94479fbc5b574a8fc6281a>:0 at ICSharpCode.Decompiler.Ast.AstBuilder.RunTransformations (System.Predicate`1[T] transformAbortCondition) [0x00000] in <37b5ad8a7a94479fbc5b574a8fc6281a>:0 at ICSharpCode.Decompiler.Ast.AstBuilder.RunTransformations () [0x00000] in <37b5ad8a7a94479fbc5b574a8fc6281a>:0 at ApiIntersect.MainClass.DumpTypes (System.Collections.Generic.List`1[T] types, System.String baseDir) [0x000a7] in <aac3e0d5bcd4473a96e385115da49b96>:0 at ApiIntersect.MainClass.Process (System.Collections.Generic.List`1[T] intersections, System.Collections.Generic.List`1[T] exclusions, Mono.Cecil.ReaderParameters readerParameters, System.String outputPath) [0x00319] in <aac3e0d5bcd4473a96e385115da49b96>:0 at ApiIntersect.MainClass.Main (System.String[] args) [0x0039f] in <aac3e0d5bcd4473a96e385115da49b96>:0
kzu
approved these changes
Jul 24, 2018
The build failure seems to have been happening with other builds and seems unrelated to this change.
|
The failure are two failed unit tests. I'll take a look next week. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Running ApiIntersect on an Android project will fail to resolve the
MonoAndroid assembly. Since this assembly is not required and should
not be included in the generated classes a new argument has been
added to the ApiIntersect tool so unresolved assemblies can be
ignored and the classes can be generated without an exception
being thrown. This prevents the ApiIntersect.exe error on building:
With verbose msbuild logging the ApiIntersect crash is:
Note that the missing assembly references will be reported by MSBuild as warnings so this information is not hidden from the user.