How to reproduce:
1. Open the attached “IN-141168” project
2. Enter Play Mode
3. Exit Play Mode
4. Observe the Console window
Actual result: Error “Release of invalid GC handle. The handle is from a previous domain. The release operation is skipped.” is thrown
Expected result: No errors are thrown
Reproducible with: 2.1.0 (6000.0.1f1), 2.11.1 (6000.5.0b6, 6000.6.0a4)
Not reproducible with: 2.0.8 (6000.0.1f1)
Reproducible on: Windows 11
Not reproducible on: No other environments tested
Note: This is a timing issue during domain reload where ScriptingGCHandle::Release() attempts to resolve a handle, but the corresponding object has already been collected, returning null during the restore phase..