-
Notifications
You must be signed in to change notification settings - Fork 190
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
"Cannot view the AST" #944
Comments
Hello, thanks for reaching out with this! We are already aware of this issue and have a fix ready which will be in the 2.6.1 release of the CodeQL CLI. |
Hi @kumom, on a deeper look into your issue, I think there is something else going on. @edoardopirovano is correct that we will be releasing a separate fix for the AST viewer in 2.6.1 of the CLI, but I suspect you are having a different problem. The AST viewer will only work on source files inside of a database. There is no need to explicitly unzip the
See here for more information: https://codeql.github.com/docs/codeql-for-visual-studio-code/exploring-the-structure-of-your-source-code/ |
You are right. After selecting the files from
I guess this is expected then. |
Yes, this is still a problem. We are releasing a fix shortly. |
v1.5.5 has been released and this bug is fixed. Please let me know if this works for you. |
Unfortunately, I could not find the folder |
Could you try removing and re-adding the database? You should not need to add any folder to the workspace. The source archive is added automatically when you add the database. |
After removing and re-adding the database, I can see the source archive. The AST Viewer also works as expected now. Thanks a lot! |
Describe the bug
I tried to see the AST generated by CodeQL in VS Code. I chose the
torvalds/linux
database downloaded from LGTM.com, but when thesrc.zip
in the database or some*.c
file unzipped from thesrc.zip
is selected in the editor, the AST cannot be generated. The error message showsVersion
CodeQL extension version: 1.5.4 CodeQL CLI version: 2.6.0 Platform: darwin x64
VS Code:
Version: 1.60.0
Commit: e7d7e9a9348e6a8cc8c03f877d39cb72e5dfb1ff
Date: 2021-09-01T10:54:53.442Z (4 days ago)
Electron: 13.1.8
Chrome: 91.0.4472.164
Node.js: 14.16.0
V8: 9.1.269.39-electron.0
OS: Darwin x64 20.6.0
To reproduce
torvalds/linux
database in theDATABASES
panelsrc.zip
in the database to the editor. ClickView AST
in theAST VIEWER
panel.src.zip
in the database. Open a random*.c
file in the editor. ClickView AST
in theAST VIEWER
panel.Expected behavior
I actually don't know what to expect (i.e., whether it will produce a description of the graph or an image file) because the documentation does not give any examples. That's why I'd like to try it myself.
The text was updated successfully, but these errors were encountered: