FontFace.Weight is "empty" (not nil) and when referenced in Luau causes Roblox to crash

When setting the FontFace’s Weight property into something else than “Regular” and the font doesn’t support it, the property becomes “empty” and referencing it in Luau causes Studio to crash

image

Reproduction steps

  1. Create a TextLabel
  2. Set FontFace font to “Ubuntu”
  3. Set FontFace weight to “Light”
  4. Run the following in the console: print(path.to.textlabel.FontFace.Weight)
  5. It crashes

You can alternatively use this file and import it into Studio, then skip to step 4:
crash cause.rbxm (2.4 KB)

Expected behavior

Either it does a runtime error or it just prints nil

Actual behavior

Crashes Studio, not tested in the client but it probably crashes there aswell

Device and Studio version


image

1 Like

We’ve filed a ticket to our internal database for this issue, and will update this thread as soon as we have further information!

Thanks for the report!

1 Like

There was a bug with the Studio font picker that caused it to not work correctly, I think this is a side effect of that.

Can you try updating to the latest version of Studio (572, released this morning) and try again? I am unable to reproduce the blank behavior or the crash now that the font picker issue has been fixed.

Note that place files that were edited prior to the fix may still have broken weight values, but should fix themselves if you try to select the weight again from in Studio.

2 Likes

I can confirm the issue has been resolved:
image
image

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