Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

lift-json should not produce invalid json from JValue instance #1300

fleipold opened this Issue Jul 27, 2012 · 5 comments


None yet
4 participants

JField currently extends JValue

This leads to expressions like the following being compilable:

JObject(List(JField("field1", JField("field2", JString("value")))))

This in turn renders to


which is not valid json.

Currently the ~-operator produces such structures, so there is a bit of work when fixing this...

Looking at the [Json][http://www.json.org/] grammar we can see that:

value:  string |  number | object | array | true | false | null

but not pair as they call the JField.


jonifreeman commented Jul 27, 2012

This will be fixed in version which will probably be Lift 3.0. See:


Cool, thanks. I only checked on trunk.


Shadowfiend commented May 13, 2014

@jonifreeman Can we merge a PR for https://github.com/lift/framework/compare/joni_scala_2.10 into lift_30 and close this ticket, or was there more work you wanted to put in there?


jonifreeman commented May 14, 2014

Yes, this should be ok. They used this branch in json4s when they forked lift-json. AFAIK it has been working well there.


Shadowfiend commented May 14, 2014

Perfect. I'll open up a PR to do that then.

@fmpwizard fmpwizard added this to the 3.0-M2 milestone Jul 2, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment