question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`NullPointerException` on `extractTestCase`

See original GitHub issue

First of all, thanks for courgette-jvm, it’s a great tool that has allowed us to boost the execution of our tests.

Running 5.12.0 I’ve seen following exception occasionally:

    java.lang.NullPointerException
        at courgette.runtime.CourgetteNdJsonCreator.extractTestCase(CourgetteNdJsonCreator.java:183)
        at courgette.runtime.CourgetteNdJsonCreator.addMessage(CourgetteNdJsonCreator.java:115)
        at courgette.runtime.CourgetteNdJsonCreator.lambda$null$1(CourgetteNdJsonCreator.java:78)
        at java.util.ArrayList.forEach(ArrayList.java:1259)
        at courgette.runtime.CourgetteNdJsonCreator.lambda$getScenarioMessages$2(CourgetteNdJsonCreator.java:78)
        at java.util.HashMap.forEach(HashMap.java:1289)
        at courgette.runtime.CourgetteNdJsonCreator.getScenarioMessages(CourgetteNdJsonCreator.java:72)
        at courgette.runtime.CourgetteNdJsonCreator.createScenarioMessages(CourgetteNdJsonCreator.java:56)
        at courgette.runtime.CourgetteReporter.createMessages(CourgetteReporter.java:128)
        at courgette.runtime.CourgetteReporter.<init>(CourgetteReporter.java:33)

I’ve not being able to reproduce the problem consistently yet 😞 so can’t provide additional details.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:9 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
marojorcommented, Nov 24, 2021
  1. No other scenario, just those two
  2. rerunFailedScenarios is not set. We use a retries system outside courgette, so as far as courgette knows is just a list of 2 scenarios.
  3. Yes, CourgetteRunLevel.SCENARIO is set.

Waiting for 7.0.0 sounds fair, we’ve reduced the number of threads and so far didn’t hit the crash again, so we can wait with current setup.

If I’m able to create a small project that reproduces the error I’ll share it with you.

0reactions
prashant-ramcharancommented, Dec 5, 2021

Closing issue - please reopen if still an issue and can be reproduced.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Save Failed (1653) - General Database error (2016) - Eclipse
Cannot save editor after copy of lines into new Test Case Save Failed (1653) - General Database error (2016) JubulaVersion: 8.3.1.125
Read more >
JUnit test case: java.lang.NullPointerException - Stack Overflow
I am trying to write test case for following controller code using JUnit and mockito . But I am getting null pointer Exception....
Read more >
Automatically Generating Complex Test Cases from Simple ...
... new RectangleConstraint(200, 100)); // NullPointerException in ... to extract test case fragments related to the instantiation of classes (instantiation ...
Read more >
What is a NullPointerException, and how do I fix it? - YouTube
... and how do I fix it?# NullPointerException exception occurred when you are trying to get something from null referenced object...
Read more >
Null Pointer Exception Java Fix - YouTube
Full Java Course: https://course.alexlorenlee.com/courses/learn-java-fastIf you want to be a Software Engineer, I HIGHLY RECOMMEND applying ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found