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

Variant Analysis Results don't show results for certain non-standard select statements #2630

Closed
Marcono1234 opened this issue Jul 22, 2023 · 2 comments
Labels
bug Something isn't working VSCode

Comments

@Marcono1234
Copy link
Contributor

Describe the bug
The Variant Analysis Results view does not show any results for certain non-standard select statements (for queries without @kind), even though the query has results and a local database run does show them.

Maybe closely related to #2629, or even the same underlying issue

Version
Extension version

CodeQL extension version: 1.8.8 
CodeQL CLI version: 2.14.0 
Platform: win32 x64

VS Code version

Version: 1.80.1 (user setup)
Commit: 74f6148eb9ea00507ec113ec51c489d6ffb4b771
Date: 2023-07-12T17:22:07.651Z
Electron: 22.3.14
ElectronBuildId: 21893604
Chromium: 108.0.5359.215
Node.js: 16.17.1
V8: 10.8.168.25-electron.0
OS: Windows_NT x64 10.0.19045

To reproduce
For each of the sample queries below (yes they literally consist only of a select statement), open Quick Query and perform Variant Analysis for them on the top 10 repositories.

  • ✔️ Works
    select "first"
  • ✔️ Works
    select "first", 1
  • ❌ No results
    select "first", "second"

This list is not exhaustive; there might be more cases.

Expected behavior
The raw results table should always be shown if there are results.

@Marcono1234 Marcono1234 added the bug Something isn't working label Jul 22, 2023
@robertbrignull
Copy link
Contributor

Thank you for raising this. This is a known issue that the variant analysis results view can fail to render results sometimes. I don't believe it's the same underlying issue as #2629 and it's more to do with the column types rather than results being from or not from the source.

We've got a couple of internal issues for this and we're going to look into making this behaviour better in two ways:

  • If @kind metadata is given then we want to respect it, so in cases like this you could put @kind table to get it to render the raw results.
  • It shouldn't be as eager to render results as alerts (i.e. problem queries) when the columns don't actually match the right format

@shati-patel
Copy link
Contributor

Thanks again for reporting the issue!

This was fixed by github/codeql-variant-analysis-action#854, so should now be working in the extension.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working VSCode
Projects
None yet
Development

No branches or pull requests

3 participants