Jan Skrasek
09/06/2023, 8:02 AMJan Skrasek
09/06/2023, 8:43 AMmbonnin
09/06/2023, 8:46 AMmbonnin
09/06/2023, 8:47 AMJan Skrasek
09/07/2023, 9:09 AMDateTime
and once we would like to parse it as Instant
and another time as OffsetDateTime
and convert it to LocalDateTime
.mbonnin
09/07/2023, 10:22 AMJan Skrasek
09/07/2023, 10:22 AMmbonnin
09/07/2023, 10:23 AMmbonnin
09/07/2023, 10:23 AMJan Skrasek
09/07/2023, 10:23 AMmbonnin
09/07/2023, 10:23 AMmbonnin
09/07/2023, 10:24 AMmbonnin
09/07/2023, 10:26 AMJan Skrasek
09/07/2023, 10:26 AMmbonnin
09/07/2023, 10:27 AM@specifiedBy
directive in the scalar definition, it makes it explicit what format its usingJan Skrasek
09/07/2023, 10:28 AMmbonnin
09/07/2023, 10:28 AMmbonnin
09/07/2023, 10:29 AMmbonnin
09/07/2023, 10:31 AMmbonnin
09/07/2023, 10:34 AMI think having a LocalDateTime or LocalDate or LocalTime are worth having a discussion, but at the same time they can be represented as an DateTime in some way and I didn't want to make this proposal more complex.
Stylianos Gakis
09/07/2023, 10:38 AMhttps://kotlinlang.slack.com/archives/C01A6KM1SBZ/p1694082391465249?thread_ts=1693987357.862219&cid=C01A6KM1SBZVery interesting! Is there an exhaustive list somewhere for all such scalars? Or is this it, those are all the community-contributed ones? Is there a list where theyโre all together? Just curious about it
mbonnin
09/07/2023, 10:42 AMmbonnin
09/07/2023, 10:42 AMIs there an exhaustive list somewhere for all such scalars?The list is (in small) on top of https://scalars.graphql.org/. Right now it's only LocalDate and DateTime
Stylianos Gakis
09/07/2023, 10:44 AMUpload
scalar, and any other such scalars that exist too.mbonnin
09/07/2023, 10:45 AMStylianos Gakis
09/07/2023, 10:46 AMmbonnin
09/07/2023, 10:46 AMUpload
has never been specifiedStylianos Gakis
09/07/2023, 10:46 AMUpload
just something that you give us in apollo-kotlin for convenience then?mbonnin
09/07/2023, 10:46 AMmbonnin
09/07/2023, 10:46 AMIsActually I don't think apollo-kotlin comes withjust something that you give us in apollo-kotlin for convenience then?Upload
Upload
mbonnin
09/07/2023, 10:47 AMUpload
scalarmbonnin
09/07/2023, 10:47 AMFileUpload
or FooBar
you could still use the apollo-kotlin upload support with mapScalarToUpload("FooBar")
Stylianos Gakis
09/07/2023, 10:47 AMfun Path.toUpload(contentType: String, fileSystem: FileSystem = systemFileSystem): Upload
and so onmbonnin
09/07/2023, 10:48 AMUpload
is a kotlin type herembonnin
09/07/2023, 10:48 AMFooBar
to com.apollographql.apollo3.api.Upload
if you wantStylianos Gakis
09/07/2023, 10:49 AMmapScalarToUpload("Upload")
and we then work with it. And the names being the same in our setup, since we just went with the same name made me forget that we had to do this mapping. Itโs been there since forever and I remember that it was very easy to setup so in my mind I thought itโs just a normal built-in scalar.
I had the wrong impression about all this here, thanks a lot for clearing it all up for me!mbonnin
09/07/2023, 10:49 AMmbonnin
09/07/2023, 10:50 AMmbonnin
09/07/2023, 10:50 AMUpload
, Json
, different Dates
, Long
mbonnin
09/07/2023, 10:50 AM