In my case I’ve isolated this code snippet which I use for my front end to get text bounds and it now yields indefinitely for some reason:
local getTextBoundsParams = Instance.new("GetTextBoundsParams")
-- ... setting params
-- PRELOAD FONT OR :GetTextBoundsAsync MIGHT YIELD INDEFINITELY
local family = fontFace.Family
family = string.gsub(family, " ", "")
local fontURL = ("rbxasset://fonts/families/%s.json"):format(family)
services.ContentProvider:PreloadAsync({fontURL}) -- now yields indefinitely
local textBounds = services.TextService:GetTextBoundsAsync(getTextBoundsParams)
I currently fixed this by just shoving the preload to the bottom and making a skip button. However the fact that the preload function is broken is a huge concern obviously.
This has also occurred to me, which is interesting.
Ignore this horrible code, I wrote it like 3 years ago probably in the middle of the night and never looked back bc it worked
local preload = require(game:GetService("ReplicatedStorage"):WaitForChild("preload"));
local later = {};
local loadLst = {};
for key,tex in pairs(preload) do
loadLst[tex] = false;
end
for i = 1,#preload do
later[i] = preload[i];
end
for key,tex in pairs(preload) do
table.remove(later,table.find(later,tex));
loadLst[tex] = true;
contentProvider:PreloadAsync({tex});
handle((key/#preload));
if(doSkip) then
break;
end
end
Can also vouch for this happening to me too, even in studio.
function LoadSounds()
local AllSounds = {}
local SoundNames = {};
local function RecurseGet(CurrentTable: {any}, SubsetName: string)
for Index, Val in CurrentTable do
if typeof(Val) == 'table' then
RecurseGet(Val, `{SubsetName or "MAIN://"}/{Index}`)
elseif type(Val) == 'number' then
table.insert(AllSounds, `rbxassetid://{Val}`)
table.insert(SoundNames, `{SubsetName or "?"}<br></br> '{Index}'`)
end
end
end
RecurseGet(SoundStorage)
local AssetNumber = 1
local function PreloadLabelUpdate(AssetId: number, AssetFetchStatus: Enum.AssetFetchStatus)
LoadingLabel.Text = "{<br></br>"..` Loading...<br></br> {SoundNames[AssetNumber]}<br></br> ({AllSounds[AssetNumber]})`.."<br></br>}"
AssetNumber += 1
end
local PlayingSound = nil
for _, Sound in AllSounds do
if LoadingSkipped then
break
end
ContentProviderService:PreloadAsync({Sound}, PreloadLabelUpdate) --inf yield?
if PlayingSound then
PlayingSound:Destroy()
end
PlayingSound = SoundControl.new(string.gsub(Sound, "rbxassetid://", ""), SoundControl.newSoundParams())
PlayingSound:LocalPlay()
end
if PlayingSound then
PlayingSound:Destroy()
end
end
You should edit the title of this post to be more descriptive of the issue and additionally, remove “[CRITICAL]” from the title as this tag is no longer in use. Doing so should result in a faster response from engineers.
Something like “PreloadAsync infinitely yielding with fonts” would do.
I’m also having issues with odd client-to-server bugs at the same time, including frozen intro menus and player outfits being duplicated to other players.
Was there any information regarding any recent updates that could’ve impacted or caused this?
This issue is critical and needs to be resolved ASAP. Popular games are affected and unplayable. Any experience that uses ContentProvider:PreloadAsync() without a skip button appears to be unplayable. This is particularly impacting one of my favorite games, rendering it unplayable. The problem seems to have arisen after the latest Roblox client update.
Update for this issue, engineers have identified a potential cause and a mitigation has been made. Please let us know if you or your player base is still encountering the issue
My own, Guts & Blackpowder. The loading will occasionally still get stuck on loading animations, or meshes, or sounds, and the user will be forced to click skip loading to avoid being stuck on the loading screen forever.