STAMP-project/dspot

java.io.FileNotFoundException: (No such file or directory)

RenanGreca opened this issue ยท 1 comments

Characteristics

  • Reproducibility: Always
  • Severity: Unclear
  • Tool/Service/Component: Dspot 3.2.0
  • Execution Environment: Ubuntu 20.04, openjdk version "1.8.0_312"

Description

Whenever I run Dspot, either the example or on another project, the first thing the log shows is this:

log4j:ERROR setFile(null,true) call failed.
java.io.FileNotFoundException:  (No such file or directory)
	at java.io.FileOutputStream.open0(Native Method)
	at java.io.FileOutputStream.open(FileOutputStream.java:270)
	at java.io.FileOutputStream.<init>(FileOutputStream.java:213)
	at java.io.FileOutputStream.<init>(FileOutputStream.java:133)
	at org.apache.log4j.FileAppender.setFile(FileAppender.java:294)
	at org.apache.log4j.RollingFileAppender.setFile(RollingFileAppender.java:207)
	at org.apache.log4j.FileAppender.activateOptions(FileAppender.java:165)
	at org.apache.log4j.config.PropertySetter.activate(PropertySetter.java:307)
	at org.apache.log4j.config.PropertySetter.setProperties(PropertySetter.java:172)
	at org.apache.log4j.config.PropertySetter.setProperties(PropertySetter.java:104)
	at org.apache.log4j.PropertyConfigurator.parseAppender(PropertyConfigurator.java:842)
	at org.apache.log4j.PropertyConfigurator.parseCategory(PropertyConfigurator.java:768)
	at org.apache.log4j.PropertyConfigurator.parseCatsAndRenderers(PropertyConfigurator.java:672)
	at org.apache.log4j.PropertyConfigurator.doConfigure(PropertyConfigurator.java:516)
	at org.apache.log4j.PropertyConfigurator.doConfigure(PropertyConfigurator.java:580)
	at org.apache.log4j.helpers.OptionConverter.selectAndConfigure(OptionConverter.java:526)
	at org.apache.log4j.LogManager.<clinit>(LogManager.java:127)
	at org.slf4j.impl.Log4jLoggerFactory.<init>(Log4jLoggerFactory.java:66)
	at org.slf4j.impl.StaticLoggerBinder.<init>(StaticLoggerBinder.java:72)
	at org.slf4j.impl.StaticLoggerBinder.<clinit>(StaticLoggerBinder.java:45)
	at org.slf4j.LoggerFactory.bind(LoggerFactory.java:150)
	at org.slf4j.LoggerFactory.performInitialization(LoggerFactory.java:124)
	at org.slf4j.LoggerFactory.getILoggerFactory(LoggerFactory.java:412)
	at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:357)
	at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:383)
	at eu.stamp_project.dspot.common.miscellaneous.DSpotUtils.<clinit>(DSpotUtils.java:35)
	at eu.stamp_project.dspot.common.configuration.UserInput.setAbsolutePathToProjectRoot(UserInput.java:636)
	at eu.stamp_project.dspot.common.configuration.UserInput.configureExample(UserInput.java:1062)
	at eu.stamp_project.Main.parse(Main.java:43)
	at eu.stamp_project.Main.main(Main.java:15)

It seems to be searching for a blank string as filename (hence no file path after the exception). But I don't know where it's coming from and whether I need to add a parameter.

It's also unclear to me if this is affecting the tool's execution in general. After this exception, the tool seems to run normally.

Steps to reproduce

Just run java -jar dspot-3.2.0-jar-with-dependencies.jar --example.

Properties file

n/a

Command Line / Options
java -jar dspot-3.2.0-jar-with-dependencies.jar --example

Hey @RenanGreca ! ๐Ÿ˜Š

I'm running / working on DSpot for quite a while and often have this same message in my log output, too.
(not always curiously...)
However, also does not impact the actual amplification!

Tried tracking it down a few times by now. How far I came is that it's happening when initializing the logger in the Checker class (which checks whether the command line arguments make sense).

Maybe it has something to do with the configured properties or so? I see it happening when I run DSpot through the .jar as part of my IntelliJ plugin, but e.g. not when executing DSpot directly from the IntelliJ run configuration.

Maybe that additional info helps, would be great to solve it, but I never got further ๐Ÿ˜„๐Ÿ˜‰