You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
% wget http://repo1.maven.org/maven2/org/slf4j/slf4j-api/1.7.7/slf4j-api-1.7.7.jar%CLASSPATH=flickrj-android-2.0.8.jar scala-2.10
[...]
scala>new com.googlecode.flickrjandroid.Flickr("a","b")
warning:Class org.json.JSONException not found - continuing with a stub.
[...]
That entry seems to have slain the compiler. ShallI replay
your session?I can re-run each line except the last one.
Some analysis
As far as I can tell, the root cause of the issue is the ClassNotFound on JsonException. Adding json to the classpath make it complain about LoggerFactory, but does not crash the compiler. Adding slf4j make the code work.
% wget http://repo1.maven.org/maven2/org/json/json/20140107/json-20140107.jar% wget http://repo1.maven.org/maven2/org/slf4j/slf4j-api/1.7.7/slf4j-api-1.7.7.jar%CLASSPATH=flickrj-android-2.0.8.jar:json-20140107.jar:slf4j-api-1.7.7.jar scala-2.10
[...]
scala>new com.googlecode.flickrjandroid.Flickr("a","b")
SLF4J:Failed to load class"org.slf4j.impl.StaticLoggerBinder".
SLF4J:Defaulting to no-operation (NOP) logger implementation
SLF4J:See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
res0: com.googlecode.flickrjandroid.Flickr= com.googlecode.flickrjandroid.Flickr@7fe69211
Some (useful ?) context
We found the bug while starting a play project. Adding the flickr4j-android dependency totally break the project with weird errors. For some reason, the json dependency is not declared in the flickr4j pom.
The text was updated successfully, but these errors were encountered:
% tail test.scala build.sbt
==> test.scala <==
object Test {
new com.googlecode.flickrjandroid.Flickr("a","b")
}
==> build.sbt <==
scalaVersion := "2.10.4"
libraryDependencies += "com.googlecode.flickrj-android" % "flickrj-android" % "2.0.8"
% sbt compile
...
[info] 'compiler-interface' not yet compiled for Scala 2.10.5-20140407-165700-ec05aeb3d6. Compiling...
[info] Compilation completed in 10.284 s
[warn] Class org.json.JSONException not found - continuing with a stub.
[error] Class org.json.JSONException not found - continuing with a stub.
[warn] one warning found
[error] one error found
[error] (compile:compile) Compilation failed
[error] Total time: 64 s, completed May 14, 2014 2:24:44 PM
How to reproduce:
Some analysis
As far as I can tell, the root cause of the issue is the ClassNotFound on JsonException. Adding json to the classpath make it complain about LoggerFactory, but does not crash the compiler. Adding slf4j make the code work.
Some (useful ?) context
We found the bug while starting a play project. Adding the flickr4j-android dependency totally break the project with weird errors. For some reason, the json dependency is not declared in the flickr4j pom.
The text was updated successfully, but these errors were encountered: