Description

There was an issue in 4.16 (fixed in CL# 3437205) in which blueprint output pins would hold on to object references until the blueprint was destroyed. It appears that an additional fix may need to be applied to widget blueprints, as they're still holding on to a reference to the last widget created.

The reference will only be dropped when the blueprint containing the node is destroyed, or when it falls out of scope. Because of this, wrapping the create widget node in a function is a valid workaround.

Steps to Reproduce
  1. Download attached project
  2. Activate the "Add UMG label trigger n times
  3. Type 'obj list class=redlabel_c' in the console to see that there are n ubojects created
  4. Activate the Remove UMG label trigger
  5. Type 'obj gc' in the console to trigger garbage collection on the now unreferenced widgets
  6. Type 'obj list class=redlabel_c' again, and observe that there is still 1 widget that hasn't been collected

Have Comments or More Details?

There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-51408 in the post.

2
Login to Vote

Fixed
ComponentUE - Gameplay - Blueprint
Affects Versions4.174.184.19
Target Fix4.19
Fix Commit3783922
Main Commit3804136
Release Commit3813083
CreatedOct 17, 2017
ResolvedDec 1, 2017
UpdatedApr 27, 2018
View Jira Issue