Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice
  4. Dismiss Notice

OperationException : SelectedLocale is null on Nintendo Switch

Discussion in 'Localization Tools' started by tknippenberg, Aug 15, 2021.

  1. tknippenberg

    tknippenberg

    Joined:
    Feb 15, 2017
    Posts:
    12
    When trying to run a development build on the Nintendo Switch my log gets spammed by
    OperationException : SelectedLocale is null for all the TextMeshPro labels in my scene that have a translation defined. On PC I'm no longer having this issue after setting an active locale (Window -> Asset Management -> Localization Scene Controls).

    My setup:
    • Active locale (Window -> Asset Management -> Localization Scene Controls) set to English
    • Localization Settings file has one Specific Locale Selector, which is English
    • Localization Settings is set to Initialize Synchronously
    • All localization calls from my scripts are done through the synchronous method (from 1.0.0-pre9)
    What should I do to get rid of this error?
     
  2. karl_jones

    karl_jones

    Unity Technologies

    Joined:
    May 5, 2015
    Posts:
    7,846
    Hi,
    We have some bugs with the synchronous methods so it could be this.
    Try disabling the Wait for completion flags on the LocalizedStrings and the Initialize Synchronously option. If this doesn't work then please file a bug report so we can look into it.we have lots of fixes in this area in the next release which should hopefully be by the end of the Month, we are just waiting on some stuff to land.
     
    Mauri likes this.
  3. tknippenberg

    tknippenberg

    Joined:
    Feb 15, 2017
    Posts:
    12
    Thanks for the reply Karl. I tried disabling the Wait for completion flags on 200 objects - which was rather painful without multi-edit for this field - but it didn't have the desired effect.

    I'll wait for the release later this month to see if it solves the issue.
     
  4. karl_jones

    karl_jones

    Unity Technologies

    Joined:
    May 5, 2015
    Posts:
    7,846
    Ah sorry to hear that. We do also have multi edit support in the next release!
    Feel free to file a bug report so we can make sure it's actually fixed in the next release for you.