Rhino geometry disappearing from window after using content cache

I’m using Grasshopper to content cache geometry and user text into new Rhino layers that replicate the original source layer structure.

The script appears to execute successfully. The new layers are created, and after saving, closing, and reopening the Rhino file, both the original geometry and the newly cached geometry are visible and correctly assigned to their respective layers. But, when I ran the Grasshopper script, both the original geometry and the cached geometry disappear from the Rhino viewport, even though the layers are still present. The geometry only becomes visible again after saving the file and reopening Rhino.

Has anyone encountered this behavior before, or is there a known viewport refresh or display issue related to content caching geometry from Grasshopper?

Below is the script that I’m using to replicate the original source layers and geometry’s user text.

it would help if you could share your files.