Giter Site home page Giter Site logo

Comments (6)

christophercurrie avatar christophercurrie commented on May 23, 2024

Until recently, Jackson core and databind did not publish snapshot version so you had to download the code and compile it yourself. That change recently, so I've just pushed a change that tells SBT where to find the snapshots.

from jackson-module-scala.

dlrodriguez avatar dlrodriguez commented on May 23, 2024

great! that worked! thanks!


David

On Jan 30, 2013, at 10:31 AM, Christopher Currie wrote:

Until recently, Jackson core and databind did not publish snapshot version so you had to download the code and compile it yourself. That change recently, so I've just pushed a change that tells SBT where to find the snapshots.


Reply to this email directly or view it on GitHub.

from jackson-module-scala.

dlrodriguez avatar dlrodriguez commented on May 23, 2024

Pardon my question and my infringement on your time. I really want to use the jackson-scala-module, but I can't even get the initialization to run. With the following simple code:

import com.fasterxml.jackson.databind.ObjectMapper
import com.fasterxml.jackson.module.scala.DefaultScalaModule

object TestJSON extends App {
val mapper = new ObjectMapper()
mapper.registerModule(DefaultScalaModule)
}

I get the following error:

Exception in thread "main" java.util.NoSuchElementException: key not found: groupId
at scala.collection.MapLike$class.default(MapLike.scala:228)
at scala.collection.AbstractMap.default(Map.scala:58)
at scala.collection.MapLike$class.apply(MapLike.scala:141)
at scala.collection.AbstractMap.apply(Map.scala:58)
at com.fasterxml.jackson.module.scala.JacksonModule$.version$lzycompute(JacksonModule.scala:27)
at com.fasterxml.jackson.module.scala.JacksonModule$.version(JacksonModule.scala:26)
at com.fasterxml.jackson.module.scala.JacksonModule$class.version(JacksonModule.scala:45)
at com.fasterxml.jackson.module.scala.DefaultScalaModule.version(DefaultScalaModule.scala:18)
at com.fasterxml.jackson.databind.ObjectMapper.registerModule(ObjectMapper.java:517)
at TestJSON$delayedInit$body.apply(TestJSON.scala:24)
at scala.Function0$class.apply$mcV$sp(Function0.scala:40)
at scala.runtime.AbstractFunction0.apply$mcV$sp(AbstractFunction0.scala:12)
at scala.App$$anonfun$main$1.apply(App.scala:71)
at scala.App$$anonfun$main$1.apply(App.scala:71)
at scala.collection.immutable.List.foreach(List.scala:309)
at scala.collection.generic.TraversableForwarder$class.foreach(TraversableForwarder.scala:32)
at scala.App$class.main(App.scala:71)
at TestJSON$.main(TestJSON.scala:16)
at TestJSON.main(TestJSON.scala)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:120)

I am using scala 2.10.0 to compile everything (including the jack-sacla-module) and the jars listed in the build.sbt file for the jackson library. I am also using Java 7. Am I running unto some Java incompatibility? I'm pretty new to Scala and very new to jackson..in case that doens't show already. :)

If you can help, great. If not, I appreciate your efforts nonetheless. Thanks for contributing.


David

On Jan 30, 2013, at 10:31 AM, Christopher Currie wrote:

Until recently, Jackson core and databind did not publish snapshot version so you had to download the code and compile it yourself. That change recently, so I've just pushed a change that tells SBT where to find the snapshots.


Reply to this email directly or view it on GitHub.

from jackson-module-scala.

christophercurrie avatar christophercurrie commented on May 23, 2024

As far as I know, Scala is still unsupported on Java 7. If you still have this issue on Java 6 then I can take a further look at your use case.

from jackson-module-scala.

dlrodriguez avatar dlrodriguez commented on May 23, 2024

Unfortunately my project also needs Java FX 2.0 and ScalaFX, and I don't believe JavaFX is available for all platforms in Java 6. It's fine...I'll try something else. Thanks for your help.


David

On Feb 3, 2013, at 8:16 PM, Christopher Currie wrote:

As far as I know, Scala is still unsupported on Java 7. If you still have this issue on Java 6 then I can take a further look at your use case.


Reply to this email directly or view it on GitHub.

from jackson-module-scala.

christophercurrie avatar christophercurrie commented on May 23, 2024

FWIW, I might be wrong about Scala's support for Java 7, I have just never tested it. But since Java 6 is hitting end of life this month, I'll look more closely to see if it's failure is due to my code or Scala's.

from jackson-module-scala.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.