roborourke / wp-l10n-gen

Modern translation file generation for WP
8 stars 3 forks source link

Does not seem to work with gettext/gettext v4.8.6 #5

Open zimdin12 opened 3 years ago

zimdin12 commented 3 years ago

Fatal error: Uncaught Error: Object of class Gettext\Utils\ParsedComment could not be converted to string in C:\laragon\www[THEME-DIR]\vendor\gettext\gettext\src\Generators\Po.php:40

Stack trace:

0 C:\laragon\www[THEME-DIR]\vendor\gettext\gettext\src\Generators\Generator.php(14): Gettext\Generators\Po::toString(Object(Gettext\Translations), Array)

1 [internal function]: Gettext\Generators\Generator::toFile(Object(Gettext\Translations), 'languages\balti...', Array)

2 C:\laragon\www[THEME-DIR]\vendor\gettext\gettext\src\Translations.php(191): call_user_func_array('Gettext\Generat...', Array)

3 C:\laragon\www[THEME-DIR]\vendor\roborourke\wp-l10n-gen\inc\class-command.php(351): Gettext\Translations->__call('toPoFile', Array)

4 C:\laragon\www[THEME-DIR]\vendor\roborourke\wp-l10n-gen\inc\class-command.php(135): WP_L10N_Gen\Command->to(Object(Gettext\Translations), 'pot', 'l in C:\laragon\www[THEME-DIR]\vendor\gettext\gettext\src\Generators\Po.php on line 40

zimdin12 commented 3 years ago

Since it works with gettext 4.8.2 then this command would get it to work: composer require gettext/gettext:4.8.2

zimdin12 commented 2 years ago

Hello. Should I look for another solution ?