I just spent the better part of my afternoon debugging a null pointer exception in my code. The reason for this is a faulty jdk annotation that IDEA gets from somewhere.
The offending method is org.w3c.dom.Node#getAttributes(). In the jdkAnnotations.jar file that IntelliJ uses for external annotations, this method is listed as having a NotNull annotation. However, the method javadoc from the jdk mention that null values can be returned.
I have two questions:
- Why is this method annotated as NotNull if this is not the case?
- What is the source of this file? It has appeared in my IDEA settings but I'm not sure where it comes from. Who decides what goes in here?