Wrong information shown into "About" dialog after install russian language pack #718

Closed
opened 2025-09-10 23:47:01 -05:00 by giteasync · 14 comments
Owner

Originally created by @sergey-dryabzhinsky on GitHub.

Describe the bug
After VSC moved to release+commit verioning lines in About dialog shifted and now shown wrong information.

Please confirm that this problem is VSCodium-specific

  • This bug doesn't happen if I use Microsoft's Visual Studio Code. It only happens in VSCodium.

Please confirm that the issue/resolution isn't already documented

To Reproduce
Steps to reproduce the behavior:
0. Setup language pack. In my case - russian.

  1. Go to main menu 'Help/Помощь'
  2. Click on 'About/О программе'
  3. See wrong info in dialog

Expected behavior
Build date in Date info, etc.
Seems like russian lang pack does not have "Release:" line. And all other lines shifted.

Screenshots
Снимок экрана_2022-10-07_20-52-11

Desktop (please complete the following information):

  • OS: Ubuntu Linux 18.04
  • Architecture: amd64
  • Version: since 1.70.1+
  • App Manager: tar.gz

Additional context
If I remove language pack - all info got in right lines.
Снимок экрана_2022-10-07_21-06-32

Originally created by @sergey-dryabzhinsky on GitHub. **Describe the bug** After VSC moved to release+commit verioning lines in About dialog shifted and now shown wrong information. **Please confirm that this problem is VSCodium-specific** - [x] This bug doesn't happen if I use Microsoft's Visual Studio Code. It only happens in VSCodium. **Please confirm that the issue/resolution isn't already documented** - [x] I checked [the Docs page](https://github.com/VSCodium/vscodium/blob/master/DOCS.md) and my issue is not mentioned there. **To Reproduce** Steps to reproduce the behavior: 0. Setup language pack. In my case - russian. 1. Go to main menu 'Help/Помощь' 2. Click on 'About/О программе' 3. See wrong info in dialog **Expected behavior** Build date in Date info, etc. Seems like russian lang pack does not have "Release:" line. And all other lines shifted. **Screenshots** ![Снимок экрана_2022-10-07_20-52-11](https://user-images.githubusercontent.com/717597/194621873-1dc11dc8-5f2f-43bf-aacf-9a30ed6462aa.png) **Desktop (please complete the following information):** - OS: Ubuntu Linux 18.04 - Architecture: amd64 - Version: since 1.70.1+ - App Manager: tar.gz **Additional context** If I remove language pack - all info got in right lines. ![Снимок экрана_2022-10-07_21-06-32](https://user-images.githubusercontent.com/717597/194621848-83c3f486-54ab-4c3d-83cd-5609b6260c5d.png)
giteasync added the
bug
label 2025-09-10 23:47:01 -05:00
Author
Owner
@Crystal-RainSlide commented on GitHub: Also see: https://github.com/VSCodium/vscodium/issues/1301 https://github.com/VSCodium/vscodium/blob/10582b3c86c800f43dbe7836203420dde9862c60/patches/build-version.patch#L145-L151 https://github.com/microsoft/vscode/blob/c07b428d7db4662a1f45e8e57e41d44167f2e11a/src/vs/workbench/electron-sandbox/parts/dialogs/dialogHandler.ts#L169
Author
Owner

@daiyam commented on GitHub:

@Crystal-RainSlide Feel free to make a PR to fix the issue 😉

@daiyam commented on GitHub: @Crystal-RainSlide Feel free to make a PR to fix the issue 😉
Author
Owner

@daiyam commented on GitHub:

@sergey-dryabzhinsky This issue is specific to VSCodium since the release number isn't available on VSCode.

@daiyam commented on GitHub: @sergey-dryabzhinsky This issue is specific to VSCodium since the release number isn't available on VSCode.
Author
Owner

@daiyam commented on GitHub:

  • Should we hide the Release version? No
  • Should we merge the Release version into the "Version:"? No
  • Should we patch the language packs instead? No

Oh! I see the issue... The text needs to be patched after it has been localized. Insert the new line (Release: {1}) after the line 1.
What about the text Release? Should we keep it in english or have the translations for all the languages?

@daiyam commented on GitHub: - Should we hide the Release version? **No** - Should we merge the Release version into the "Version:"? **No** - Should we patch the language packs instead? **No** Oh! I see the issue... The text needs to be patched after it has been localized. Insert the new line (`Release: {1}`) after the line 1. What about the text `Release`? Should we keep it in english or have the translations for all the languages?
Author
Owner

@Crystal-RainSlide commented on GitHub:

Honestly, I don't know...

  • Should we hide the Release version?
  • Should we merge the Release version into the "Version:"?
  • Should we patch the language packs instead?

@daiyam You have to choose one first! 😆

@Crystal-RainSlide commented on GitHub: > Honestly, I don't know... > - Should we hide the Release version? > - Should we merge the Release version into the "Version:"? > - Should we patch the language packs instead? @daiyam You have to choose one first! 😆
Author
Owner

@Crystal-RainSlide commented on GitHub:

English + every language we can have for now? or Machine translate?

Machine translate is actually OK if we use Release version as input instead of just Release. Release itself would easily be translated to verb, or something equal to version by machine. But Release version is surely a noun, and we are not likely to get a Version version.


Update

Update: No good. I can't find any sure way to get current language. Best bet is import { getConfiguredDefaultLocale } from 'vs/nls'; (instead of try to locate the right constant to import from vs/base/common/platform) but this requires some testing. It also seems that VSCode is playing code generation on this.


Update again: Good, we just need import { language } from 'vs/base/common/platform';


Non-English Lanauges according to https://github.com/microsoft/vscode-loc , excluding Pseudo Language (qps-ploc):

["cs", "de", "es", "fr", "it", "ja", "ko", "pl", "pt-BR", "ru", "tr", "zh-hans", "zh-hant"]
@Crystal-RainSlide commented on GitHub: English + every language we can have for now? or Machine translate? Machine translate is actually OK if we use `Release version` as input instead of just `Release`. `Release` itself would easily be translated to verb, or something equal to `version` by machine. But `Release version` is surely a noun, and we are not likely to get a `Version version`. --- <details> <summary>Update</summary> Update: No good. I can't find any sure way to get current language. Best bet is `import { getConfiguredDefaultLocale } from 'vs/nls';` (instead of try to locate the right constant to import from [vs/base/common/platform](https://github.com/microsoft/vscode/blob/41bdf03368d2c03360c04ac596b9d3413bcc0886/src/vs/base/common/platform.ts)) but this requires some testing. It also seems that VSCode is playing code generation on this. - https://github.com/microsoft/vscode/blob/7bd27b4287b49e61a1cb49e18f370260144c8685/src/vs/nls.ts - https://github.com/microsoft/vscode/blob/c07b428d7db4662a1f45e8e57e41d44167f2e11a/src/vs/nls.build.ts - https://github.com/microsoft/vscode/blob/c07b428d7db4662a1f45e8e57e41d44167f2e11a/src/vs/nls.mock.ts </details> --- Update again: Good, we just need `import { language } from 'vs/base/common/platform';` --- Non-English Lanauges according to https://github.com/microsoft/vscode-loc , excluding Pseudo Language (qps-ploc): ``` JSON ["cs", "de", "es", "fr", "it", "ja", "ko", "pl", "pt-BR", "ru", "tr", "zh-hans", "zh-hant"] ```
Author
Owner

@Crystal-RainSlide commented on GitHub:

@sergey-dryabzhinsky Can you provide Russian translation of Release (as a noun) or Release version for us, to add it together?

@Crystal-RainSlide commented on GitHub: @sergey-dryabzhinsky Can you provide Russian translation of `Release` (as a noun) or `Release version` for us, to add it together?
Author
Owner

@sergey-dryabzhinsky commented on GitHub:

it's Релиз and Версия релиза

@sergey-dryabzhinsky commented on GitHub: it's `Релиз` and `Версия релиза`
Author
Owner

@Crystal-RainSlide commented on GitHub:

That's what I can offer for now:

Expand / collapse
diff --git a/src/vs/workbench/electron-sandbox/parts/dialogs/dialogHandler.ts b/src/vs/workbench/electron-sandbox/parts/dialogs/dialogHandler.ts
index f63b75f..218373f 100644
--- a/src/vs/workbench/electron-sandbox/parts/dialogs/dialogHandler.ts
+++ b/src/vs/workbench/electron-sandbox/parts/dialogs/dialogHandler.ts
@@ -8,3 +8,3 @@ import { fromNow } from 'vs/base/common/date';
 import { mnemonicButtonLabel } from 'vs/base/common/labels';
-import { isLinux, isLinuxSnap, isWindows } from 'vs/base/common/platform';
+import { isLinux, isLinuxSnap, isWindows, language } from 'vs/base/common/platform';
 import Severity from 'vs/base/common/severity';
@@ -167,2 +167,10 @@ export class NativeDialogHandler implements IDialogHandler {
 
+		const RELEASE_DEFAULT = 'Release';
+		const releaseString = ({
+			'en': RELEASE_DEFAULT,
+			'ru': 'Релиз',
+			'zh-hans': '发布版本',
+			'zh-hant': '發布版本',
+		})(language) || RELEASE_DEFAULT;
+
 		const detailString = (useAgo: boolean): string => {
@@ -179,3 +187,3 @@ export class NativeDialogHandler implements IDialogHandler {
 				process.sandboxed ? 'Yes' : 'No' // TODO@bpasero remove me once sandbox is final
-			);
+			).replace('\n', `\n${releaseString}: ${this.productService.release || 'Unknown'}`);
 		};
@Crystal-RainSlide commented on GitHub: That's what I can offer for now: <details open> <summary>Expand / collapse</summary> ``` diff diff --git a/src/vs/workbench/electron-sandbox/parts/dialogs/dialogHandler.ts b/src/vs/workbench/electron-sandbox/parts/dialogs/dialogHandler.ts index f63b75f..218373f 100644 --- a/src/vs/workbench/electron-sandbox/parts/dialogs/dialogHandler.ts +++ b/src/vs/workbench/electron-sandbox/parts/dialogs/dialogHandler.ts @@ -8,3 +8,3 @@ import { fromNow } from 'vs/base/common/date'; import { mnemonicButtonLabel } from 'vs/base/common/labels'; -import { isLinux, isLinuxSnap, isWindows } from 'vs/base/common/platform'; +import { isLinux, isLinuxSnap, isWindows, language } from 'vs/base/common/platform'; import Severity from 'vs/base/common/severity'; @@ -167,2 +167,10 @@ export class NativeDialogHandler implements IDialogHandler { + const RELEASE_DEFAULT = 'Release'; + const releaseString = ({ + 'en': RELEASE_DEFAULT, + 'ru': 'Релиз', + 'zh-hans': '发布版本', + 'zh-hant': '發布版本', + })(language) || RELEASE_DEFAULT; + const detailString = (useAgo: boolean): string => { @@ -179,3 +187,3 @@ export class NativeDialogHandler implements IDialogHandler { process.sandboxed ? 'Yes' : 'No' // TODO@bpasero remove me once sandbox is final - ); + ).replace('\n', `\n${releaseString}: ${this.productService.release || 'Unknown'}`); }; ``` </details>
Author
Owner

@daiyam commented on GitHub:

Could you make a PR? Thx

@daiyam commented on GitHub: Could you make a PR? Thx
Author
Owner

@Crystal-RainSlide commented on GitHub:

OH NO NOT AGAIN

Got fooled by GitHub's commit to a new branch and start a PR, again.

@Crystal-RainSlide commented on GitHub: OH NO NOT AGAIN Got fooled by GitHub's commit to a new branch and start a PR, again.
Author
Owner

@sergey-dryabzhinsky commented on GitHub:

@sergey-dryabzhinsky Sorry for not ask them at once, but: Is the word Релиз good for represent Release version, which means a version number?

Yes

@sergey-dryabzhinsky commented on GitHub: > @sergey-dryabzhinsky Sorry for not ask them at once, but: Is the word `Релиз` good for represent `Release version`, which means a version number? Yes
Author
Owner

@daiyam commented on GitHub:

@Crystal-RainSlide You have to make the PR on VSCodium/vscodium so we can merge it 😉

@daiyam commented on GitHub: @Crystal-RainSlide You have to make the PR on VSCodium/vscodium so we can merge it :wink:
Author
Owner

@Crystal-RainSlide commented on GitHub:

@sergey-dryabzhinsky Sorry for not ask them at once, but: Is the word Релиз good for represent Release version, which means a version number?

@Crystal-RainSlide commented on GitHub: @sergey-dryabzhinsky Sorry for not ask them at once, but: Is the word `Релиз` good for represent `Release version`, which means a version number?
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: VSCodium/vscodium#718
No description provided.