Closed kant2002 closed 1 week ago
Here the stack trace
System.InvalidOperationException : Sequence contains more than one element
at System.Linq.Enumerable.Single[TSource](IEnumerable`1 source)
at System.Linq.ImmutableArrayExtensions.Single[T](ImmutableArray`1 immutableArray,Func`2 predicate)
at Csla.Analyzers.CheckConstructorsAnalyzerPublicConstructorCodeFix.AddCodeFixWithUpdatingNonPublicConstructor(CodeFixContext context,SyntaxNode root,Diagnostic diagnostic,ClassDeclarationSyntax classNode,SemanticModel model)
at async Csla.Analyzers.CheckConstructorsAnalyzerPublicConstructorCodeFix.RegisterCodeFixesAsync(<Unknown Parameters>)
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at async Microsoft.CodeAnalysis.CodeFixes.CodeFixService.GetCodeFixesAsync(<Unknown Parameters>)
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at async Microsoft.CodeAnalysis.Extensions.IExtensionManagerExtensions.PerformFunctionAsync[T](<Unknown Parameters>)
Describe the bug Open the BlazorExample and add private parameterless constructor to the![image](https://github.com/MarimerLLC/csla/assets/4257079/7149c37c-f61a-407e-91f8-b21e29a7dc91)
BusinessLibrary.PersonEdit
. I assume that this rule should trigger https://github.com/MarimerLLC/csla/blob/main/docs/analyzers/CSLA0003-CheckConstructorsAnalyzer.md But it is not, only Analyzer error displayed,but no code fix.![image](https://github.com/MarimerLLC/csla/assets/4257079/965a7242-2932-4b5a-a7d3-f20e7ee13114)
Version and Platform CSLA version: main OS: Windows, Linux, iOS, Android, etc. Platform: WinForms, WPF, ASP.NET Core, MVC, Xamarin, etc.
Code that Fails