awslabs / awslabs/aws-mobile-appsync-sdk-android

Support `null` literal for optional fields

Open
#135 1 comment 0 reactions 0 assignees View on GitHub
feature-request
Dominant language
Java
Stars
106
Forks
56
PR merge metrics
No merged PRs in 30d

Description

Not sure if it's a bug or a missing feature but `null` literals don't seem to work.
Passing `null` to an optional field for a mutation results in the field being ignored.

It's been added to GraphQL, see https://github.com/facebook/graphql/pull/83

Contributor guide

Open the contributing guide

Research direction

Start by tracing how mutation variables are serialized for optional fields in the Android SDK, then compare that behavior with GraphQL's null literal semantics described in the linked specification change. Done means an explicitly supplied null is preserved and sent rather than treated as an omitted field, with regression coverage for the mutation case.

Written by the indexing model from the issue text.

Assessment

Tech stack
android, graphql, java
Domain
api, mobile
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.