I'm having a difficult time understanding what this DIS Validation error means, it shows up as "Critical" and when trying to publish the DIS Output shows a stack trace (below).
I've gone trough all my QAction files and neither them or protocol.xml shows any errors.
Restarting VS2022 does not help.
DIS Output:
2023/11/16 04:40:06.854|Could not compile protocol:
System.MissingMethodException: Method not found: 'Void NuGet.Packaging.Core.PackageIdentity..ctor(System.String, NuGet.Versioning.NuGetVersion)'.
at SLDisCompiler.Protocol.ProtocolBuilder.<BuildQActionDllImports>d__21.MoveNext()
at System.Runtime.CompilerServices.AsyncTaskMethodBuilder`1.Start[TStateMachine](TStateMachine& stateMachine)
at SLDisCompiler.Protocol.ProtocolBuilder.BuildQActionDllImports(QActionsQAction qa, Project project, IQActions allQActions, PackageReferenceProcessor packageReferenceProcessor, BuildResultItems buildResultItems, ICompliancies compliancies)
at SLDisCompiler.Protocol.ProtocolBuilder.<BuildQAction>d__19.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at SLDisCompiler.Protocol.ProtocolBuilder.<BuildQActions>d__18.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at SLDisCompiler.Protocol.ProtocolBuilder.<BuildResultsAsync>d__16.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at SLDisCompiler.Protocol.ProtocolBuilder.<BuildAsync>d__15.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Skyline.VSX.ProtocolEditor.Documents.ProtocolDocument.<CompileProtocolAsync>d__27.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.VisualStudio.Threading.JoinableTask.CompleteOnCurrentThread()
at Microsoft.VisualStudio.Threading.JoinableTask`1.CompleteOnCurrentThread()
at Skyline.VSX.ProtocolEditor.Margin.PublishDropDownButton.<>c__DisplayClass19_0.<PublishProtocol>b__0(DoWorkEventArgs a)
2023/11/16 04:40:06.872|Protocol published!
Critical DIS Validation error:
Critical: Unexpected exception in Test 'CSharpSLProtocolCheckTrigger': System.ArgumentException: Syntax node is not within syntax tree
at Microsoft.CodeAnalysis.CSharp.CSharpSemanticModel.CheckSyntaxNode(CSharpSyntaxNode syntax)
at Microsoft.CodeAnalysis.CSharp.CSharpSemanticModel.GetTypeInfo(ExpressionSyntax expression, CancellationToken cancellationToken)
at Microsoft.CodeAnalysis.CSharp.CSharpExtensions.GetTypeInfo(SemanticModel semanticModel, ExpressionSyntax expression, CancellationToken cancellationToken)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynHelper.GetFullyQualifiedName(SemanticModel semanticModel, ExpressionSyntax expression)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynHelper.TryParseValue(ExpressionSyntax expression, SemanticModel semanticModel, Solution solution, Value& value)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynHelper.TryGetVariableValue(ExpressionSyntax expression, SemanticModel semanticModel, Solution solution, Value& value)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynHelper.TryParseValue(ExpressionSyntax expression, SemanticModel semanticModel, Solution solution, Value& value)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynHelper.TryParseValue(ExpressionSyntax expression, SemanticModel semanticModel, Solution solution, Value& value)
at SLDisCSharpAnalysis.CSharpAnalyzer.Classes.Argument.TryParseToValue(SemanticModel semanticModel, Solution solution, Value& value)
at SLDisValidator2.Tests.Protocol.QActions.QAction.CSharpSLProtocolCheckTrigger.QActionAnalyzer.CheckCallingMethod(CallingMethodClass callingMethod)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynVisitor.VisitInvocationExpression(InvocationExpressionSyntax node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.Visit(SyntaxNode node)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynVisitor.Visit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.DefaultVisit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.Visit(SyntaxNode node)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynVisitor.Visit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.DefaultVisit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.Visit(SyntaxNode node)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynVisitor.Visit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.DefaultVisit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.Visit(SyntaxNode node)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynVisitor.Visit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.DefaultVisit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.Visit(SyntaxNode node)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynVisitor.Visit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.DefaultVisit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.Visit(SyntaxNode node)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynVisitor.Visit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.DefaultVisit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.Visit(SyntaxNode node)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynVisitor.Visit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.DefaultVisit(SyntaxNode node)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynVisitor.VisitMethodDeclaration(MethodDeclarationSyntax node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.Visit(SyntaxNode node)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynVisitor.Visit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.DefaultVisit(SyntaxNode node)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynVisitor.VisitClassDeclaration(ClassDeclarationSyntax node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.Visit(SyntaxNode node)
at SLDisCSharpAnalysis.CSharpAnalyzer.RoslynVisitor.Visit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.DefaultVisit(SyntaxNode node)
at Microsoft.CodeAnalysis.CSharp.CSharpSyntaxWalker.Visit(SyntaxNode node)
at SLDisValidator2.Tests.Protocol.QActions.QAction.CSharpSLProtocolCheckTrigger.CSharpSLProtocolCheckTrigger.Validate(ValidatorContext context)
at SLDisValidator2.Validator.RunValidateTest(IValidate test, ValidatorContext context, List`1 results) (line 0 col 0) [0.0.0]
With the latest Visual Studio 2022 update (17.8.0), DIS 2.44 has become incompatible. Our current advice is to update to the latest insider release (2.45) for now: DataMiner Integration Studio - Downloads - DataMiner Dojo
We're in the process of releasing 2.46, so 2.45 will become the main release as well.