A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/pmd/pmd/issues/5094 below:

[apex] "No adapter exists for type" error message printed to stdout instead of stderr · Issue #5094 · pmd/pmd · GitHub

The error message "No adapter exists for type" error message is being printed to stdout instead of stderr.

This happens with the --json flag provided to PMD - which then causes JSON parsing on stdout to fail.

Full error printed:
No adapter exists for type com.google.summit.ast.declaration.VariableDeclarationGroup.

Source to reproduce:

SObject sobj = new Account();
switch on sobj {
  when Account acc {
    // ^^^ parsed as VariableDeclarationGroup
  }
}

Each branch with a Type name combination causes the error message to be printed out 1x.

Relevant line:

println("No adapter exists for type ${node::class.qualifiedName}")

Reproducible using CLI (pmd check --format json path/to/example -R category/apex/bestpractices.xml --threads 0 --no-progress 2>/dev/null)


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4