Entire contents showing less elements than I need it to show...?

Hey all, Im running this code to view all the ui elements of the app Slack

tell application “Slack” to activate

tell application “System Events”

tell front window of (first application process whose frontmost is true)

set uiElems to entire contents

end tell

end tell

The output I’m seeing is:
Result:
{group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", button 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", button 2 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", button 3 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events"}

BUT, If I launch the app “UI Browser” and explore Slack


Then, when I run the exact same code, this is what I see (Even if I close UI Browser right after)
Result:
{group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 2 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 2 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 2 of group 2 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 3 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 4 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", UI element "Request a submission" of group 1 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of UI element "Request a submission" of group 1 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", static text "Request a submission" of group 1 of UI element "Request a submission" of group 1 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", button 1 of group 1 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", button 2 of group 1 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 2 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 2 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", static text "So, you want to make a submission? Riddle me this..." of group 1 of group 2 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 2 of group 2 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 2 of group 2 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", static text "What to submit to?" of group 1 of group 2 of group 2 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 2 of group 2 of group 2 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", text field "What to submit to?" of group 2 of group 2 of group 2 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 3 of group 2 of group 2 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 4 of group 2 of group 2 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 3 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of group 3 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", button "Close" of group 1 of group 3 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of button "Close" of group 1 of group 3 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", static text "Close" of group 1 of button "Close" of group 1 of group 3 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", button "Next" of group 1 of group 3 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", group 1 of button "Next" of group 1 of group 3 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", static text "Next" of group 1 of button "Next" of group 1 of group 3 of group 1 of group 1 of group 5 of group 1 of UI element "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of group 1 of group 1 of group 1 of group 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", button 1 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", button 2 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events", button 3 of window "something-something-something-bringup-submissions - GDE - 12 new items - Slack" of application process "Slack" of application "System Events"}

If I close this session of Slack and open it back up, Im back to the first output.

I need to be able to see the second result without opening UI Browser at all. What am I missing? What does UI Browser do exactly to force Slack or the MacOS to explore all these extra groups and UI elements that Im not seeing on a fresh opened Slack?