0
PythonでGraphQLを使用していますが、リストデータを解決しようとしていますが、フィールドはnullを解決しています。実際のリストデータを返すにはどうしたらいいですか?ここで Graphene Pythonリストはすべてのフィールドでnullを解決します
は、ここに私の現在のクエリ![query](https://i.stack.imgur.com/twfk0.png)
、望ましくない応答であるスニペットは缶がgraphene playground
でテストされ
import graphene
class User(graphene.ObjectType):
""" Type definition for User """
id = graphene.Int()
username = graphene.String()
email = graphene.String()
class Query(graphene.ObjectType):
users = graphene.List(User)
def resolve_users(self, args):
resp = [{'id': 39330, 'username': 'RCraig', 'email':
'[email protected]', 'teamId': 0}, {'id': 39331,
'username': 'AHohmann','email': '[email protected]',
'teamId': 0}]
return resp
schema = graphene.Schema(query=Query)