Closed picks44 closed 4 years ago
solved already in https://github.com/schmittjoh/JMSTranslationBundle/pull/533
Cool @goetas thanks, is it already available in a release or shall I wait to upgrade the package?
Already released as 1.5.1
On Thu, 19 Mar 2020, 08:43 VinZ, notifications@github.com wrote:
Cool @goetas https://github.com/goetas thanks, is it already available in a release or shall I wait to upgrade the package?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/schmittjoh/JMSTranslationBundle/issues/535#issuecomment-601033510, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAF5UJ5AK77W5CH7WBNS3M3RIHEKLANCNFSM4LOUE4KA .
OK, now I have this error on the same command (with package updated to 1.5.1). Any clue @goetas ?
08:19:49 ERROR [console] Error thrown while running command "translation:ext
ract en --config=iwid --output-format=xliff". Message: "hash() expects parameter
2 to be string, integer given" ["exception" => TypeError { …},"command" => "tra
nslation:extract en --config=iwid --output-format=xliff","message" => "hash() ex
pects parameter 2 to be string, integer given"]
Seems that some of your translation keys are just numbers, is it?
On Thu, 19 Mar 2020, 09:21 VinZ, notifications@github.com wrote:
OK, now I have this error on the same command (with package updated to 1.5.1). Any clue @goetas https://github.com/goetas ?
08:19:49 ERROR [console] Error thrown while running command "translation:ext
ract en --config=iwid --output-format=xliff". Message: "hash() expects parameter
2 to be string, integer given" ["exception" => TypeError { …},"command" => "tra
nslation:extract en --config=iwid --output-format=xliff","message" => "hash() ex
pects parameter 2 to be string, integer given"]
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/schmittjoh/JMSTranslationBundle/issues/535#issuecomment-601047855, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAF5UJZWTICO7U4V3GG2LUTRIHIZ3ANCNFSM4LOUE4KA .
@goetas The closest TK that I have that looks like an integer is "615 xxx xxx x"... it is a placeholder in a form.
can you please try to add a string casting in the second parameter of the hash
function? in https://github.com/schmittjoh/JMSTranslationBundle/blob/master/Translation/Dumper/XliffDumper.php#L121, like this:
$unit->setAttribute('id', hash('sha1', (string) $id));
And see if there are more errors please?
Tested and validated, thanks guys!
Here is the output I get when using the command
It was working file with 1.4.4, please support.