A Native Collection has not been disposed, Enable Full Stack?

I have case where :

A Native Collection has not been disposed, resulting in a memory leak. Enable Full StackTraces to get more details.

error spawns. The error suggests that I shoud enable full stack trace. Which I have done, but it does not help to identify or find more information about the related error.

No matter the stack trace level for debug console, the message stays the same and there are no more info, detail about the error. This is not very helpful, so what else can we do?

You need to install the com.unity.jobs package in the package manager and then enable through the Jobs menu installed with the package. I was not able to find this package in the package manager registry but was able to locate it by searching fir the full name com.unity.jobs.

@castor76 the menu you need to enable full stack traces in in this one:
7083142--842893--upload_2021-4-27_18-56-49.png
If you don’t have the ‘Jobs’ menu you’ll need to do as @Yumby said.

I can’t remember, but it may require you to to enable preview packages:

2 Likes

I see!, Got it and much thanks!

I got this problem in “Unity 2020 version”
when i use WWW requests

WWW www = new(url, request.BytesData, request.headers);

i just added Using and it fixed thiss issue

using (WWW www = new(url, request.BytesData, request.headers)){}
4 Likes

Has anyone found a way to Enable Full Stack Traces for jobs in Unity 2021.3? This used to be included in the com.unity.jobs package as described in this thread. But Unity gutted that package, even going so far as to nuke the previously-valid version number, leaving just a note saying “Please use the Collections Package”. But I have collections installed and it doesn’t let me enable Full Stack Traces for Jobs.