NightOwl888 commented on issue #872: URL: https://github.com/apache/lucenenet/issues/872#issuecomment-1752122329
This will only affect .NET Framework/.NET Standard 2.0 users - so this is all legacy. Previously the code was under MIT and now it has either a Community or Commercial license. ConditionalWeakTable is missing the enumerator prior to .NET Standard 2.1 and newer versions cannot be back ported because it ties directly into the GC in native code. This is the reason why we went with weak events in the first place. See #613. Porting it is a dead end. There are at least 3 options: 1. Leave the current dependency. If someone wants to upgrade, let them deal with the licensing. Presumably, they won't be upgrading unless they have a license, anyway. 2. Go to a commit in Prism that had an MIT license and copy the weak event code into the Support/Util/Events folder (in the namespace Lucene.Net.Util.Events) and add the headers as specified in the [prior license](https://github.com/PrismLibrary/Prism/blob/7ca126dcddbad026d087b42f8c16914af12d7fcd/LICENSE). There are only a few types that we depend on and it is all pure C# code. 3. Adapt the weak events to use [WeakEventManager](https://learn.microsoft.com/en-us/dotnet/api/system.windows.weakeventmanager?view=windowsdesktop-7.0) in .NET Framework (See [Weak event patterns](https://learn.microsoft.com/en-us/dotnet/desktop/wpf/events/weak-event-patterns?view=netdesktop-7.0)) and remove the dependency on the Prism.Core package. This would require us to drop support for .NET Standard 2.0, but this is something we are considering doing anyway. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: dev-unsubscr...@lucenenet.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org