(Have reported this here because I assume the issue is with CodeQL CLI)
Description
After cancelling a query in VS Code shortly after I started it, a warning was shown that the generation of the evaluator log summary failed and the following was logged, indicating that a NullPointerException occurred for CodeQL CLI:
Cannot invoke "java.lang.Long.longValue()" because "event.millis" is null
```
Generating log summary using CodeQL CLI: generate log-summary -v --log-to-stderr --format=text --end-summary=#redacted#\Code\User\globalStorage\github.vscode-codeql\queries\equality-check-for-incompatible-types.ql-yF5mW-zjXGhpHhRaGP7a8\evaluator-log-end.summary --sourcemap #redacted#\Code\User\globalStorage\github.vscode-codeql\queries\equality-check-for-incompatible-types.ql-yF5mW-zjXGhpHhRaGP7a8\evaluator-log.jsonl #redacted#\Code\User\globalStorage\github.vscode-codeql\queries\equality-check-for-incompatible-types.ql-yF5mW-zjXGhpHhRaGP7a8\evaluator-log.summary...
Sending shutdown request
Sent shutdown request
[2022-11-27 22:32:59] [PROGRESS] generate log-summary> Beginning to generate summary for query log located at #redacted#\Code\User\globalStorage\github.vscode-codeql\queries\equality-check-for-incompatible-types.ql-yF5mW-zjXGhpHhRaGP7a8\evaluator-log.jsonl
[2022-11-27 22:32:59] [ERROR] generate log-summary> Reached end of log file before footer was found. The output of this command will be incomplete as the input log contains a partial evaluation that did not complete.
[2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 69% of input file
[2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 74% of input file
[2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 79% of input file
[2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 84% of input file
[2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 89% of input file
[2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 94% of input file
[2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 99% of input file
[2022-11-27 22:32:59] Exception caught at top level: java.lang.NullPointerException: Cannot invoke "java.lang.Long.longValue()" because "event.millis" is null
com.semmle.inmemory.logging.ExpensivePredicateTracker.eventTime(ExpensivePredicateTracker.java:33)
com.semmle.inmemory.logging.ExpensivePredicateTracker.lambda$toList$2(ExpensivePredicateTracker.java:45)
java.base/java.util.Comparator.lambda$comparing$77a9974f$1(Unknown Source)
java.base/java.util.TimSort.binarySort(Unknown Source)
java.base/java.util.TimSort.sort(Unknown Source)
java.base/java.util.Arrays.sort(Unknown Source)
java.base/java.util.stream.SortedOps$SizedRefSortingSink.end(Unknown Source)
java.base/java.util.stream.AbstractPipeline.copyInto(Unknown Source)
java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(Unknown Source)
java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(Unknown Source)
java.base/java.util.stream.AbstractPipeline.evaluate(Unknown Source)
java.base/java.util.stream.ReferencePipeline.collect(Unknown Source)
com.semmle.inmemory.logging.ExpensivePredicateTracker.toList(ExpensivePredicateTracker.java:45)
com.semmle.inmemory.logging.HumanLogSummariser.printMostExpensive(HumanLogSummariser.java:570)
com.semmle.inmemory.logging.HumanLogSummariser.writeStagesSummary(HumanLogSummariser.java:536)
com.semmle.cli2.generate.LogSummaryCommand.logMostExpensive(LogSummaryCommand.java:407)
com.semmle.cli2.generate.LogSummaryCommand.executeSubcommand(LogSummaryCommand.java:239)
com.semmle.cli2.picocli.SubcommandCommon.lambda$executeSubcommandWithMessages$2(SubcommandCommon.java:625)
com.semmle.cli2.picocli.SubcommandCommon.withCompilationMessages(SubcommandCommon.java:405)
com.semmle.cli2.picocli.SubcommandCommon.executeSubcommandWithMessages(SubcommandCommon.java:624)
com.semmle.cli2.picocli.SubcommandCommon.executeWithParent(SubcommandCommon.java:545)
com.semmle.cli2.execute.CliServerCommand.lambda$executeSubcommand$0(CliServerCommand.java:67)
com.semmle.cli2.picocli.SubcommandMaker.runMain(SubcommandMaker.java:225)
com.semmle.cli2.execute.CliServerCommand.executeSubcommand(CliServerCommand.java:67)
com.semmle.cli2.picocli.SubcommandCommon.lambda$executeSubcommandWithMessages$2(SubcommandCommon.java:625)
com.semmle.cli2.picocli.SubcommandCommon.withCompilationMessages(SubcommandCommon.java:405)
com.semmle.cli2.picocli.SubcommandCommon.executeSubcommandWithMessages(SubcommandCommon.java:624)
com.semmle.cli2.picocli.SubcommandCommon.call(SubcommandCommon.java:561)
com.semmle.cli2.picocli.SubcommandMaker.runMain(SubcommandMaker.java:225)
com.semmle.cli2.picocli.SubcommandMaker.runMain(SubcommandMaker.java:234)
com.semmle.cli2.CodeQL.main(CodeQL.java:100)
```
Cannot invoke "java.lang.Long.longValue()" because "size" is null
```
[2022-11-27 23:18:51] Exception caught at top level: java.lang.NullPointerException: Cannot invoke "java.lang.Long.longValue()" because "size" is null
com.semmle.inmemory.logging.RecursionSummary.addOne(RecursionSummary.java:35)
com.semmle.inmemory.logging.HumanLogSummariser.printLayerIfComplete(HumanLogSummariser.java:294)
com.semmle.inmemory.logging.HumanLogSummariser.visit(HumanLogSummariser.java:210)
com.semmle.inmemory.logging.HumanLogSummariser.visit(HumanLogSummariser.java:43)
com.semmle.inmemory.logging.json.summary.SummaryEvent.accept(SummaryEvent.java:16)
com.semmle.cli2.generate.LogSummaryCommand.processEvent(LogSummaryCommand.java:370)
com.semmle.cli2.generate.LogSummaryCommand.executeSubcommand(LogSummaryCommand.java:205)
com.semmle.cli2.picocli.SubcommandCommon.lambda$executeSubcommandWithMessages$2(SubcommandCommon.java:625)
com.semmle.cli2.picocli.SubcommandCommon.withCompilationMessages(SubcommandCommon.java:405)
com.semmle.cli2.picocli.SubcommandCommon.executeSubcommandWithMessages(SubcommandCommon.java:624)
com.semmle.cli2.picocli.SubcommandCommon.executeWithParent(SubcommandCommon.java:545)
com.semmle.cli2.execute.CliServerCommand.lambda$executeSubcommand$0(CliServerCommand.java:67)
com.semmle.cli2.picocli.SubcommandMaker.runMain(SubcommandMaker.java:225)
com.semmle.cli2.execute.CliServerCommand.executeSubcommand(CliServerCommand.java:67)
com.semmle.cli2.picocli.SubcommandCommon.lambda$executeSubcommandWithMessages$2(SubcommandCommon.java:625)
com.semmle.cli2.picocli.SubcommandCommon.withCompilationMessages(SubcommandCommon.java:405)
com.semmle.cli2.picocli.SubcommandCommon.executeSubcommandWithMessages(SubcommandCommon.java:624)
com.semmle.cli2.picocli.SubcommandCommon.call(SubcommandCommon.java:561)
com.semmle.cli2.picocli.SubcommandMaker.runMain(SubcommandMaker.java:225)
com.semmle.cli2.picocli.SubcommandMaker.runMain(SubcommandMaker.java:234)
com.semmle.cli2.CodeQL.main(CodeQL.java:100)
```
Version
CodeQL extension version: 1.7.6 CodeQL CLI version: 2.11.4 Platform: win32 x64
(Have reported this here because I assume the issue is with CodeQL CLI)
Description
After cancelling a query in VS Code shortly after I started it, a warning was shown that the generation of the evaluator log summary failed and the following was logged, indicating that a
NullPointerException
occurred for CodeQL CLI:
``` Generating log summary using CodeQL CLI: generate log-summary -v --log-to-stderr --format=text --end-summary=#redacted#\Code\User\globalStorage\github.vscode-codeql\queries\equality-check-for-incompatible-types.ql-yF5mW-zjXGhpHhRaGP7a8\evaluator-log-end.summary --sourcemap #redacted#\Code\User\globalStorage\github.vscode-codeql\queries\equality-check-for-incompatible-types.ql-yF5mW-zjXGhpHhRaGP7a8\evaluator-log.jsonl #redacted#\Code\User\globalStorage\github.vscode-codeql\queries\equality-check-for-incompatible-types.ql-yF5mW-zjXGhpHhRaGP7a8\evaluator-log.summary... Sending shutdown request Sent shutdown request [2022-11-27 22:32:59] [PROGRESS] generate log-summary> Beginning to generate summary for query log located at #redacted#\Code\User\globalStorage\github.vscode-codeql\queries\equality-check-for-incompatible-types.ql-yF5mW-zjXGhpHhRaGP7a8\evaluator-log.jsonl [2022-11-27 22:32:59] [ERROR] generate log-summary> Reached end of log file before footer was found. The output of this command will be incomplete as the input log contains a partial evaluation that did not complete. [2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 69% of input file [2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 74% of input file [2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 79% of input file [2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 84% of input file [2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 89% of input file [2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 94% of input file [2022-11-27 22:32:59] [PROGRESS] generate log-summary> Continuing to generate log summary: have currently processed about 99% of input file [2022-11-27 22:32:59] Exception caught at top level: java.lang.NullPointerException: Cannot invoke "java.lang.Long.longValue()" because "event.millis" is null com.semmle.inmemory.logging.ExpensivePredicateTracker.eventTime(ExpensivePredicateTracker.java:33) com.semmle.inmemory.logging.ExpensivePredicateTracker.lambda$toList$2(ExpensivePredicateTracker.java:45) java.base/java.util.Comparator.lambda$comparing$77a9974f$1(Unknown Source) java.base/java.util.TimSort.binarySort(Unknown Source) java.base/java.util.TimSort.sort(Unknown Source) java.base/java.util.Arrays.sort(Unknown Source) java.base/java.util.stream.SortedOps$SizedRefSortingSink.end(Unknown Source) java.base/java.util.stream.AbstractPipeline.copyInto(Unknown Source) java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(Unknown Source) java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(Unknown Source) java.base/java.util.stream.AbstractPipeline.evaluate(Unknown Source) java.base/java.util.stream.ReferencePipeline.collect(Unknown Source) com.semmle.inmemory.logging.ExpensivePredicateTracker.toList(ExpensivePredicateTracker.java:45) com.semmle.inmemory.logging.HumanLogSummariser.printMostExpensive(HumanLogSummariser.java:570) com.semmle.inmemory.logging.HumanLogSummariser.writeStagesSummary(HumanLogSummariser.java:536) com.semmle.cli2.generate.LogSummaryCommand.logMostExpensive(LogSummaryCommand.java:407) com.semmle.cli2.generate.LogSummaryCommand.executeSubcommand(LogSummaryCommand.java:239) com.semmle.cli2.picocli.SubcommandCommon.lambda$executeSubcommandWithMessages$2(SubcommandCommon.java:625) com.semmle.cli2.picocli.SubcommandCommon.withCompilationMessages(SubcommandCommon.java:405) com.semmle.cli2.picocli.SubcommandCommon.executeSubcommandWithMessages(SubcommandCommon.java:624) com.semmle.cli2.picocli.SubcommandCommon.executeWithParent(SubcommandCommon.java:545) com.semmle.cli2.execute.CliServerCommand.lambda$executeSubcommand$0(CliServerCommand.java:67) com.semmle.cli2.picocli.SubcommandMaker.runMain(SubcommandMaker.java:225) com.semmle.cli2.execute.CliServerCommand.executeSubcommand(CliServerCommand.java:67) com.semmle.cli2.picocli.SubcommandCommon.lambda$executeSubcommandWithMessages$2(SubcommandCommon.java:625) com.semmle.cli2.picocli.SubcommandCommon.withCompilationMessages(SubcommandCommon.java:405) com.semmle.cli2.picocli.SubcommandCommon.executeSubcommandWithMessages(SubcommandCommon.java:624) com.semmle.cli2.picocli.SubcommandCommon.call(SubcommandCommon.java:561) com.semmle.cli2.picocli.SubcommandMaker.runMain(SubcommandMaker.java:225) com.semmle.cli2.picocli.SubcommandMaker.runMain(SubcommandMaker.java:234) com.semmle.cli2.CodeQL.main(CodeQL.java:100) ```Cannot invoke "java.lang.Long.longValue()" because "event.millis" is null
``` [2022-11-27 23:18:51] Exception caught at top level: java.lang.NullPointerException: Cannot invoke "java.lang.Long.longValue()" because "size" is null com.semmle.inmemory.logging.RecursionSummary.addOne(RecursionSummary.java:35) com.semmle.inmemory.logging.HumanLogSummariser.printLayerIfComplete(HumanLogSummariser.java:294) com.semmle.inmemory.logging.HumanLogSummariser.visit(HumanLogSummariser.java:210) com.semmle.inmemory.logging.HumanLogSummariser.visit(HumanLogSummariser.java:43) com.semmle.inmemory.logging.json.summary.SummaryEvent.accept(SummaryEvent.java:16) com.semmle.cli2.generate.LogSummaryCommand.processEvent(LogSummaryCommand.java:370) com.semmle.cli2.generate.LogSummaryCommand.executeSubcommand(LogSummaryCommand.java:205) com.semmle.cli2.picocli.SubcommandCommon.lambda$executeSubcommandWithMessages$2(SubcommandCommon.java:625) com.semmle.cli2.picocli.SubcommandCommon.withCompilationMessages(SubcommandCommon.java:405) com.semmle.cli2.picocli.SubcommandCommon.executeSubcommandWithMessages(SubcommandCommon.java:624) com.semmle.cli2.picocli.SubcommandCommon.executeWithParent(SubcommandCommon.java:545) com.semmle.cli2.execute.CliServerCommand.lambda$executeSubcommand$0(CliServerCommand.java:67) com.semmle.cli2.picocli.SubcommandMaker.runMain(SubcommandMaker.java:225) com.semmle.cli2.execute.CliServerCommand.executeSubcommand(CliServerCommand.java:67) com.semmle.cli2.picocli.SubcommandCommon.lambda$executeSubcommandWithMessages$2(SubcommandCommon.java:625) com.semmle.cli2.picocli.SubcommandCommon.withCompilationMessages(SubcommandCommon.java:405) com.semmle.cli2.picocli.SubcommandCommon.executeSubcommandWithMessages(SubcommandCommon.java:624) com.semmle.cli2.picocli.SubcommandCommon.call(SubcommandCommon.java:561) com.semmle.cli2.picocli.SubcommandMaker.runMain(SubcommandMaker.java:225) com.semmle.cli2.picocli.SubcommandMaker.runMain(SubcommandMaker.java:234) com.semmle.cli2.CodeQL.main(CodeQL.java:100) ```Cannot invoke "java.lang.Long.longValue()" because "size" is null