Open Dieder opened 5 years ago
yes, i agree this change will be better than loading all types..
I have same issue, but i think project is dead. Last visit of author is more than year ago.
Yes, its a pity. This code is very effective for filtering data with dynamic needs.
Op do 14 mei 2020 om 01:11 schreef InsonusK notifications@github.com:
I have same issue, but i think project is dead. Last visit of author is more than year ago.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/dbelmont/ExpressionBuilder/issues/60#issuecomment-628292587, or unsubscribe https://github.com/notifications/unsubscribe-auth/AA6FTVERPP4OAX63Q5AIL2DRRMSJ5ANCNFSM4JGIWYRQ .
there is a fork here, working well on dotnet core
https://github.com/yurisouza/expressionbuildernetcore
Ive asked the author to change this dynamic conditions load, to avoid scanning all the assemblies, this is creating too much problem for little benefit.. one can use the dedicated method to add new custom conditions.
John
I have installed the latest NuGet package of your library with version 2.1.0-rc. Unfortunately it doesn't work at runtime. After execution, I get the following error: System.AggregateException : One or more errors occurred. (The type initializer for 'ExpressionBuilder.Helpers.OperationHelper' threw an exception.) ---- System.TypeInitializationException : The type initializer for 'ExpressionBuilder.Helpers.OperationHelper' threw an exception. -------- System.Reflection.ReflectionTypeLoadException : Unable to load one or more of the requested types.
The cause of the problem is found in the file ' OperationHelper.cs' operation 'LoadDefaultOperations' . I don't know why all assemblies have to be loaded with all types, but this implementation causes the error. I made a fix in the implementation of the method as follows: var @interface = typeof(IOperation); var operationsFound = typeof(IOperation).Assembly .GetTypes() .Where(p => @interface.IsAssignableFrom(p) && p.IsClass && !p.IsAbstract) .Select(t => (IOperation)Activator.CreateInstance(t));
This will fix the issue. Furthermore the compile conditions are missing the new core 3.0 and 3.1 compiler variables.
Please, will you update the code, so it works with .Net Core 3.0? Thanks in advance.