cross
New Foswiki release 2.1.6 is available with important security fixes.
Sourceforge foswiki email lists being discontinued. Subscribe to the new Foswiki announce and discuss lists at MailingLists
This question about Configuration: Answered

Configure > Internationalisation > Languages tab

Whatever language I try to enable, I always get the following error:

Internal error: xx is missing the '_language_name' from it's translation. Language will not be usable.

where xx is the language code (nl, fr, ...)

Any ideas?


This can be caused if the maketext() call fails for any reason. We are just assuming that no results is a missing _language_name field. Check your System.PerlDependencyReport results to see if any of the language dependencies are missing. In particular: CPAN:Locale::Language, CPAN:Locale::Maketext::Lexicon and CPAN:Locale::Msgfmt.

-- Main.GeorgeClark - 10 Aug 2017 - 02:02

The following patch might reveal more about what's failing:

diff --git a/core/lib/Foswiki/Configure/Checkers/LANGUAGE.pm b/core/lib/Foswiki/Configure/Checkers/LANGUAGE.pm
index 5b285e2..ae35983 100644
--- a/core/lib/Foswiki/Configure/Checkers/LANGUAGE.pm
+++ b/core/lib/Foswiki/Configure/Checkers/LANGUAGE.pm
@@ -48,6 +48,9 @@ sub check_current_value {
 "Internal error: $lang is missing the '_language_name' from it's translation.  Language will not be usable."
             );
         }
+        if ($@) {
+           print STDERR "Language lookup failed\n" . $@;
+        }
     }
 }
 

-- GeorgeClark - 10 Aug 2017

Strange. This is what I checked:

PERL DEPENDENCY REPORT The only missing one I "suspected", was MultiLingualPlugin, but this one didn't solve the problem, so I uninstalled it again. Apparently, it is meant for multilingual content, not for a translated interface.

The other missing/obsolete modules are: - CPAN:IO::Socket::SSL, CPAN:DBD::SQLite, CPAN:DBI, XSendFileContrib, DBCachePlugin, SolrPlugin, CPAN:Spreadsheet::ParseExcel, CPAN:Spreadsheet::XLSX, CPAN:mod_perl2 But I don't suspect these ones, or am I wrong?

PARTICULAR PERL MODULES When I enable Interface Internationalisation, it tells me the mentioned modules are installed: - Locale::Maketext 1.28 installed for I18N translations - Locale::Maketext::Lexicon 1.00 installed for I18N translations - Locale::Msgfmt 0.15 installed for I18N Language file compression

PATCH If I'm using the patched LANGUAGE.PM checker file, I still get the same result, no more extra error output, although I was definitely using the patched file.

Any further ideas?

-- StijnBousard - 10 Aug 2017

If you save the config with the languages enabled, do they show up in the language selector? (ie, is this a problem with the checker, rather than an actual problem with the language files.) The errors reported by the checkers won't actually stop configure from saving the configuration.

Right, MultiLingualPlugin has nothing to the base languages support. Nothing jumps out in the list of missing modules.

-- GeorgeClark - 10 Aug 2017

SOLVED

Apparently, there must have been something wrong with the CPAN modules I installed in the local CPAN library of my Foswiki installation.

After I asked the hosting company to activate CPAN:Locale::Language, CPAN:Locale::Maketext::Lexicon, CPAN:Locale::Msgfmt in the base path, I was able to enable Interface Internationalisation and choose languages without errors. Immediately after saving the changes, the language selector appeared (which was not the case when I saved the config when the errors were mentioned).

-- StijnBousard - 12 Aug 2017
 

QuestionForm edit

Subject Configuration
Extension
Version Foswiki 2.1.3
Status Answered
Related Topics
Topic revision: r7 - 14 Aug 2017, StijnBousard - This page was cached on 18 Sep 2018 - 00:53.

The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy