Unable to unload async-loaded textures in a widget

In UE4.16.3, I am async-loading textures for UI purposes, since I don’t want full-res UI textures sitting in memory all the time. This works well (I use OBJ LIST to see what textures are loaded before and after the load). The UI widget will async-load a data table (via asset ID) that references the asset IDs of various UI textures, which then get loaded as necessary.

However, I am unable to find any way (in Blueprint) to then remove these loaded textures from memory. User Widgets stay in memory when removed from the viewport, even after a garbage collect, so I tried de-referencing the async-loaded UI textures from the image widgets (when the UI is removed from the viewport), but after a garbage collect, the textures are still in memory.

As far as I can see, it seems like any async-loaded assets will just have to stay in memory? (unless you are using C++)

The only workaround I can think of is to use mip-maps on UI textures, and assume that the texture streaming system will keep only the smallest mip in memory when the UI is not in view. But requiring mip-maps for UI textures comes with other issues…

EDIT: Here is an example of what I’m doing:

Just doing some more testing to see if I’ve de-referenced the texture properly:

OBJ REFS says that the texture is still referenced by a “Cast to Texture2D” node (that is inside that “Load Image for Key” macro). Perhaps this is the real problem - references are being held by a blueprint node that has long finished executing…

Ah, ok - the texture reference is actually held due to this problem:

I hope that is on the issues radar somewhere… potentially huge assets could be held in memory just because of a blueprint node that got executed a long time ago…

I made an updated post about the blueprint object references here: