Translation error

New home Forums Pro Add-on Troubleshooting Translation error

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #57261
    boatsRus
    Member

    I copied the latest default PO file from 8.0.14 to generate a new translation file. However, Poedit (V2.2.4) indicates that there is an error with one of the strings, it apparently does not like a % sign in the source text.

    See attached screenshots for details. Could you in the next release change the ailing string to now have a % sign in it and generate a new default po file?

    Attachments:
    You must be logged in to view attached files.
    #57276
    Perry
    Moderator

    Hi Hakan

    Happy new year, I hope you’re well!

    A lot of our translation strings use %, this is the standard mechanism for translating a certain type of dynamic string, for instance, strings with a link in.

    The “set your map to 100%” string you’ve shown in your screenshot has been there for many years now, so if that’s only just started coming up in your PO software then this must be a new warning.

    “Format specification missing” sounds like it’s expecting a character after the percent sign, either we need to escape that percent, or this is a false positive.

    According to this article https://stackoverflow.com/questions/38435081/poedit-show-error-a-format-specification-for-argument-1-doesnt-exist-in-msgs the solution is to add a comment,

    Please could we ask you to open /wp-google-maps-pro/legacy-core.php and add a new line above line 1349 (which has that string on), please add

    Does that help at all?

    Kind regards
    – Perry

    #57298
    boatsRus
    Member

    Does not have any effect. POEedit refers also to some totally other lines of code so seems the PO/POT files are old. Perhaps the suggest fix actually is needed when you generate the PO/POT file?

    I did a brute for fix by just editing the ailing string (meaning it cannot now be translated), please try to generate a PO/POT file that works with the latest version of POedit.

    Attachments:
    You must be logged in to view attached files.
    #57314
    Perry
    Moderator

    Hi Hakan

    I ran a scan using the latest version of POEdit, I’m not seeing any issues at my end.

    Our translations are user contributed, if you think the translation files need updating then we would welcome any contributions in terms of translation.

    Which string exactly are you having issues with?

    Kind regards
    – Perry

    #57320
    boatsRus
    Member

    It’s the “set your map to 100%” string shown in the screenshot in the first post. It seems something now causes POedit the think that the precentage sign is the php replacement function. The problem is NOT the translations but the “source string” picked up from your code (which ofcourse is basically not editable in POedit but I did some violence on the .po file to remove that one string.

    The to duplicate the problem you need to generate the .po(t) file and then try to generate a new translation for some language with the newest version of POedit.

    #57327
    Perry
    Moderator

    Hi Hakan

    I thought that might be the case, I’m not seeing the same thing at my end at all unfortunately.

    Please see the attached screenshot, POEdit has no problem with this string at my end. I’m running Windows 10, if that helps.

    Is it POEdit itself that reports this error?

    Kind regards
    – Perry

    #57345
    boatsRus
    Member

    You forgot the screenshot it seems? Yes, POedit complains (see screen capture of error, it is a POedit error).

    #57357
    Perry
    Moderator

    Hi Hakan

    My apologies, it looks like we’re having issues with attachments between our support desk and the forum.

    Please see the attached – I’m not seeing any errors at all using POEdit 2.2.4 (build 5785)

    Kind regards
    – Perry

    Attachments:
    You must be logged in to view attached files.
Viewing 8 posts - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.