Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

There are no default labels for Russian. You must provide your own labels for this language. #6068

Closed
k0xxx opened this issue Jul 18, 2021 · 10 comments

Comments

@k0xxx
Copy link

k0xxx commented Jul 18, 2021

  • Electron-Builder Version: 22.11.7
  • Node Version: 14
  • Electron Version: 13.1.7
  • Electron Type (current, beta, nightly): current

"@imjs/electron-differential-updater": "^5.1.6" based on electron-updater

  • Target: mac and windows

• found existing path=/Users/k0xxx/Library/Caches/electron-builder/nsis/nsis-3.0.4.1
⨯ No known languages found for specification Russian. failedTask=build stackTrace=NoSuchLanguageError: No known languages found for specification Russian.
at Function.bySpec (/Users/k0xxx/Documents/work/colleagial/dentalbot_desktop/node_modules/dmg-license/lib/Language.js:35:19)
at Object.indexByLanguage (/Users/k0xxx/Documents/work/colleagial/dentalbot_desktop/node_modules/dmg-license/lib/Language.js:81:41)
at labelCache (/Users/k0xxx/Documents/work/colleagial/dentalbot_desktop/node_modules/dmg-license/lib/assembleLicenses.js:92:35)
at Object.assembleLicenses [as default] (/Users/k0xxx/Documents/work/colleagial/dentalbot_desktop/node_modules/dmg-license/lib/assembleLicenses.js:117:23)
at dmgLicensePlist (/Users/k0xxx/Documents/work/colleagial/dentalbot_desktop/node_modules/dmg-license/lib/index.js:27:78)
at dmgLicense (/Users/k0xxx/Documents/work/colleagial/dentalbot_desktop/node_modules/dmg-license/lib/index.js:21:62)
at Object.dmgLicenseFromJSON (/Users/k0xxx/Documents/work/colleagial/dentalbot_desktop/node_modules/dmg-license/lib/index.js:37:18)
at Object.addLicenseToDmg (/Users/k0xxx/Documents/work/colleagial/dentalbot_desktop/node_modules/dmg-builder/src/dmgLicense.ts:59:9)
at DmgTarget.build (/Users/k0xxx/Documents/work/colleagial/dentalbot_desktop/node_modules/dmg-builder/src/dmg.ts:73:25)
• found existing path=/Users/k0xxx/Library/Caches/electron-builder/nsis/nsis-resources-3.4.1
• building embedded block map file=dist/Dentalbot by Colleagial-1.0.5-mac.zip
• building block map blockMapFile=dist/Dentalbot by Colleagial Setup 1.0.5.exe.blockmap
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

If we are building without licenseButtons_ru.json, we are getting error with no available languages for current language

@mmaietta
Copy link
Collaborator

Is there a question or request or issue here?

@k0xxx
Copy link
Author

k0xxx commented Jul 18, 2021

It’s issue, sorry my bad. When I build application with ru license I’ve getting error with ‘no available labels for this language’

@mmaietta
Copy link
Collaborator

Descriptions and details help a lot.
Please post your config and the electron-builder output with env var DEBUG=electron-builder set

@k0xxx
Copy link
Author

k0xxx commented Jul 18, 2021

I think here is related issue #5887

@k0xxx
Copy link
Author

k0xxx commented Jul 18, 2021

As i understood from the related post, there is some inaccuracy in the documentation
For correct inserting licenses on different languages in the updated version of electron-builder need to add own licenseButtons for target languages, so RU and UK languages do not present in the default configuration of lables.
So regarding this the correct template of lableButton is "licenseButtons_ru.json"
{
"languageName": "Russian",
"lang": "ru-RU",
"agree": "Согласен",
"disagree": "Не согласен",
"print": "Распечатать",
"save": "Сохранить...",
"message": "Если вы согласны с условиями этой лицензии, нажмите "Согласен", чтобы установить программное обеспечение. Если не согласен, нажмите "Не согласен"."
}
lang must be a language code with region and also we need to provide languageName as reqired field
PS please update basic documentation for this issue

@mmaietta mmaietta self-assigned this Jul 19, 2021
@stale
Copy link

stale bot commented Sep 19, 2021

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@stale stale bot added the backlog label Sep 19, 2021
@itsPG
Copy link

itsPG commented Oct 19, 2021

I got the same issue.

It was worked on v22.9.1 and it's broken on v22.13.1, which is the latest version on 2021/10/19.

After some bisection search, I found v22.9.1 is the last one worked version for me.

@stale stale bot removed the backlog label Oct 19, 2021
@stale
Copy link

stale bot commented Apr 17, 2022

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@stale stale bot added the backlog label Apr 17, 2022
@stale stale bot closed this as completed Apr 29, 2022
@itsPG
Copy link

itsPG commented Sep 29, 2022

This issue still exists on v23.0.2.

According to #6726

To build on macOS >= 12.3 We must upgrade to this version.

I'll try to see if there's any available workaround.

@itsPG
Copy link

itsPG commented Sep 29, 2022

After struggling with it for a while

I found a workaround:

  • create 4 files named licenseButtons_cs.json, licenseButtons_hu.json, licenseButtons_pl.json, licenseButtons_ru.json, and put them under the build folder
  • the *.json should be like this: (be aware that the field name should be langName & message, the one written in the document is incorrect)
{
    "langName": "Russian",
    "agree": "Agree",
    "disagree": "Disagree",
    "print": "Print",
    "save": "Save",
    "message": "Russian"
  }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants