WindowsCommunityToolkit icon indicating copy to clipboard operation
WindowsCommunityToolkit copied to clipboard

Sample App has a memory leak issue

Open nmetulev opened this issue 5 years ago • 3 comments

I'm submitting a...

  • Bug report (I searched for similar issues and did not find one)

Current behavior

The sample app keeps references to sample objects after they are no longer used.

Expected behavior

The sample app should clean up all references to sample objects once the sample is closed

Minimal reproduction of the problem with instructions

  • Run the sample app through Visual Studio
  • Take a memory snapshot
  • Navigate through different samples and navigate back to the initial page
  • Take another memory snapshot and compare

Environment

Windows 10 Build Number:
- [ ] Fall Creators Update (16299)
- [ ] April 2018 Update (17134)
- [x] October 2018 Update (17763)
- [ ] Insider Build (build number: )

App min and target version:
- [x] Fall Creators Update (16299)
- [ ] April 2018 Update (17134)
- [x] October 2018 Update (17763)
- [ ] Insider Build (xxxxx)

Device form factor:
- [x] Desktop
- [ ] Mobile
- [ ] Xbox
- [ ] Surface Hub
- [ ] IoT

Visual Studio 
- [ ] 2017 (version: )
- [x] 2017 Preview (version: 15.9.0 Preview 4)

nmetulev avatar Oct 26 '18 00:10 nmetulev

Have you tried setting the NavigationCacheMode?

skendrot avatar Oct 26 '18 14:10 skendrot

I haven't. The issue seems to be related in part to the Monaco editor, but haven't had time to debug more

nmetulev avatar Oct 26 '18 15:10 nmetulev

I know in my Monaco TestApp I test removing it and adding it to the Visual Tree, and that's usually pretty clean. I wonder if we're not doing something in the wrapper we have around it in the SampleApp. I can take a look more in November/December.

michael-hawker avatar Oct 26 '18 17:10 michael-hawker