NullPointerException in scalastyle_2.12-1.0.0

19 views
Skip to first unread message

Tim Calderwood

unread,
Sep 28, 2017, 7:11:13 PM9/28/17
to Scalastyle users
I am running the following command on a Windows 10 Pro 64bit machine with JAVA version 1.8.0.74.

java -jar scalastyle_2.12-1.0.0-batch.jar --config scalastyle_config.xml --xmlOutput test.xml --quiet true C:\Streams\main\Manager\src\main\scala\smv

I am getting the following

Exception in thread "main" java.lang.NullPointerException
        at org.scalastyle.XmlOutput$.printToFile(Output.scala:117)
        at org.scalastyle.XmlOutput$.save(Output.scala:110)
        at org.scalastyle.XmlOutput$.save(Output.scala:96)
        at org.scalastyle.Main$.execute(Main.scala:121)
        at org.scalastyle.Main$.main(Main.scala:99)
        at org.scalastyle.Main.main(Main.scala)

Anybody else seeing this? Is there a fix?

Matthew Farwell

unread,
Sep 30, 2017, 4:21:50 AM9/30/17
to Scalastyle users
Hi,

This is a wierd one. Can you reproduce this? The NullPointerException seems to be coming from File#getParentFile.exists(). Are you perhaps executing this in the root directory?

Can you raise an issue in https://github.com/scalastyle/scalastyle/issues with any relevant information, and I'll have a look at it and try to reproduce it.

Thanks.

Matthew Farwell.
Reply all
Reply to author
Forward
0 new messages