Hacktoberfest 2026: as issues que os mantenedores marcaram para outubro, abertas e boas para iniciantes. Ver issues do Hacktoberfest

Variant Analysis Results don't show results without source location in some cases

Aberta
#2,629 1 comentário 0 reações 0 responsáveis Ver no GitHub

Mantenedores costumam responder em até 3 dias

Ninguém assumiu esta issue ainda.

Avaliação

Dificuldade
4/5
Tempo estimado
3-5 dias
Facilidade para iniciantes
45/100
Tipo de issue
Bug
Clareza
Razoavelmente clara
Status de atividade
Estagnada
Stack de tecnologia
typescript, vscode

Direção de pesquisa

Comece reproduzindo a consulta no Quick Query e inspecionando a visualização Variant Analysis Results com resultados que não têm localizações de origem. Compare o comportamento com uma execução em um banco de dados local e com uma consulta cujo primeiro valor da tupla seja uma string. Está concluído quando os resultados omitidos forem claramente contabilizados ou estiverem disponíveis por meio de uma visualização raw-results.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

bug VSCode

Describe the bug
If you use a query with @kind problem in the metadata (or even without @kind, whose select clause has an element as first tuple value, e.g. select element, "my message") and all or some of the elements in the results don't have a source location (for example because they come from an external library), then they are not shown in the Variant Analysis Results view and there is no indication that they were omitted.

This differs from a run for a local database, whose result view includes these results, respectively offers to view the "raw results".

It also differs from a Variant Analysis run without @kind ... in the metadata and where for example a string is the first value in the result tuples (e.g. select "my message", element), which does show the raw results.

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

  1. Open Quick Query and paste the following query
    /**
     * @kind problem
     */
    
    import java
    
    from EnumType t
    where not t.fromSource()
    select t, "my message"
    
  2. Run Variant Analysis, for example on the top 10 repositories
  3. Open the Variant Analysis Results
    ❌ Bug: No results are shown, and there is no indication and no way to show the actual results which don't have a source location

Expected behavior
Either:

  • There should be at least an indication that X results were omitted because they are not in the source code
  • Or better, there should be a way to view the "raw results" (i.e. shown as regular table), which include elements without source location

Additional context
This might affect other @kind types as well.

Linguagem predominante
TypeScript
Estrelas
540
Forks
242
Merge médio
2d 20h
PRs com merge (30d)
36

Preparar o ambiente

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de github/vscode-codeql

Todas as issues de github/vscode-codeql

Issues semelhantes

Mais issues de TypeScript

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.