I've just downloaded an already working BC extension into my Mac, to try the new AL (2.0.48254) extension, using a Docker with BC version "13.0.24630.24844 (ES)" and I can not compile the extension, due to this error:
macOS: Unexpected value '49184' of type 'Mono.Cecil.TargetArchitecture'
After a bit of investigation, I've found that the error is triggered when I leave a single Codeunit with just this code:
codeunit 50001 Test
{
[EventSubscriber(ObjectType::Codeunit, Codeunit::"Conf./Personalization Mgt.", 'OnRoleCenterOpen', '', true, true)]
local procedure TestMsg()
begin
Message('hello');
end;
}
And it goes away if I remove the [EventSubscriber] attribute.
The full error log is:
Compilation started for project 'Test' containing '1' files at '9:44:40.897'.
error AL0999: Internal error: System.AggregateException: One or more errors occurred. (Unexpected value '49184' of type 'Mono.Cecil.TargetArchitecture') ---> System.InvalidOperationException: Unexpected value '49184' of type 'Mono.Cecil.TargetArchitecture'
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.Cecil.CecilExtensions.GetProcessorArchitecture(ModuleDefinition module) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\Cecil\CecilExtensions.cs:line 392
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.AssemblyLocatorBase.GetAssemblyNameFromPath(String filePath) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\AssemblyLocatorBase.cs:line 390
at System.Collections.Concurrent.ConcurrentDictionary`2.GetOrAdd(TKey key, Func`2 valueFactory)
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.AssemblyLocatorBase.GetPathToCompatibleAssemblyFromCandidates(AssemblyNameAdapter searchName, IEnumerable`1 pathsToAssemblies) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\AssemblyLocatorBase.cs:line 101
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.AssemblyLocatorBase.GetPathToCompatibleAssembly(AssemblyNameAdapter searchName) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\AssemblyLocatorBase.cs:line 69
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.Cecil.CecilAssemblyResolver.Resolve(AssemblyNameReference name, ReaderParameters parameters) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\Cecil\CecilAssemblyResolver.cs:line 40
at Mono.Cecil.MetadataResolver.Resolve(TypeReference type)
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.Cecil.CecilDotNetTypeInfoProvider..ctor(ReaderParameters moduleReaderParameters) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\Cecil\CecilDotNetTypeInfoProvider.cs:line 80
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.Cecil.CecilDotNetTypeLoader.get_TypeInfoProvider() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\Cecil\CecilDotNetTypeLoader.cs:line 48
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.Cecil.CecilDotNetTypeLoader.<LoadAssembly>b__13_0(String assemblyName) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\Cecil\CecilDotNetTypeLoader.cs:line 66
at System.Collections.Concurrent.ConcurrentDictionary`2.GetOrAdd(TKey key, Func`2 valueFactory)
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ReferenceDotNetAssemblyDeclarationSymbol.<>c__DisplayClass4_0.<.ctor>b__2() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Reference\ReferenceDotNetAssemblyDeclarationSymbol.cs:line 62
at System.Lazy`1.ViaFactory(LazyThreadSafetyMode mode)
at System.Lazy`1.ExecutionAndPublication(LazyHelper executionAndPublication, Boolean useDefaultConstructor)
at System.Lazy`1.CreateValue()
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ReferenceDotNetTypeDeclarationSymbol.<>c__DisplayClass4_0.<.ctor>b__1() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Reference\ReferenceDotNetTypeDeclarationSymbol.cs:line 37
at System.Lazy`1.ViaFactory(LazyThreadSafetyMode mode)
at System.Lazy`1.ExecutionAndPublication(LazyHelper executionAndPublication, Boolean useDefaultConstructor)
at System.Lazy`1.CreateValue()
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ModuleSymbol.GetObjectSymbolInModuleByName(ImmutableDictionary`2 objectsByName, SymbolKind kind, String name) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\ModuleSymbol.cs:line 149
at Microsoft.Dynamics.Nav.CodeAnalysis.ReferenceManager.GetDotNetObjectSymbolsByName(String name) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\SymbolReference\ReferenceManager.cs:line 259
at Microsoft.Dynamics.Nav.CodeAnalysis.ReferenceManager.GetObjectSymbolsByName(SymbolKind kind, String name) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\SymbolReference\ReferenceManager.cs:line 253
at Microsoft.Dynamics.Nav.CodeAnalysis.SymbolReference.SerializableSymbolModelConverter.ResolveApplicationObjectReference(ModuleSymbol module, SymbolKind kind, Subtype subType) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\SymbolReference\SerializableSymbolModelConverter.cs:line 905
at Microsoft.Dynamics.Nav.CodeAnalysis.SymbolReference.SerializableSymbolModelConverter.ResolveElementType(ModuleSymbol module, Symbol owner, TypeDefinition typeDefinition) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\SymbolReference\SerializableSymbolModelConverter.cs:line 1001
at Microsoft.Dynamics.Nav.CodeAnalysis.SymbolReference.SerializableSymbolModelConverter.ResolveType(ModuleSymbol module, Symbol owner, TypeDefinition typeDefinition) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\SymbolReference\SerializableSymbolModelConverter.cs:line 126
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ReferenceGlobalVariableSymbol..ctor(ContainerSymbol containingSymbol, VariableDefinition variable) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Reference\ReferenceGlobalVariableSymbol.cs:line 22
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ReferenceCodeunitTypeSymbol.<>c__DisplayClass4_0.<.ctor>b__2() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Reference\ReferenceCodeunitTypeSymbol.cs:line 59
at System.Lazy`1.ViaFactory(LazyThreadSafetyMode mode)
at System.Lazy`1.ExecutionAndPublication(LazyHelper executionAndPublication, Boolean useDefaultConstructor)
at System.Lazy`1.CreateValue()
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ReferenceCodeunitTypeSymbol.GetMembers(String name) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Reference\ReferenceCodeunitTypeSymbol.cs:line 110
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.TypeSymbol.Microsoft.Dynamics.Nav.CodeAnalysis.IContainerSymbol.GetMembers(String name) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\TypeSymbol.cs:line 36
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceAttributeSymbol.FindEvent(Compilation compilation, SymbolKind objectKind, Int32 objectId, String eventName, Location applicationIdLocation) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceAttributeSymbol.cs:line 198
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceAttributeSymbol.FindEventMethod() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceAttributeSymbol.cs:line 182
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceAttributeSymbol.LazyGetEventMethod() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceAttributeSymbol.cs:line 166
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.EventSubscriberAttributeValidator.CheckEventAttribute(AttributeSymbol attribute, SourceMethodOrTriggerSymbol methodSymbol, DiagnosticBag diagnostics) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\BuiltIn\AttributeValidators\EventSubscriberAttributeValidator.cs:line 82
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceAttributeSymbol.CheckAttribute() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceAttributeSymbol.cs:line 293
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceAttributeSymbol.ForceComplete(SourceLocation locationOpt, CancellationToken cancellationToken) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceAttributeSymbol.cs:line 258
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceMethodOrTriggerSymbol.ForceCompleteAttributes(SourceLocation locationOpt, CancellationToken cancellationToken) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceMethodOrTriggerSymbol.cs:line 391
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceMethodOrTriggerSymbol.ForceComplete(SourceLocation locationOpt, CancellationToken cancellationToken) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceMethodOrTriggerSymbol.cs:line 329
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ObjectMembers`1.ForceMembersCompleteAndCheckUniqueness(SourceLocation locationOpt, DiagnosticBag diagnostics, CancellationToken cancellationToken, Predicate`1 excludeFromNameUniqueness) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Members\ObjectMembers.cs:line 172
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ObjectMembers`1.ForceCompleteMembers(SourceLocation locationOpt, CancellationToken cancellationToken, Predicate`1 excludeFromNameUniqueness) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Members\ObjectMembers.cs:line 709
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ObjectMembers`1.ForceComplete(SourceLocation locationOpt, CancellationToken cancellationToken, Predicate`1 excludeFromNameUniqueness) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Members\ObjectMembers.cs:line 675
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceCodeunitTypeSymbol.ForceComplete(SourceLocation locationOpt, CancellationToken cancellationToken) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceCodeunitTypeSymbol.cs:line 77
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceModuleSymbol.ForceCompleteMemberByLocation(SourceLocation locationOpt, Symbol member, CancellationToken cancellationToken) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceModuleSymbol.cs:line 195
at System.Threading.Tasks.Parallel.<>c__DisplayClass19_0`1.<ForWorker>b__1(RangeWorker& currentWorker, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion)
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Threading.Tasks.Parallel.<>c__DisplayClass19_0`1.<ForWorker>b__1(RangeWorker& currentWorker, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion)
at System.Threading.Tasks.TaskReplicator.Replica`1.ExecuteAction(Boolean& yieldedBeforeCompletion)
at System.Threading.Tasks.TaskReplicator.Replica.Execute()
--- End of inner exception stack trace ---
at System.Threading.Tasks.TaskReplicator.Run[TState](ReplicatableUserAction`1 action, ParallelOptions options, Boolean stopOnFirstFailure)
at System.Threading.Tasks.Parallel.ForWorker[TLocal](Int32 fromInclusive, Int32 toExclusive, ParallelOptions parallelOptions, Action`1 body, Action`2 bodyWithState, Func`4 bodyWithLocal, Func`1 localInit, Action`1 localFinally)
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Threading.Tasks.Parallel.ThrowSingleCancellationExceptionOrOtherException(ICollection exceptions, CancellationToken cancelToken, Exception otherException)
at System.Threading.Tasks.Parallel.ForWorker[TLocal](Int32 fromInclusive, Int32 toExclusive, ParallelOptions parallelOptions, Action`1 body, Action`2 bodyWithState, Func`4 bodyWithLocal, Func`1 localInit, Action`1 localFinally)
at System.Threading.Tasks.Parallel.For(Int32 fromInclusive, Int32 toExclusive, ParallelOptions parallelOptions, Action`1 body)
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceModuleSymbol.ForceComplete(SourceLocation locationOpt, CancellationToken cancellationToken) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceModuleSymbol.cs:line 101
at Microsoft.Dynamics.Nav.CodeAnalysis.Compilation.GetSourceDeclarationDiagnostics(SyntaxTree syntaxTree, Nullable`1 filterSpanWithinTree, Func`4 locationFilterOpt, CancellationToken cancellationToken) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Compilation\Compilation.cs:line 930
at Microsoft.Dynamics.Nav.CodeAnalysis.Compilation.GetDiagnostics(CompilationStage stage, Boolean includeEarlierStages, CancellationToken cancellationToken) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Compilation\Compilation.cs:line 616
---> (Inner Exception #0) System.InvalidOperationException: Unexpected value '49184' of type 'Mono.Cecil.TargetArchitecture'
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.Cecil.CecilExtensions.GetProcessorArchitecture(ModuleDefinition module) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\Cecil\CecilExtensions.cs:line 392
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.AssemblyLocatorBase.GetAssemblyNameFromPath(String filePath) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\AssemblyLocatorBase.cs:line 390
at System.Collections.Concurrent.ConcurrentDictionary`2.GetOrAdd(TKey key, Func`2 valueFactory)
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.AssemblyLocatorBase.GetPathToCompatibleAssemblyFromCandidates(AssemblyNameAdapter searchName, IEnumerable`1 pathsToAssemblies) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\AssemblyLocatorBase.cs:line 101
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.AssemblyLocatorBase.GetPathToCompatibleAssembly(AssemblyNameAdapter searchName) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\AssemblyLocatorBase.cs:line 69
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.Cecil.CecilAssemblyResolver.Resolve(AssemblyNameReference name, ReaderParameters parameters) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\Cecil\CecilAssemblyResolver.cs:line 40
at Mono.Cecil.MetadataResolver.Resolve(TypeReference type)
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.Cecil.CecilDotNetTypeInfoProvider..ctor(ReaderParameters moduleReaderParameters) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\Cecil\CecilDotNetTypeInfoProvider.cs:line 80
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.Cecil.CecilDotNetTypeLoader.get_TypeInfoProvider() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\Cecil\CecilDotNetTypeLoader.cs:line 48
at Microsoft.Dynamics.Nav.CodeAnalysis.DotNet.Cecil.CecilDotNetTypeLoader.<LoadAssembly>b__13_0(String assemblyName) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\DotNet\Cecil\CecilDotNetTypeLoader.cs:line 66
at System.Collections.Concurrent.ConcurrentDictionary`2.GetOrAdd(TKey key, Func`2 valueFactory)
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ReferenceDotNetAssemblyDeclarationSymbol.<>c__DisplayClass4_0.<.ctor>b__2() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Reference\ReferenceDotNetAssemblyDeclarationSymbol.cs:line 62
at System.Lazy`1.ViaFactory(LazyThreadSafetyMode mode)
at System.Lazy`1.ExecutionAndPublication(LazyHelper executionAndPublication, Boolean useDefaultConstructor)
at System.Lazy`1.CreateValue()
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ReferenceDotNetTypeDeclarationSymbol.<>c__DisplayClass4_0.<.ctor>b__1() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Reference\ReferenceDotNetTypeDeclarationSymbol.cs:line 37
at System.Lazy`1.ViaFactory(LazyThreadSafetyMode mode)
at System.Lazy`1.ExecutionAndPublication(LazyHelper executionAndPublication, Boolean useDefaultConstructor)
at System.Lazy`1.CreateValue()
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ModuleSymbol.GetObjectSymbolInModuleByName(ImmutableDictionary`2 objectsByName, SymbolKind kind, String name) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\ModuleSymbol.cs:line 149
at Microsoft.Dynamics.Nav.CodeAnalysis.ReferenceManager.GetDotNetObjectSymbolsByName(String name) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\SymbolReference\ReferenceManager.cs:line 259
at Microsoft.Dynamics.Nav.CodeAnalysis.ReferenceManager.GetObjectSymbolsByName(SymbolKind kind, String name) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\SymbolReference\ReferenceManager.cs:line 253
at Microsoft.Dynamics.Nav.CodeAnalysis.SymbolReference.SerializableSymbolModelConverter.ResolveApplicationObjectReference(ModuleSymbol module, SymbolKind kind, Subtype subType) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\SymbolReference\SerializableSymbolModelConverter.cs:line 905
at Microsoft.Dynamics.Nav.CodeAnalysis.SymbolReference.SerializableSymbolModelConverter.ResolveElementType(ModuleSymbol module, Symbol owner, TypeDefinition typeDefinition) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\SymbolReference\SerializableSymbolModelConverter.cs:line 1001
at Microsoft.Dynamics.Nav.CodeAnalysis.SymbolReference.SerializableSymbolModelConverter.ResolveType(ModuleSymbol module, Symbol owner, TypeDefinition typeDefinition) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\SymbolReference\SerializableSymbolModelConverter.cs:line 126
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ReferenceGlobalVariableSymbol..ctor(ContainerSymbol containingSymbol, VariableDefinition variable) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Reference\ReferenceGlobalVariableSymbol.cs:line 22
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ReferenceCodeunitTypeSymbol.<>c__DisplayClass4_0.<.ctor>b__2() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Reference\ReferenceCodeunitTypeSymbol.cs:line 59
at System.Lazy`1.ViaFactory(LazyThreadSafetyMode mode)
at System.Lazy`1.ExecutionAndPublication(LazyHelper executionAndPublication, Boolean useDefaultConstructor)
at System.Lazy`1.CreateValue()
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ReferenceCodeunitTypeSymbol.GetMembers(String name) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Reference\ReferenceCodeunitTypeSymbol.cs:line 110
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.TypeSymbol.Microsoft.Dynamics.Nav.CodeAnalysis.IContainerSymbol.GetMembers(String name) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\TypeSymbol.cs:line 36
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceAttributeSymbol.FindEvent(Compilation compilation, SymbolKind objectKind, Int32 objectId, String eventName, Location applicationIdLocation) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceAttributeSymbol.cs:line 198
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceAttributeSymbol.FindEventMethod() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceAttributeSymbol.cs:line 182
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceAttributeSymbol.LazyGetEventMethod() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceAttributeSymbol.cs:line 166
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.EventSubscriberAttributeValidator.CheckEventAttribute(AttributeSymbol attribute, SourceMethodOrTriggerSymbol methodSymbol, DiagnosticBag diagnostics) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\BuiltIn\AttributeValidators\EventSubscriberAttributeValidator.cs:line 82
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceAttributeSymbol.CheckAttribute() in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceAttributeSymbol.cs:line 293
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceAttributeSymbol.ForceComplete(SourceLocation locationOpt, CancellationToken cancellationToken) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceAttributeSymbol.cs:line 258
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceMethodOrTriggerSymbol.ForceCompleteAttributes(SourceLocation locationOpt, CancellationToken cancellationToken) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceMethodOrTriggerSymbol.cs:line 391
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceMethodOrTriggerSymbol.ForceComplete(SourceLocation locationOpt, CancellationToken cancellationToken) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceMethodOrTriggerSymbol.cs:line 329
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ObjectMembers`1.ForceMembersCompleteAndCheckUniqueness(SourceLocation locationOpt, DiagnosticBag diagnostics, CancellationToken cancellationToken, Predicate`1 excludeFromNameUniqueness) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Members\ObjectMembers.cs:line 172
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ObjectMembers`1.ForceCompleteMembers(SourceLocation locationOpt, CancellationToken cancellationToken, Predicate`1 excludeFromNameUniqueness) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Members\ObjectMembers.cs:line 709
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.ObjectMembers`1.ForceComplete(SourceLocation locationOpt, CancellationToken cancellationToken, Predicate`1 excludeFromNameUniqueness) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Members\ObjectMembers.cs:line 675
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceCodeunitTypeSymbol.ForceComplete(SourceLocation locationOpt, CancellationToken cancellationToken) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceCodeunitTypeSymbol.cs:line 77
at Microsoft.Dynamics.Nav.CodeAnalysis.Symbols.SourceModuleSymbol.ForceCompleteMemberByLocation(SourceLocation locationOpt, Symbol member, CancellationToken cancellationToken) in C:\a\459\s\source\Prod\Microsoft.Dynamics.Nav.CodeAnalysis\Symbols\Source\SourceModuleSymbol.cs:line 195
at System.Threading.Tasks.Parallel.<>c__DisplayClass19_0`1.<ForWorker>b__1(RangeWorker& currentWorker, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion)
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Threading.Tasks.Parallel.<>c__DisplayClass19_0`1.<ForWorker>b__1(RangeWorker& currentWorker, Int32 timeout, Boolean& replicationDelegateYieldedBeforeCompletion)
at System.Threading.Tasks.TaskReplicator.Replica`1.ExecuteAction(Boolean& yieldedBeforeCompletion)
at System.Threading.Tasks.TaskReplicator.Replica.Execute()<---
@salgiza have you configured the assemblyProbingPaths for your project?
Hi @atoader, the parameter has the default value:

The only settings configured in the workplace are for enabling the codeAnalysis, but compilation fails as well if I l remove them.
The type you are referencing in the EventSubscriber contains references to .NET types. We are trying to resolve those references and we are crashing because we are trying to look into an assembly that does not match our expectations.
I will open a bug and try to get it fixed as soon as possible.
The fix for this issue has been checked in to the master branch. It will be available in the bcinsider.azurecr.io/bcsandbox-master Docker image starting from build number 25778.
If you don鈥檛 have access to these images you need to become part of the Ready2Go program: aka.ms/readytogo
For more details on code branches and docker images please read:
https://blogs.msdn.microsoft.com/nav/2018/05/03/al-developer-previews-multiple-releases-and-github/
https://blogs.msdn.microsoft.com/freddyk/2018/04/16/which-docker-image-is-the-right-for-you/
The fix for this issue has been checked in to the master branch. It will be available in the bcinsider.azurecr.io/bcsandbox-master Docker image starting from platform build number 25778.
If you don鈥檛 have access to these images you need to become part of the Ready2Go program: aka.ms/readytogo
For more details on code branches and docker images please read:
https://blogs.msdn.microsoft.com/nav/2018/05/03/al-developer-previews-multiple-releases-and-github/
https://blogs.msdn.microsoft.com/freddyk/2018/04/16/which-docker-image-is-the-right-for-you/
Most helpful comment
The type you are referencing in the EventSubscriber contains references to .NET types. We are trying to resolve those references and we are crashing because we are trying to look into an assembly that does not match our expectations.
I will open a bug and try to get it fixed as soon as possible.