This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Tool/software:
This bug is present on both CCS THEIA v1.5.1 and CCS v20.0.0.
When `clangd` detects a problem in a header file, this problem is both highlighted inline and listed in the "Problems" section next to output. When said problem is resolved, the highlight/problem description remains in the header file even when rebuilding the project. This includes the inline highlighting, "Problems" section description, and even the file explorer red highlighting/number of problems annotation.
This problem persists between CCS application restarts, closing/opening the same workspace, deleting the build output folders and rebuilding.
Hello,
I cannot fully reproduce this issue. I see clang-tidy issues in the Problems view get resolved immediately. For some warnings from the clangd parser, it may persist but when rebuilding the project the warning goes away from the Problems view and elsewhere.
Can you provide a small test case? It can be a very simple example project that I can import and experiment with.
Thanks
ki
I've created a minimal reproduction project linked below.
github.com/.../TI_compile_fail_example
Steps to reproduce:
1. Clone repository into desired directory
2. Open repository folder in CCSv20/CCS Theia
3. Open CPU1/include/vehicle.h
4. Delete the `#include <stdbool.h>`
5. Compile, and confirm compilation failure/`clangd` error in `vehicle.h` header file
6. Re-add `#include <stdbool.h>`
7. Compile, and confirm successful compilation but remaining `clangd` error in `vehicle.h` header file
Result sample (Note the successful compilation, but remaining `clangd` error below):
Thanks for the test case. I think the issue is specific to header files that have been added to the project. I need to clean the project to get rid of the messages.
I filed a ticket for this. Tracking link: https://sir.ext.ti.com/jira/browse/EXT_EP-12041
Thanks
ki
Some variant of this same issue is occurring on multiple machines for us as well. It seems to be a problem where a cache is not getting cleaned up properly.
As an example, the following MSP430 project builds just fine, generates an output, and I am able to debug it. Yet, it shows an error here that is completely unrelated to the highlight variables. I believe this file used to have the variables in question at these lines several iterations ago but the "error" is still shown. This remains after cleaning, rebuilding the project, deleting the output Debug directory, etc.
This is CCS Theia 20.0.0.12__1.6.0 on a Windows 10 machine.
We are also dealing with another instance on an Ubuntu 20.04 machine with the same version where the persistent error prevents the project from building. Identical setups on two different machines - it will build on one machine but not the other. The one that doesn't build may have had the specific error in the past but the code has been changed and it still doesn't build.
I think there are issues with this version of Theia. Is there any way to wipe the cache that contains these old errors?
This remains after cleaning, rebuilding the project, deleting the output Debug directory, etc.
Cleaning the project always resolved the issue for me. Deleting the build configuration subfolder would also be deleting the clangd cache folder for the project.
he one that doesn't build may have had the specific error in the past but the code has been changed and it still doesn't build.
This is an unrelated error. Outdated false positive parser errors would not impact the build.
If you can provide small reproducible test cases for both, that would be helpful. For the build issue please provide the full build output copied to a text file and post that log here.
Thanks
ki
Neither cleaning the project nor deleting the Debug build folder resolves the issue. Here is another example, I moved a typedef from a driver file to a higher layer in the application and the error here shows that the type is undefined - even though the line in question is literally defining the type:
There is something "sticky" about the indexer in the latest version of Theia, that isn't tied to the build cache. Removing the output build folder and cleaning the project do not resolve the issue.
This particular project would not be simple to share with you but I think you could replicate it by doing something similar:
It's CCS 20.0.0, which I assumed was Theia because it's based on VSCode and the default workspace is workspace_ccstheia
It's CCS 20.0.0, which I assumed was Theia because it's based on VSCode and the default workspace is workspace_ccstheia
Yes CCS 20 is based on Theia IDE. There is some confusion because we used to have a separate "CCS Theia" product that we discontinued after CCS 20 came out.
I will try again to reproduce on this version with the additional steps you provided.