ContentProvider not loading assets

Hi!

With an admin system I’m making I tried to make it load some stuff once the admin panel is cloned.

I made this yesterday and never found the issue, here’s the code:

		local NewPanel = script.Panel:Clone()
		NewPanel.Parent = plr.PlayerGui
		for i, asset in pairs(NewPanel:GetDescendants()) do
			print("pls work")
			local succ, err = pcall(function()
				game:GetService("ContentProvider"):PreloadAsync({asset})
			end)
			if succ then
				print("finished loading "..asset.Name.." for the admin panel")
			else
				warn(asset.Name.." could not load due to "..error)
			end
		end
		print("done")

All I see it print is “pls work”, followed by nothing else.

Thanks for any help!

Then ContentProvider is stalling/taking too long. Have you tried checking the asset on the website? If there’s really nothing else that’s printed in the output after a few seconds, then maybe it’s your internet? Maybe the website got blocked? Have you tried restarting Studio or your router?

Try putting a breakpoint here and wait for a while just to make sure.

I see a sound error,but I don’t have anything in the panel that could be causing it to stall. I will delete all months sounds and try again

Just fixed all of the sounds, now that isn’t a possible issue.
I now still only see “please work” followed by nothing else. It’s not my wifi, I get the same result on both my laptop and PC

Is the script ever deleted? Try clicking “Network” in the View tab and see after “pls work” is printed if “Request Queue Size” under “HTTP” is one or more (have a wait at the top of the script to make sure only the asset is being loaded after the print, and everything else in your game has finished loading).

idk what happened, but it’s working fine in game on my PC