What's the best way to force garbage collection?

Thanks, I also tried to track down where the object is being rooted, but didn’t find the answer.

I know that in the startupmodule, the datasource is not rooted, you can check with this funtion “isrooted”,

but in the shutdownmodule, the datasource is rooted, but where?

Here is what I have tried:

  1. Add a data breakpoint for objectflag in visual studio 2022, but the breakpoint not hit.
  2. LOG the objectflag, It really changes, breakpoint should hit, but it didn’t.

Really confused. Any other method to track down the object rooted?

Maybe it’a a very low-level bug😀