Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

igx-grid memory leak - a data object bound to an igx-grid is never released when that igx-grid has a paginator #15302

Open
jsakamotoIGJP opened this issue Jan 27, 2025 · 0 comments · May be fixed by #15307
Assignees
Labels
🐛 bug Any issue that describes a bug ✅ status: resolved Applies to issues that have pending PRs resolving them, or PRs that have already merged.

Comments

@jsakamotoIGJP
Copy link

Description

The igx-grid has a memory leaking problem. It happens when users move columns.

  • igniteui-angular version: 19.0.6
  • browser: Microsoft Edge Version 132.0.2957.115 (Official build) (64-bit)
  • OS: Windows 11 Pro 24H2 x64
  • Node.js version: 22.13.0

Steps to reproduce

  1. Download the sample program, 📦c-00235192-ng-app4-grid-mem-leak.zip, and extract it into a working directory.
  2. Open a terminal on the working directory.
  3. Execute the npm ci, npm run build, and npx serve .\dist\c-00235192-ng-app4-grid-mem-leak\browser\ commands.
  4. Open http://localhost:30000 in a web browser.
  5. Open the browser's Dev Tools / Memory tab.
  6. Take the 1st memory snapshot (don't forget to click the "Collect garbage" button before taking.)
  7. Click the "Go to the Grid with Paginator page" button. You will see a grid with a paginator on the page.
  8. Take the 2nd memory snapshot (don't forget to click the "Collect garbage" button before taking.)
  9. Click the "Home" button to return to the home page.
  10. Take the 3rd memory snapshot (don't forget to click the "Collect garbage" button before taking.)
  11. In the Dev Tools Memory tab, select the 3rd snapshot, select "Comparison" in the "Perspective" dropdown, input "Sample" into the "Class filter" text field, and select the 1st snapshot in the "Base snapshot".

Result

You will see that "SampleDataType" objects bound to the igx-grid component remain in comparison between the first snapshot and the third one. (Please see also the video I attached below.)

2025-01-27_16h38_31.mp4

Expected result

No "SampleDataType" objects should exist in that "Comparison" view because the garbage collector should have cleaned up those objects.

Note

If the grid didn't even have a paginator, the 'SampleDataType' objects would be garbage collected as expected, so I consider the behavior reported above to be a problem and a kind of memory leak. (Please see also the video I attached below.)

2025-01-27_16h35_58.mp4

Attachments

@jsakamotoIGJP jsakamotoIGJP added 🐛 bug Any issue that describes a bug 🆕 status: new labels Jan 27, 2025
@MayaKirova MayaKirova self-assigned this Jan 28, 2025
@MayaKirova MayaKirova added ✅ status: resolved Applies to issues that have pending PRs resolving them, or PRs that have already merged. and removed 🆕 status: new labels Jan 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug Any issue that describes a bug ✅ status: resolved Applies to issues that have pending PRs resolving them, or PRs that have already merged.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants