geolexica / isotc211.geolexica.org

ISO/TC 211 online version of the Multi-Lingual Glossary of Terms
https://isotc211.geolexica.org
4 stars 2 forks source link

Language codes are not consistent with ISO 639-2 #85

Closed strogonoff closed 4 years ago

strogonoff commented 5 years ago

For example, Malaysian is specified as may (e.g., the link https://www.geolexica.org/registers/#language-may), while the code appears to be msa.

ronaldtse commented 5 years ago

@strogonoff this problem is in the tc211-termbase gem:

Need to fix this:

  # TODO: read language_code from sheet
  def language_code
    # Hack to make ISO_639 gem work...
    lang = case language
    when "Dutch"
      "Dutch; Flemish"
    when "Spanish"
      "Spanish; Castilian"
    else
      language
    end
    ISO_639.find_by_english_name(lang).alpha3
  rescue
    raise StandardError.new("Failed to find alpha3 code for language: #{lang}")
  end
ronaldtse commented 5 years ago

We can fix this once these issues are fixed:

skalee commented 4 years ago

We should use the correct ISO 639-2 codes for terminology. Code for Malaysian was corrected quite some time ago. Ones pointed by @ronaldtse in above comment are also fixed. The last ones are being fixed in #137.