AdService:GetAdAvailabilityNowAsync() permanently bricks invoking thread if called in non-whitelisted place

Currently, as of 5/14/25, if AdService:GetAdAvailabilityNowAsync() is called, it will permanently brick / suspend the luau thread it was called on if the place it was called in is not whitelisted for access to that API. If it is called in a place that is whitelisted, the API works fine.

To reproduce, run the following code in a whitelisted and non-whitelisted place. Observe that when ran in a whitelisted place, the API works fine. Also observe that when in a non-whitelisted place, the thread silently halts and never resumes.

local AdService = game:GetService("AdService")

local function WaitForAdAvailable()
	local Retries = 0

	while true do
		local AdAvailabilitySuccess, AdAvailabilityResult = pcall(function()
			warn("Invoking AdService API")
			return AdService:GetAdAvailabilityNowAsync(Enum.AdFormat.RewardedVideo)
		end)

		warn(Retries, AdAvailabilitySuccess, AdAvailabilityResult.AdAvailabilityResult)

		if AdAvailabilitySuccess and AdAvailabilityResult.AdAvailabilityResult == Enum.AdAvailabilityResult.IsAvailable then
			return true
		elseif Retries == 3 then
			warn("FAILED TO GET AD!")

			return false
		else
			Retries = Retries + 1
			task.wait(1)
		end
	end
end

WaitForAdAvailable()

Expected behavior

It is expected that the GetAdAvailabilityNowAsync() API would return an error or relevant enum if the place is not whitelisted. It should not silently brick the actual thread the API was called on.

5 Likes