Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Nov 28 09:42
    alexarchambault closed #323
  • Nov 28 09:42

    alexarchambault on main

    Update sbt to 1.8.0 (#323) (compare)

  • Nov 28 09:42

    alexarchambault on main

    Update nscplugin, sbt-scala-nat… (compare)

  • Nov 28 09:42
    alexarchambault closed #325
  • Nov 28 09:42

    alexarchambault on main

    Update sbt-scalajs, scalajs-com… (compare)

  • Nov 28 09:42
    alexarchambault closed #324
  • Nov 24 13:18
    scala-steward closed #322
  • Nov 24 13:18
    scala-steward commented #322
  • Nov 24 13:18
    scala-steward opened #325
  • Nov 24 13:18
    scala-steward opened #324
  • Nov 12 13:23
    scala-steward opened #323
  • Nov 10 12:53
    scala-steward opened #322
  • Nov 03 10:25

    dependabot[bot] on github_actions

    (compare)

  • Nov 03 10:25

    alexarchambault on main

    Bump coursier/cache-action from… (compare)

  • Nov 03 10:25
    alexarchambault closed #319
  • Nov 03 10:01
    dependabot[bot] edited #319
  • Nov 03 10:01
    dependabot[bot] edited #319
  • Nov 03 10:01
    dependabot[bot] synchronize #319
  • Nov 03 10:01

    dependabot[bot] on github_actions

    Bump coursier/cache-action from… (compare)

  • Nov 03 10:01
    dependabot[bot] edited #319
Alexandre Archambault
@alexarchambault
But implicitly is fine with this, whereas Lazy is not.
Miles Sabin
@milessabin
Ahh!
Alexandre Archambault
@alexarchambault
?? :-)
Miles Sabin
@milessabin
Lazy is a red herring here.
Alexandre Archambault
@alexarchambault
??
Miles Sabin
@milessabin
I think this is a Generic bug ... the Coproduct representation is including private subtypes.
Alexandre Archambault
@alexarchambault
why does the error pop up when using Lazy, and not when using implicitly then?
Miles Sabin
@milessabin
I think if a sealed trait has private subtypes it shouldn't have a Generic instance.
Alexandre Archambault
@alexarchambault
... I agree...
Miles Sabin
@milessabin
Because Lazy has allowed an implicit search path to be explored which wouldn't be without it.
Like I said, Lazy doesn't derive anything, it just controls divergence.
Alexandre Archambault
@alexarchambault
Shoudn't Lazy catch this error in a way or another?
Miles Sabin
@milessabin
Catch what? A bug in Generic?
Alexandre Archambault
@alexarchambault
Why is implicitly fine here?
Miles Sabin
@milessabin
Because Lazy has allowed an implicit search path to be explored which wouldn't be without it.
Alexandre Archambault
@alexarchambault
Yes, I read that... :-)
Miles Sabin
@milessabin
With implicitly we never go down the path that trips the bug.
Does that make sense?
Alexandre Archambault
@alexarchambault
I don't know enough of the internals of Lazy yet (I already tried to understand them though :-)
Miles Sabin
@milessabin
Would you mind trying out Generic on a sealed trait with private subtypes and see what happens?
Alexandre Archambault
@alexarchambault
I'll do that (I can't right now).
Miles Sabin
@milessabin
ie. materialize the Generic in a context which can access the trait but not the subtypes.
Alexandre Archambault
@alexarchambault
I'll try! I have to go, I'll keep you posted.
Thanks!
Miles Sabin
@milessabin
Thanks!
Miles Sabin
@milessabin
Just published shapeless-2.2.4 ... with fixes for most of your Generic prefix bugs.
Alexandre Archambault
@alexarchambault
@milessabin I'll do a release just for the sake of updating the shapeless dependency. And with milessabin/shapeless#418 fixed, there are lots of extra features to add in the next major release.
Miles Sabin
@milessabin
:+1:
Jamie Pullar
@JamiePullar
I have a particular use case for argonaut_shapeless, but find I am unable to resolve it. If I have a serialized form of an unknown subclass and I want to serialize it into its superclass. Using your example of BaseIntString, Im trying to do this Parse.decode[Base]. Is such a thing possible? Would it be possible for there to be a class name parameter to match against? """{"s":"test","i":3, "$class":"BaseIntString"}"""
Alexandre Archambault
@alexarchambault
@JamiePullar It's something that will be in the next version (I have some extra local developments for that, they're awaiting milessabin/shapeless#427)
I'd really like to pack a lot of new developments very soon (that are waiting for too long :-| )
A few developments are already on github thanks too @notxcain, but undocumented and not enough tested for now
Jamie Pullar
@JamiePullar
Great news, I'll keep an eye on it!
Miles Sabin
@milessabin
Sorry about the hold up ... I'm trying to get 2.12.0-M2 100% before cutting a new release.
Alexandre Archambault
@alexarchambault
@milessabin np, I changed and added quite a few things since the PR... I need to put that in shape.
Jeffrey N. Davis
@penland365
Hi everyone, I have what is probably an easy question - I have a DecodeJson operation that fails on decoding an Option[Float], but is succesful when the field is present. Example =>
case class Foo(bar: Int, baz: Int, moo: Option[Float])
implicit val decodeJson = implicitly[DecodeJson[Foo]]

Json =>

{
  bar: 3,
  baz: 1
}

fails

Alexandre Archambault
@alexarchambault
@penland365 It's fine with 0.4.0-SNAPSHOT (but not with 0.3.1, which is the last stable version)
A few things are going to change, this point happens to be fixed with these...
Hopefully, I'll do a 0.4.0 release soon (I should have some funployment soon :-)
So if you're fine with snapshots, use 0.4.0-SNAPSHOT (but other things may change too, be careful).
Alexandre Archambault
@alexarchambault
Another point: argonaut seems to require the field names to be quoted, I tested with
{
  "bar": 3,
  "baz": 1
}
Rodolfo Hansen
@kryptt
yes, the quotes are required in the json spec as well
Jeffrey N. Davis
@penland365
Sorry about that, the JSON is quoted, my attempts to create an example failed there
Also, thanks a million for this library - it's amazing
Srepfler Srdan
@schrepfler
hi all, let's say there's a rest service returning json, and this json is pretty big tree, 10 results can have a payload of >1.5MB
can I use somehow lenses to say, i need this this and this path
or block this this and that path
so that I kind of 'prune' the tree to something smaller
Nir Levanon
@NirLevanon
I need some help, I'm not really sure how to deal with the implicits that argonaut requires.
Nir Levanon
@NirLevanon
I can't run the example of the automatic codec, I keep getting a "could not find implicit value for evidence parameter of type argonaut.EncodeJson[<sealed type>]" errors