vscode-cmake-tools icon indicating copy to clipboard operation
vscode-cmake-tools copied to clipboard

Couldn't find message for key cmake-tools.configuration.cmake.options.advanced.statusBarLength.description

Open mihailim opened this issue 1 year ago • 7 comments

Brief Issue Summary

For a while now (at least 3 months), the cmake-tools extension has been spamming the shared log with the warning message reproduced below. This happens on startup, and then periodically throughout the session, regardless of whether or not anything cmake-related is open or running; the presence of the installed extension is sufficient to reproduce. Changing the logging level to debug doesn't affect anything in any direction.

This is with vscode-cmake-tools v1.17.16 running on the latest MS-published vscode build (1.86.2) on Linux (repros on Ubuntu noble daily, Ubuntu jammy, Ubuntu bionic with the older still-compatible vscode 1.85.whatnot). No idea about other OS-es, sorry.

The locale environment is LANGUAGE=en_US and LANG=en_US.UTF-8 and it also reproduces with LANG=C .

2024-02-27 13:42:56.606 [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.options.advanced.statusBarLength.description.
2024-02-27 13:42:56.606 [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.options.advanced.statusBarLength.description.
2024-02-27 13:42:56.606 [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.options.advanced.statusBarLength.description.
2024-02-27 13:42:56.606 [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.options.advanced.statusBarLength.description.
2024-02-27 13:42:56.606 [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.options.advanced.statusBarLength.description.
2024-02-27 13:42:56.606 [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.options.advanced.statusBarLength.description.
2024-02-27 13:42:56.606 [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.options.advanced.statusBarLength.description.
2024-02-27 13:42:56.606 [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.options.advanced.statusBarLength.description.
2024-02-27 13:42:56.607 [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.options.advanced.statusBarLength.description.
2024-02-27 13:42:56.607 [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.options.advanced.statusBarLength.description.
2024-02-27 13:42:56.607 [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.options.advanced.statusBarLength.description.
2024-02-27 13:42:56.607 [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.options.advanced.statusBarLength.description.

CMake Tools Diagnostics

I'd love to be able to provide this, but I can't seem to find this command at all.

Debug Log

No response

Additional Information

No response

mihailim avatar Feb 27 '24 11:02 mihailim

It looks like the correct key is cmake-tools.configuration.cmake.options.advanced.statusBarLength.markdownDescription. Needs to be updated in package.json.

bobbrow avatar Feb 27 '24 19:02 bobbrow

@mihailim @bobbrow Thanks for pointing this out, I have a PR open here: #3618

gcampbell-msft avatar Feb 28 '24 15:02 gcampbell-msft

How do I resolve the issue if I don't have a package.json file?

IkeCuizhihui avatar Mar 28 '24 03:03 IkeCuizhihui

@IkeCuizhihui If you don't want to wait for the next extension release and it bothers you that much, you can switch to the prerelease version of the extension -- open the extension's page (go to Extensions and click on CMake Tools) then click the "Switch to Pre-Release Version" button under the extension description, next to the "Disable" and "Uninstall" buttons. Then after it switches, click Reload, and then you may need to close and reopen vscode once to fully get rid of the warning spam.

But, to be honest, I wouldn't risk it if it's a prod environment you need to be sure the extension is stable and working. After all, it's not that big of a deal, more or less an aesthetic annoyance.

mihailim avatar Mar 28 '24 13:03 mihailim

It's been two months since this was merged.

Any chance someone can cut a release that includes this?

notpeter avatar May 02 '24 05:05 notpeter

I'm seeing this as well - can we have a new release, please? :)

georglauterbach avatar May 03 '24 13:05 georglauterbach

@notpeter @georglauterbach, thanks for your reply. About this issue, it is fixed on CMakeTools extension release version 1.18 but this version has not been released yet. If you are in a hurry to use it, you could switch to the prerelease version of the extension -- open the extension's page (go to Extensions and click on CMake Tools) then click the "Switch to Pre-Release Version" button. Please refer to the mihailim's above comment. Thanks for your support. image

Evelyn-001 avatar May 08 '24 08:05 Evelyn-001

This went out with v1.18.41. Pre-release is not longer required anymore. Thanks all.

notpeter avatar Jun 04 '24 05:06 notpeter

Any updates on it? Release version v1.18.44 and pre-release v1.19.40 both have this problem too.

zhongxiang117 avatar Aug 15 '24 15:08 zhongxiang117

@zhongxiang117 This has been fixed for a while. You may be referring to the similar but different issue with [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.deleteBuildDirOnCleanCconfigure.description which is issue #3865 . That one isn't released yet, annoyingly.

mihailim avatar Aug 15 '24 15:08 mihailim

@mihailim thanks for your reply, it is the same issue.

image

zhongxiang117 avatar Aug 15 '24 15:08 zhongxiang117

Also, another version:

image

zhongxiang117 avatar Aug 15 '24 15:08 zhongxiang117

You're right, my apologies. I can confirm it's happening with the pre-release version v1.19.40, but not with the release version v1.18.44. On the other hand, the release version suffers from the #3865 issue, but not from this issue. So the fix for this issue was probably lost for the pre-release version, and currently both of them are annoying for different reasons :)

mihailim avatar Aug 15 '24 15:08 mihailim

@mihailim , OK, I will switch back to v1.18.44. Also, my apologies for the wrong screenshot, I was using the same picture for twice (as you will see the time stamp are the same).

zhongxiang117 avatar Aug 15 '24 15:08 zhongxiang117

For version v1.18.44, this issue is gone, thanks for that!

zhongxiang117 avatar Aug 15 '24 15:08 zhongxiang117

@mihailim @zhongxiang117 I'm not sure I fully understand from your comments, which error is happening where?

gcampbell-msft avatar Aug 15 '24 15:08 gcampbell-msft

With a quick test and viewing the source code, these issues are fixed in the most recent code. If you could tell me any steps you take to see this output, it'd be great so that I can test and see for myself. Thanks!

gcampbell-msft avatar Aug 15 '24 15:08 gcampbell-msft

@gcampbell-msft , as a brief conclusion, for my system, pre-version v1.19.40 has this opened issue, but v1.18.44 doesn't have.

zhongxiang117 avatar Aug 15 '24 15:08 zhongxiang117

@zhongxiang117 Are you doing anything specific to get this output? I'm opening the extension on the most recent release and I don't see the issue

gcampbell-msft avatar Aug 15 '24 15:08 gcampbell-msft

Quick question, is cmake-tools has any dependencies? Like this extension CMake? image

zhongxiang117 avatar Aug 15 '24 15:08 zhongxiang117

@zhongxiang117 Are you doing anything specific to get this output? I'm opening the extension on the most recent release and I don't see the issue

Could you provide any steps? Are you using any other display language than English?

Quick question, is cmake-tools has any dependencies? Like this extension CMake? image

We don't have a dependency, but we do bundle with the one that you have in your screenshot. We hope to remove that bundle at some point as we implement and improve our own language services for CMake files.

gcampbell-msft avatar Aug 15 '24 15:08 gcampbell-msft

@gcampbell-msft it's not actually a dependency. It is just bundled with this extension. Anyone can uninstall it if they want to use a different language server extension for CMakeLists.txt.

bobbrow avatar Aug 15 '24 15:08 bobbrow

@bobbrow Good clarification, you are correct, it's not a dependency but a bundle. Thanks. I'll update my comment as well

gcampbell-msft avatar Aug 15 '24 15:08 gcampbell-msft

Yeah, the top-level readme has a link to another language server extension.

bobbrow avatar Aug 15 '24 15:08 bobbrow

@zhongxiang117 This has been fixed for a while. You may be referring to the similar but different issue with [warning] [cmake-tools]: Couldn't find message for key cmake-tools.configuration.cmake.deleteBuildDirOnCleanCconfigure.description which is issue #3865 . That one isn't released yet, annoyingly.

@mihailim We have released this in the most recent pre-release. Additionally, we no longer use the key cmake-tools.configuration.cmake.deleteBuildDirOnCleanCconfigure.description, as it has a typo, it was fixed to be cmake-tools.configuration.cmake.deleteBuildDirOnCleanConfigure.description.

gcampbell-msft avatar Aug 15 '24 15:08 gcampbell-msft

OK, I got it, thanks for you two.

The steps is: I installed v1.19.40 and then removed CMake extension, then happened to have this issue.

Now, it seems I cannot reproduce them, v1.19.40 and v1.18.44 both work well.

zhongxiang117 avatar Aug 15 '24 16:08 zhongxiang117