argonaut json macro

1
Travis Brown @travisbrown

.@xuwei_k Nice! Have you looked at `Liftable`? Here's a quick implementation that should work in both 2.10 and 2.11: https://t.co/ku1OmpWitf

2014-04-21 00:52:40
Travis Brown @travisbrown

@xuwei_k You get more flexibility in how you define them with macro bundles in 2.11 (and a nice `Liftable.apply`, etc.) /cc @den_sh @xeno_by

2014-04-21 01:12:53
Mark Hibberd @markhibberd

After an epic battle with scalac there is an argonaut 6.0.4 release for scala 2.11.0-final: https://t.co/15ivZyzikY (Thanks to @xuwei_k )

2014-04-21 19:09:13
Travis Brown @travisbrown

@xuwei_k By the way, any plans for macro-generated Argonaut codecs (like Play's Inception)? It's on my list of things to do. /cc @mandubian

2014-04-21 19:31:46
Miles Sabin @milessabin

@travisbrown Ahem ... TypeClass and/or LabelledGeneric ;-) /cc @xuwei_k @mandubian

2014-04-21 19:35:57
Travis Brown @travisbrown

@milessabin Yep, `LabelledGeneric` is what I was thinking. Anyone in particular working on this, @seanparsons? /cc @xuwei_k @mandubian

2014-04-21 19:38:33
S @seanparsons

@travisbrown @milessabin @xuwei_k @mandubian I'm moderately busy on the Haskell port, so will probably see a TH implementation first. :)

2014-04-21 19:39:27
Travis Brown @travisbrown

@mandubian Yes—it's very impressive! (I still do want the type-provider-y `Lens[Contact].informations` syntax, though.) /cc @skaalf @xuwei_k

2014-04-21 19:42:17
Mark Hibberd @markhibberd

@travisbrown @milessabin @seanparsons @xuwei_k @mandubian I have a start. Will push up the code. Just not enough time at the moment.

2014-04-21 20:13:43
Mark Hibberd @markhibberd

@travisbrown @milessabin @seanparsons @xuwei_k @mandubian It is sitting to the side for the moment but plan is to move it to companion.

2014-04-21 20:34:30
Travis Brown @travisbrown

@milessabin It's not funny! I don't know how many times I've seen "error: not found: value LabeledGeneric"!

2014-04-21 21:49:41
Travis Brown @travisbrown

@milessabin By the way, thoughts on avoiding collisions without `import AutoDecodeJson.auto.{ derive => deriveDecodeJson }`-ing everything?

2014-04-21 22:19:50
Mark Hibberd @markhibberd

@travisbrown @milessabin I was thinking about that, is it reasonable to just add something to the each companion explicitly with unique name

2014-04-21 22:23:27
Mark Hibberd @markhibberd

@travisbrown @milessabin And not expose the shapeless `.auto` one at all. Seems like one of the few options anyway.

2014-04-21 22:24:32
Mark Hibberd @markhibberd

@milessabin Another q, is there a sensible way to expose LabelledGeneric macro in a way that would let them specify custom label mappings.

2014-04-21 22:29:57
Mark Hibberd @markhibberd

@milessabin I.e. implicit def CustomEncodeJson: EncodeJson[Custom] = derive("fieldOne" -> "field_1", "fieldTwo" -> "field_2")

2014-04-21 22:31:47
Miles Sabin @milessabin

@markhibberd You could take the approach I tried in BlueEyes: https://t.co/pE07tQzpGj. I used an explicit schema value to map names etc.

2014-04-21 22:32:45