Search Issue Tracker
Won't Fix
Won't Fix in 2023.1.X
Votes
0
Found in
2020.3.43f1
2021.3.16f1
2022.2.1f1
2023.1.0a24
Issue ID
UUM-22822
Regression
No
Memory leak when uninstalling or installing packages
Steps to reproduce:
1. Open the "PackagesMemoryIssues" project
2. Open Package Manager
3. Observe the Activity Monitor or Task Manager or Profiler
4. Install any package (e.g. 2D PSD Importer)
5. Observe the Activity Monitor or Task Manager or Profiler
Expected result: The memory usage is the same as before the installation
Actual result: Memory usage climbs higher every time the package is installed or uninstalled
Reproducible with: 2020.3.43f1, 2021.3.16f1, 2022.2.1f1, 2023.1.0a24
Reproduced on: macOS Monterey 12.2 (Intel), Windows 10
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Crash on UndoManager::RegisterUndoInternal when applying added GameObjects to a Prefab
- [Asset Bundles] A new bundle hash is not generated when the name of a serialized field is changed
- Icon section shows incomplete message and unusable check box in Build Profiles and Player Settings window instead of “Not applicable for this platform” for Dedicated Server Platform
- Assets are created in the Package folders when creating assets via custom buttons in the Inspector window or other windows
- “Select” windows are named differently on Windows and macOS
Resolution Note:
From looking at the video, the problem is that the user doesn't see the package dependencies that are installed at the same time. The packages that are the problems in the video have a dependency on Burst. Burst is a big package to optimize code and take a lot of memory. (In the project settings there is an option to see dependencies, it helps to understand any problems. Also the dependencies are now always visible in Unity 22LTS+ in a Dependencies tab for each packages.)
Also on the end of the video we see a project with a simple scene that takes 3.5G of memory. Unfortunately the Packages folder in the project browser is collapsed and we can't see all the packages installed. My guess is (because I can see URP is used) that there are a lot of packages installed in that project. To fix that issue, the user should uninstall unnecessary packages in the package manager in the 'In project' view. Unity can't load only packages affecting the current scene as it's not possible to evaluate what to load from packages, so we need to load all packages while the project is opened.
Resolution Note (2023.1.X):
From looking at the video, the problem is that the user doesn't see the package dependencies that are installed at the same time. The packages that are the problems in the video have a dependency on Burst. Burst is a big package to optimize code and take a lot of memory. (In the project settings there is an option to see dependencies, it helps to understand any problems. Also the dependencies are now always visible in Unity 22LTS+ in a Dependencies tab for each packages.)
Also on the end of the video we see a project with a simple scene that takes 3.5G of memory. Unfortunately the Packages folder in the project browser is collapsed and we can't see all the packages installed. My guess is (because I can see URP is used) that there are a lot of packages installed in that project. To fix that issue, the user should uninstall unnecessary packages in the package manager in the 'In project' view. Unity can't load only packages affecting the current scene as it's not possible to evaluate what to load from packages, so we need to load all packages while the project is opened.