LocaleIdRefactor2 causes GetTranslatorForPlayerAsync to yield indefinitely

Reproduction Steps
When testing my game this afternoon, I noticed that some parts of it didn’t load in studio, but worked fine in in-game. After tracking down the cause of the problem, it turns out the LocaleIdRefactor2 flag that was turned on today causes GetTranslatorForPlayerAsync to yield indefinitely in studio when wrapped in a pcall.

How to reproduce this:

  1. Open up a game that has been published to Roblox
  2. Run the following piece of code in the command bar:
local LocalizationService = game:GetService("LocalizationService")
local success, playerTranslator = pcall(LocalizationService.GetTranslatorForPlayerAsync, LocalizationService, game.Players.LocalPlayer)
print(success, playerTranslator)
  1. Observe how nothing is printed in the output because it yields indefinitely

Expected Behavior
I expect GetTranslatorForPlayerAsync to not yield indefinitely in studio when wrapped in a pcall.

Actual Behavior
GetTranslatorForPlayerAsync yields indefinitely in studio when wrapped in a pcall and when the flag LocaleIdRefactor2 is turned on.

Workaround
The best workaround is to manually turn off LocaleIdRefactor2, but that’s something that most developers aren’t familiar with. The worst workaround would be to not wrap GetTranslatorForPlayerAsync in a pcall because it has the potential to error, as mentioned in the docs.

Issue Area: Studio
Issue Type: Other
Impact: Moderate
Frequency: Constantly
Date First Experienced: 2022-10-13 13:00:00 (-07:00)
Date Last Experienced: 2022-10-13 14:00:00 (-07:00)

3 Likes

Can confirm, I’m experiencing this issue in Studio as well.

Yep! Can confirm it’s happening. Just spent an hour trying to figure out why my modules weren’t loading only to discover that this was the cause.

1 Like

Hi, thanks for the report! We have been able to identify the root cause and will be putting up a fix. In the meantime, we have disabled this feature on studio (you may have to restart if you haven’t recently).

Please let us know if you still run into any issues.

2 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.