From ed48b5e04c3f1a7c0c12a790be75ca8f0245cc32 Mon Sep 17 00:00:00 2001 From: Kaz Wolfe Date: Sat, 29 Jun 2024 13:40:29 -0700 Subject: [PATCH] comments for lumina pinning --- Dalamud/Plugin/Internal/Types/LocalPlugin.cs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Dalamud/Plugin/Internal/Types/LocalPlugin.cs b/Dalamud/Plugin/Internal/Types/LocalPlugin.cs index 40a512ea2..4bc2add70 100644 --- a/Dalamud/Plugin/Internal/Types/LocalPlugin.cs +++ b/Dalamud/Plugin/Internal/Types/LocalPlugin.cs @@ -634,15 +634,18 @@ internal class LocalPlugin : IDisposable config.IsUnloadable = true; config.LoadInMemory = true; config.PreferSharedTypes = false; - - config.SharedAssemblies.Add((typeof(Lumina.GameData).Assembly.GetName(), true)); - config.SharedAssemblies.Add((typeof(Lumina.Excel.ExcelSheetImpl).Assembly.GetName(), true)); // Make sure that plugins do not load their own Dalamud assembly. // We do not pin this recursively; if a plugin loads its own assembly of Dalamud, it is always wrong, // but plugins may load other versions of assemblies that Dalamud depends on. config.SharedAssemblies.Add((typeof(EntryPoint).Assembly.GetName(), false)); config.SharedAssemblies.Add((typeof(Common.DalamudStartInfo).Assembly.GetName(), false)); + + // Pin Lumina since we expose it as an API surface. Before anyone removes this again, please see #1598. + // Changes to Lumina should be upstreamed if feasible, and if there is a desire to re-add unpinned Lumina we + // will need to put this behind some kind of feature flag somewhere. + config.SharedAssemblies.Add((typeof(Lumina.GameData).Assembly.GetName(), true)); + config.SharedAssemblies.Add((typeof(Lumina.Excel.ExcelSheetImpl).Assembly.GetName(), true)); } private void EnsureLoader()