schema-codegen currently generates the following from the schema:
import strawberry
@strawberry.type
class Member:
username: str
@strawberry.type
class Query:
member: Member | None
@strawberry.type
class Mutation:
create_user: Member
schema = strawberry.Schema(query=Query, mutation=Mutation)
Here's the schema for reference:
schema {
query: Query
mutation: Mutation
}
type Member {
username: String!
}
type Query {
member: Member
}
type Mutation {
createMember(name: String!): Member!
}
Instead, it should generate the following for our mutations:
@strawberry.type
class Mutation:
@strawberry.mutation
def create_member(self, name: str) -> Member:
return Member(name=name)
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too