Skip to content

Commit 380faf6

Browse files
committed
0.2.1 remove subscription to assemblyLoadContext.Unloading event to prevent crash
1 parent 37e5213 commit 380faf6

File tree

2 files changed

+4
-23
lines changed

2 files changed

+4
-23
lines changed

CHANGELOG.md

+3
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ All notable changes to this project will be documented in this file.
44

55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
66

7+
## [0.2.1] 2024-02-13
8+
* Fixed a crash that could result from an attempted workaround of the 'assembly reload failed' error
9+
710
## [0.2.0] 2024-02-01
811

912
### Added

addons/YarnSpinner-Godot/YarnSpinnerPlugin.cs

+1-23
Original file line numberDiff line numberDiff line change
@@ -76,29 +76,7 @@ public override void _EnterTree()
7676
// }
7777
//
7878
};
79-
80-
var assemblyLoadContext =
81-
AssemblyLoadContext.GetLoadContext(Assembly.GetExecutingAssembly());
82-
if (assemblyLoadContext != null)
83-
{
84-
assemblyLoadContext.Unloading += _ =>
85-
{
86-
// trigger unload for what we can
87-
AssemblyLoadContext
88-
.GetLoadContext(typeof(Compiler).Assembly)
89-
?.Unload();
90-
AssemblyLoadContext
91-
.GetLoadContext(typeof(Antlr4.Runtime.Parser).Assembly)
92-
?.Unload();
93-
AssemblyLoadContext
94-
.GetLoadContext(typeof(CsvHelper.CsvParser).Assembly)
95-
?.Unload();
96-
AssemblyLoadContext
97-
.GetLoadContext(typeof(Google.Protobuf.MessageParser).Assembly)
98-
?.Unload();
99-
};
100-
}
101-
79+
10280
#if !GODOT4_2_OR_GREATER
10381
editorInterface = GetEditorInterface();
10482
#endif

0 commit comments

Comments
 (0)