aboutsummaryrefslogtreecommitdiffstats
path: root/graphql
diff options
context:
space:
mode:
authorMichael Muré <batolettre@gmail.com>2020-02-09 20:08:12 +0100
committerMichael Muré <batolettre@gmail.com>2020-02-09 20:23:38 +0100
commitb3d3612393387c83fa43f908dbb8e2a71068c834 (patch)
treee4609e21dc74e535d45b38cd7d0504681c544160 /graphql
parentdca85b309a0a82e9993a345964d0831ab2876fb4 (diff)
parent3caffeef4d2ed25d4eb5d4bfd262f4fc3b92561f (diff)
downloadgit-bug-b3d3612393387c83fa43f908dbb8e2a71068c834.tar.gz
Merge remote-tracking branch 'origin/master' into cheshirekow-jira
Diffstat (limited to 'graphql')
-rw-r--r--graphql/connections/connections.go2
-rw-r--r--graphql/connections/edges.go (renamed from graphql/connections/lazy_identity.go)11
-rw-r--r--graphql/connections/gen_identity.go11
-rw-r--r--graphql/connections/lazy_bug.go14
-rw-r--r--graphql/gqlgen.yml15
-rw-r--r--graphql/graph/gen_graph.go4017
-rw-r--r--graphql/graphql_test.go6
-rw-r--r--graphql/handler.go7
-rw-r--r--graphql/models/gen_models.go35
-rw-r--r--graphql/models/lazy_bug.go215
-rw-r--r--graphql/models/lazy_identity.go167
-rw-r--r--graphql/resolvers/bug.go66
-rw-r--r--graphql/resolvers/color.go6
-rw-r--r--graphql/resolvers/comment.go17
-rw-r--r--graphql/resolvers/identity.go40
-rw-r--r--graphql/resolvers/mutation.go32
-rw-r--r--graphql/resolvers/operations.go52
-rw-r--r--graphql/resolvers/query.go4
-rw-r--r--graphql/resolvers/repo.go50
-rw-r--r--graphql/resolvers/root.go4
-rw-r--r--graphql/resolvers/timeline.go48
-rw-r--r--graphql/schema/identity.graphql4
-rw-r--r--graphql/schema/root.graphql2
23 files changed, 2361 insertions, 2464 deletions
diff --git a/graphql/connections/connections.go b/graphql/connections/connections.go
index 82ad2514..0083f8b2 100644
--- a/graphql/connections/connections.go
+++ b/graphql/connections/connections.go
@@ -1,6 +1,6 @@
//go:generate genny -in=connection_template.go -out=gen_lazy_bug.go gen "Name=LazyBug NodeType=entity.Id EdgeType=LazyBugEdge ConnectionType=models.BugConnection"
//go:generate genny -in=connection_template.go -out=gen_lazy_identity.go gen "Name=LazyIdentity NodeType=entity.Id EdgeType=LazyIdentityEdge ConnectionType=models.IdentityConnection"
-//go:generate genny -in=connection_template.go -out=gen_identity.go gen "Name=Identity NodeType=identity.Interface EdgeType=models.IdentityEdge ConnectionType=models.IdentityConnection"
+//go:generate genny -in=connection_template.go -out=gen_identity.go gen "Name=Identity NodeType=models.IdentityWrapper EdgeType=models.IdentityEdge ConnectionType=models.IdentityConnection"
//go:generate genny -in=connection_template.go -out=gen_operation.go gen "Name=Operation NodeType=bug.Operation EdgeType=models.OperationEdge ConnectionType=models.OperationConnection"
//go:generate genny -in=connection_template.go -out=gen_comment.go gen "Name=Comment NodeType=bug.Comment EdgeType=models.CommentEdge ConnectionType=models.CommentConnection"
//go:generate genny -in=connection_template.go -out=gen_timeline.go gen "Name=TimelineItem NodeType=bug.TimelineItem EdgeType=models.TimelineItemEdge ConnectionType=models.TimelineItemConnection"
diff --git a/graphql/connections/lazy_identity.go b/graphql/connections/edges.go
index 3274dd7e..4e37fcd9 100644
--- a/graphql/connections/lazy_identity.go
+++ b/graphql/connections/edges.go
@@ -2,6 +2,17 @@ package connections
import "github.com/MichaelMure/git-bug/entity"
+// LazyBugEdge is a special relay edge used to implement a lazy loading connection
+type LazyBugEdge struct {
+ Id entity.Id
+ Cursor string
+}
+
+// GetCursor return the cursor of a LazyBugEdge
+func (lbe LazyBugEdge) GetCursor() string {
+ return lbe.Cursor
+}
+
// LazyIdentityEdge is a special relay edge used to implement a lazy loading connection
type LazyIdentityEdge struct {
Id entity.Id
diff --git a/graphql/connections/gen_identity.go b/graphql/connections/gen_identity.go
index b52b6f96..061e8936 100644
--- a/graphql/connections/gen_identity.go
+++ b/graphql/connections/gen_identity.go
@@ -8,23 +8,22 @@ import (
"fmt"
"github.com/MichaelMure/git-bug/graphql/models"
- "github.com/MichaelMure/git-bug/identity"
)
-// IdentityInterfaceEdgeMaker define a function that take a identity.Interface and an offset and
+// ModelsIdentityWrapperEdgeMaker define a function that take a models.IdentityWrapper and an offset and
// create an Edge.
-type IdentityEdgeMaker func(value identity.Interface, offset int) Edge
+type IdentityEdgeMaker func(value models.IdentityWrapper, offset int) Edge
// IdentityConMaker define a function that create a models.IdentityConnection
type IdentityConMaker func(
edges []*models.IdentityEdge,
- nodes []identity.Interface,
+ nodes []models.IdentityWrapper,
info *models.PageInfo,
totalCount int) (*models.IdentityConnection, error)
// IdentityCon will paginate a source according to the input of a relay connection
-func IdentityCon(source []identity.Interface, edgeMaker IdentityEdgeMaker, conMaker IdentityConMaker, input models.ConnectionInput) (*models.IdentityConnection, error) {
- var nodes []identity.Interface
+func IdentityCon(source []models.IdentityWrapper, edgeMaker IdentityEdgeMaker, conMaker IdentityConMaker, input models.ConnectionInput) (*models.IdentityConnection, error) {
+ var nodes []models.IdentityWrapper
var edges []*models.IdentityEdge
var cursors []string
var pageInfo = &models.PageInfo{}
diff --git a/graphql/connections/lazy_bug.go b/graphql/connections/lazy_bug.go
deleted file mode 100644
index 00692e8b..00000000
--- a/graphql/connections/lazy_bug.go
+++ /dev/null
@@ -1,14 +0,0 @@
-package connections
-
-import "github.com/MichaelMure/git-bug/entity"
-
-// LazyBugEdge is a special relay edge used to implement a lazy loading connection
-type LazyBugEdge struct {
- Id entity.Id
- Cursor string
-}
-
-// GetCursor return the cursor of a LazyBugEdge
-func (lbe LazyBugEdge) GetCursor() string {
- return lbe.Cursor
-}
diff --git a/graphql/gqlgen.yml b/graphql/gqlgen.yml
index fc27cc2d..fe33b8c7 100644
--- a/graphql/gqlgen.yml
+++ b/graphql/gqlgen.yml
@@ -10,13 +10,24 @@ models:
RepositoryMutation:
model: github.com/MichaelMure/git-bug/graphql/models.RepositoryMutation
Bug:
- model: github.com/MichaelMure/git-bug/bug.Snapshot
+ model: github.com/MichaelMure/git-bug/graphql/models.BugWrapper
+ fields:
+ actors:
+ resolver: true
+ participants:
+ resolver: true
+ comments:
+ resolver: true
+ timeline:
+ resolver: true
+ operations:
+ resolver: true
Color:
model: image/color.RGBA
Comment:
model: github.com/MichaelMure/git-bug/bug.Comment
Identity:
- model: github.com/MichaelMure/git-bug/identity.Interface
+ model: github.com/MichaelMure/git-bug/graphql/models.IdentityWrapper
Label:
model: github.com/MichaelMure/git-bug/bug.Label
Hash:
diff --git a/graphql/graph/gen_graph.go b/graphql/graph/gen_graph.go
index a1f7133d..67913377 100644
--- a/graphql/graph/gen_graph.go
+++ b/graphql/graph/gen_graph.go
@@ -17,7 +17,6 @@ import (
"github.com/99designs/gqlgen/graphql/introspection"
"github.com/MichaelMure/git-bug/bug"
"github.com/MichaelMure/git-bug/graphql/models"
- "github.com/MichaelMure/git-bug/identity"
"github.com/MichaelMure/git-bug/util/git"
"github.com/vektah/gqlparser"
"github.com/vektah/gqlparser/ast"
@@ -45,6 +44,7 @@ type ResolverRoot interface {
AddCommentTimelineItem() AddCommentTimelineItemResolver
Bug() BugResolver
Color() ColorResolver
+ Comment() CommentResolver
CommentHistoryStep() CommentHistoryStepResolver
CreateOperation() CreateOperationResolver
CreateTimelineItem() CreateTimelineItemResolver
@@ -204,13 +204,12 @@ type ComplexityRoot struct {
}
Identity struct {
- AvatarURL func(childComplexity int) int
+ AvatarUrl func(childComplexity int) int
DisplayName func(childComplexity int) int
Email func(childComplexity int) int
HumanID func(childComplexity int) int
ID func(childComplexity int) int
IsProtected func(childComplexity int) int
- Login func(childComplexity int) int
Name func(childComplexity int) int
}
@@ -371,61 +370,59 @@ type ComplexityRoot struct {
type AddCommentOperationResolver interface {
ID(ctx context.Context, obj *bug.AddCommentOperation) (string, error)
-
+ Author(ctx context.Context, obj *bug.AddCommentOperation) (models.IdentityWrapper, error)
Date(ctx context.Context, obj *bug.AddCommentOperation) (*time.Time, error)
}
type AddCommentTimelineItemResolver interface {
ID(ctx context.Context, obj *bug.AddCommentTimelineItem) (string, error)
+ Author(ctx context.Context, obj *bug.AddCommentTimelineItem) (models.IdentityWrapper, error)
CreatedAt(ctx context.Context, obj *bug.AddCommentTimelineItem) (*time.Time, error)
LastEdit(ctx context.Context, obj *bug.AddCommentTimelineItem) (*time.Time, error)
}
type BugResolver interface {
- ID(ctx context.Context, obj *bug.Snapshot) (string, error)
- HumanID(ctx context.Context, obj *bug.Snapshot) (string, error)
- Status(ctx context.Context, obj *bug.Snapshot) (models.Status, error)
+ ID(ctx context.Context, obj models.BugWrapper) (string, error)
+ HumanID(ctx context.Context, obj models.BugWrapper) (string, error)
+ Status(ctx context.Context, obj models.BugWrapper) (models.Status, error)
- LastEdit(ctx context.Context, obj *bug.Snapshot) (*time.Time, error)
- Actors(ctx context.Context, obj *bug.Snapshot, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error)
- Participants(ctx context.Context, obj *bug.Snapshot, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error)
- Comments(ctx context.Context, obj *bug.Snapshot, after *string, before *string, first *int, last *int) (*models.CommentConnection, error)
- Timeline(ctx context.Context, obj *bug.Snapshot, after *string, before *string, first *int, last *int) (*models.TimelineItemConnection, error)
- Operations(ctx context.Context, obj *bug.Snapshot, after *string, before *string, first *int, last *int) (*models.OperationConnection, error)
+ Actors(ctx context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error)
+ Participants(ctx context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error)
+ Comments(ctx context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.CommentConnection, error)
+ Timeline(ctx context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.TimelineItemConnection, error)
+ Operations(ctx context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.OperationConnection, error)
}
type ColorResolver interface {
R(ctx context.Context, obj *color.RGBA) (int, error)
G(ctx context.Context, obj *color.RGBA) (int, error)
B(ctx context.Context, obj *color.RGBA) (int, error)
}
+type CommentResolver interface {
+ Author(ctx context.Context, obj *bug.Comment) (models.IdentityWrapper, error)
+}
type CommentHistoryStepResolver interface {
Date(ctx context.Context, obj *bug.CommentHistoryStep) (*time.Time, error)
}
type CreateOperationResolver interface {
ID(ctx context.Context, obj *bug.CreateOperation) (string, error)
-
+ Author(ctx context.Context, obj *bug.CreateOperation) (models.IdentityWrapper, error)
Date(ctx context.Context, obj *bug.CreateOperation) (*time.Time, error)
}
type CreateTimelineItemResolver interface {
ID(ctx context.Context, obj *bug.CreateTimelineItem) (string, error)
+ Author(ctx context.Context, obj *bug.CreateTimelineItem) (models.IdentityWrapper, error)
CreatedAt(ctx context.Context, obj *bug.CreateTimelineItem) (*time.Time, error)
LastEdit(ctx context.Context, obj *bug.CreateTimelineItem) (*time.Time, error)
}
type EditCommentOperationResolver interface {
ID(ctx context.Context, obj *bug.EditCommentOperation) (string, error)
-
+ Author(ctx context.Context, obj *bug.EditCommentOperation) (models.IdentityWrapper, error)
Date(ctx context.Context, obj *bug.EditCommentOperation) (*time.Time, error)
Target(ctx context.Context, obj *bug.EditCommentOperation) (string, error)
}
type IdentityResolver interface {
- ID(ctx context.Context, obj *identity.Interface) (string, error)
- HumanID(ctx context.Context, obj *identity.Interface) (string, error)
- Name(ctx context.Context, obj *identity.Interface) (*string, error)
- Email(ctx context.Context, obj *identity.Interface) (*string, error)
- Login(ctx context.Context, obj *identity.Interface) (*string, error)
- DisplayName(ctx context.Context, obj *identity.Interface) (string, error)
- AvatarURL(ctx context.Context, obj *identity.Interface) (*string, error)
- IsProtected(ctx context.Context, obj *identity.Interface) (bool, error)
+ ID(ctx context.Context, obj models.IdentityWrapper) (string, error)
+ HumanID(ctx context.Context, obj models.IdentityWrapper) (string, error)
}
type LabelResolver interface {
Name(ctx context.Context, obj *bug.Label) (string, error)
@@ -433,7 +430,7 @@ type LabelResolver interface {
}
type LabelChangeOperationResolver interface {
ID(ctx context.Context, obj *bug.LabelChangeOperation) (string, error)
-
+ Author(ctx context.Context, obj *bug.LabelChangeOperation) (models.IdentityWrapper, error)
Date(ctx context.Context, obj *bug.LabelChangeOperation) (*time.Time, error)
}
type LabelChangeResultResolver interface {
@@ -441,7 +438,7 @@ type LabelChangeResultResolver interface {
}
type LabelChangeTimelineItemResolver interface {
ID(ctx context.Context, obj *bug.LabelChangeTimelineItem) (string, error)
-
+ Author(ctx context.Context, obj *bug.LabelChangeTimelineItem) (models.IdentityWrapper, error)
Date(ctx context.Context, obj *bug.LabelChangeTimelineItem) (*time.Time, error)
}
type MutationResolver interface {
@@ -460,32 +457,32 @@ type QueryResolver interface {
}
type RepositoryResolver interface {
AllBugs(ctx context.Context, obj *models.Repository, after *string, before *string, first *int, last *int, query *string) (*models.BugConnection, error)
- Bug(ctx context.Context, obj *models.Repository, prefix string) (*bug.Snapshot, error)
+ Bug(ctx context.Context, obj *models.Repository, prefix string) (models.BugWrapper, error)
AllIdentities(ctx context.Context, obj *models.Repository, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error)
- Identity(ctx context.Context, obj *models.Repository, prefix string) (identity.Interface, error)
- UserIdentity(ctx context.Context, obj *models.Repository) (identity.Interface, error)
+ Identity(ctx context.Context, obj *models.Repository, prefix string) (models.IdentityWrapper, error)
+ UserIdentity(ctx context.Context, obj *models.Repository) (models.IdentityWrapper, error)
ValidLabels(ctx context.Context, obj *models.Repository, after *string, before *string, first *int, last *int) (*models.LabelConnection, error)
}
type SetStatusOperationResolver interface {
ID(ctx context.Context, obj *bug.SetStatusOperation) (string, error)
-
+ Author(ctx context.Context, obj *bug.SetStatusOperation) (models.IdentityWrapper, error)
Date(ctx context.Context, obj *bug.SetStatusOperation) (*time.Time, error)
Status(ctx context.Context, obj *bug.SetStatusOperation) (models.Status, error)
}
type SetStatusTimelineItemResolver interface {
ID(ctx context.Context, obj *bug.SetStatusTimelineItem) (string, error)
-
+ Author(ctx context.Context, obj *bug.SetStatusTimelineItem) (models.IdentityWrapper, error)
Date(ctx context.Context, obj *bug.SetStatusTimelineItem) (*time.Time, error)
Status(ctx context.Context, obj *bug.SetStatusTimelineItem) (models.Status, error)
}
type SetTitleOperationResolver interface {
ID(ctx context.Context, obj *bug.SetTitleOperation) (string, error)
-
+ Author(ctx context.Context, obj *bug.SetTitleOperation) (models.IdentityWrapper, error)
Date(ctx context.Context, obj *bug.SetTitleOperation) (*time.Time, error)
}
type SetTitleTimelineItemResolver interface {
ID(ctx context.Context, obj *bug.SetTitleTimelineItem) (string, error)
-
+ Author(ctx context.Context, obj *bug.SetTitleTimelineItem) (models.IdentityWrapper, error)
Date(ctx context.Context, obj *bug.SetTitleTimelineItem) (*time.Time, error)
}
@@ -1104,11 +1101,11 @@ func (e *executableSchema) Complexity(typeName, field string, childComplexity in
return e.complexity.EditCommentOperation.Target(childComplexity), true
case "Identity.avatarUrl":
- if e.complexity.Identity.AvatarURL == nil {
+ if e.complexity.Identity.AvatarUrl == nil {
break
}
- return e.complexity.Identity.AvatarURL(childComplexity), true
+ return e.complexity.Identity.AvatarUrl(childComplexity), true
case "Identity.displayName":
if e.complexity.Identity.DisplayName == nil {
@@ -1145,13 +1142,6 @@ func (e *executableSchema) Complexity(typeName, field string, childComplexity in
return e.complexity.Identity.IsProtected(childComplexity), true
- case "Identity.login":
- if e.complexity.Identity.Login == nil {
- break
- }
-
- return e.complexity.Identity.Login(childComplexity), true
-
case "Identity.name":
if e.complexity.Identity.Name == nil {
break
@@ -1828,46 +1818,48 @@ func (e *executableSchema) Complexity(typeName, field string, childComplexity in
return 0, false
}
-func (e *executableSchema) Query(ctx context.Context, op *ast.OperationDefinition) *graphql.Response {
- ec := executionContext{graphql.GetRequestContext(ctx), e}
-
- buf := ec.RequestMiddleware(ctx, func(ctx context.Context) []byte {
- data := ec._Query(ctx, op.SelectionSet)
- var buf bytes.Buffer
- data.MarshalGQL(&buf)
- return buf.Bytes()
- })
+func (e *executableSchema) Exec(ctx context.Context) graphql.ResponseHandler {
+ rc := graphql.GetOperationContext(ctx)
+ ec := executionContext{rc, e}
+ first := true
- return &graphql.Response{
- Data: buf,
- Errors: ec.Errors,
- Extensions: ec.Extensions,
- }
-}
+ switch rc.Operation.Operation {
+ case ast.Query:
+ return func(ctx context.Context) *graphql.Response {
+ if !first {
+ return nil
+ }
+ first = false
+ data := ec._Query(ctx, rc.Operation.SelectionSet)
+ var buf bytes.Buffer
+ data.MarshalGQL(&buf)
-func (e *executableSchema) Mutation(ctx context.Context, op *ast.OperationDefinition) *graphql.Response {
- ec := executionContext{graphql.GetRequestContext(ctx), e}
+ return &graphql.Response{
+ Data: buf.Bytes(),
+ }
+ }
+ case ast.Mutation:
+ return func(ctx context.Context) *graphql.Response {
+ if !first {
+ return nil
+ }
+ first = false
+ data := ec._Mutation(ctx, rc.Operation.SelectionSet)
+ var buf bytes.Buffer
+ data.MarshalGQL(&buf)
- buf := ec.RequestMiddleware(ctx, func(ctx context.Context) []byte {
- data := ec._Mutation(ctx, op.SelectionSet)
- var buf bytes.Buffer
- data.MarshalGQL(&buf)
- return buf.Bytes()
- })
+ return &graphql.Response{
+ Data: buf.Bytes(),
+ }
+ }
- return &graphql.Response{
- Data: buf,
- Errors: ec.Errors,
- Extensions: ec.Extensions,
+ default:
+ return graphql.OneShot(graphql.ErrorResponse(ctx, "unsupported GraphQL operation"))
}
}
-func (e *executableSchema) Subscription(ctx context.Context, op *ast.OperationDefinition) func() *graphql.Response {
- return graphql.OneShot(graphql.ErrorResponse(ctx, "subscriptions are not supported"))
-}
-
type executionContext struct {
- *graphql.RequestContext
+ *graphql.OperationContext
*executableSchema
}
@@ -1885,7 +1877,7 @@ func (ec *executionContext) introspectType(name string) (*introspection.Type, er
return introspection.WrapTypeFromDef(parsedSchema, parsedSchema.Types[name]), nil
}
-var parsedSchema = gqlparser.MustLoadSchema(
+var sources = []*ast.Source{
&ast.Source{Name: "schema/bug.graphql", Input: `"""Represents a comment on a bug."""
type Comment implements Authored {
"""The author of this comment."""
@@ -2004,7 +1996,7 @@ type BugEdge {
"""The item at the end of the edge."""
node: Bug!
}
-`},
+`, BuiltIn: false},
&ast.Source{Name: "schema/identity.graphql", Input: `"""Represents an identity"""
type Identity {
"""The identifier for this identity"""
@@ -2015,9 +2007,7 @@ type Identity {
name: String
"""The email of the person, if known."""
email: String
- """The login of the person, if known."""
- login: String
- """A string containing the either the name of the person, its login or both"""
+ """A non-empty string to display, representing the identity, based on the non-empty values."""
displayName: String!
"""An url to an avatar"""
avatarUrl: String
@@ -2036,7 +2026,7 @@ type IdentityConnection {
type IdentityEdge {
cursor: String!
node: Identity!
-}`},
+}`, BuiltIn: false},
&ast.Source{Name: "schema/label.graphql", Input: `"""Label for a bug."""
type Label {
"""The name of the label."""
@@ -2055,7 +2045,7 @@ type LabelConnection {
type LabelEdge {
cursor: String!
node: Label!
-}`},
+}`, BuiltIn: false},
&ast.Source{Name: "schema/mutations.graphql", Input: `input NewBugInput {
"""A unique identifier for the client performing the mutation."""
clientMutationId: String
@@ -2226,7 +2216,7 @@ type CommitAsNeededPayload {
"""The affected bug."""
bug: Bug!
}
-`},
+`, BuiltIn: false},
&ast.Source{Name: "schema/operations.graphql", Input: `"""An operation applied to a bug."""
interface Operation {
"""The identifier of the operation"""
@@ -2327,7 +2317,7 @@ type LabelChangeOperation implements Operation & Authored {
added: [Label!]!
removed: [Label!]!
}
-`},
+`, BuiltIn: false},
&ast.Source{Name: "schema/repository.graphql", Input: `
type Repository {
"""All the bugs"""
@@ -2374,12 +2364,14 @@ type Repository {
"""Returns the last _n_ elements from the list."""
last: Int
): LabelConnection!
-}`},
+}`, BuiltIn: false},
&ast.Source{Name: "schema/root.graphql", Input: `type Query {
"""The default unnamend repository."""
defaultRepository: Repository
"""Access a repository by reference/name."""
repository(ref: String!): Repository
+
+ #TODO: connection for all repositories
}
type Mutation {
@@ -2400,7 +2392,7 @@ type Mutation {
"""Commit write the pending operations into storage. This mutation succed if nothing is pending"""
commitAsNeeded(input: CommitAsNeededInput!): CommitAsNeededPayload!
}
-`},
+`, BuiltIn: false},
&ast.Source{Name: "schema/timeline.graphql", Input: `"""An item in the timeline of events"""
interface TimelineItem {
"""The identifier of the source operation"""
@@ -2487,7 +2479,7 @@ type SetTitleTimelineItem implements TimelineItem & Authored {
title: String!
was: String!
}
-`},
+`, BuiltIn: false},
&ast.Source{Name: "schema/types.graphql", Input: `scalar Time
scalar Hash
@@ -2518,8 +2510,9 @@ interface Authored {
"""The author of this object."""
author: Identity!
}
-`},
-)
+`, BuiltIn: false},
+}
+var parsedSchema = gqlparser.MustLoadSchema(sources...)
// endregion ************************** generated!.gotpl **************************
@@ -3042,22 +3035,20 @@ func (ec *executionContext) field___Type_fields_args(ctx context.Context, rawArg
// region **************************** field.gotpl *****************************
func (ec *executionContext) _AddCommentOperation_id(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.AddCommentOperation().ID(rctx, obj)
@@ -3067,71 +3058,65 @@ func (ec *executionContext) _AddCommentOperation_id(ctx context.Context, field g
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentOperation_author(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentOperation",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Author, nil
+ return ec.resolvers.AddCommentOperation().Author(rctx, obj)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentOperation_date(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.AddCommentOperation().Date(rctx, obj)
@@ -3141,34 +3126,31 @@ func (ec *executionContext) _AddCommentOperation_date(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentOperation_message(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentOperation",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Message, nil
@@ -3178,34 +3160,31 @@ func (ec *executionContext) _AddCommentOperation_message(ctx context.Context, fi
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentOperation_files(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentOperation",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Files, nil
@@ -3215,34 +3194,31 @@ func (ec *executionContext) _AddCommentOperation_files(ctx context.Context, fiel
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]git.Hash)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHash(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHashᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentPayload_clientMutationId(ctx context.Context, field graphql.CollectedField, obj *models.AddCommentPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.ClientMutationID, nil
@@ -3255,28 +3231,25 @@ func (ec *executionContext) _AddCommentPayload_clientMutationId(ctx context.Cont
return graphql.Null
}
res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentPayload_bug(ctx context.Context, field graphql.CollectedField, obj *models.AddCommentPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Bug, nil
@@ -3286,34 +3259,31 @@ func (ec *executionContext) _AddCommentPayload_bug(ctx context.Context, field gr
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(*bug.Snapshot)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNBug2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx, field.Selections, res)
+ res := resTmp.(models.BugWrapper)
+ fc.Result = res
+ return ec.marshalNBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentPayload_operation(ctx context.Context, field graphql.CollectedField, obj *models.AddCommentPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Operation, nil
@@ -3323,34 +3293,31 @@ func (ec *executionContext) _AddCommentPayload_operation(ctx context.Context, fi
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*bug.AddCommentOperation)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNAddCommentOperation2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐAddCommentOperation(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentTimelineItem_id(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.AddCommentTimelineItem().ID(rctx, obj)
@@ -3360,71 +3327,65 @@ func (ec *executionContext) _AddCommentTimelineItem_id(ctx context.Context, fiel
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentTimelineItem_author(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentTimelineItem",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Author, nil
+ return ec.resolvers.AddCommentTimelineItem().Author(rctx, obj)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentTimelineItem_message(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentTimelineItem",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Message, nil
@@ -3434,34 +3395,31 @@ func (ec *executionContext) _AddCommentTimelineItem_message(ctx context.Context,
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentTimelineItem_messageIsEmpty(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.MessageIsEmpty(), nil
@@ -3471,34 +3429,31 @@ func (ec *executionContext) _AddCommentTimelineItem_messageIsEmpty(ctx context.C
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bool)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentTimelineItem_files(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentTimelineItem",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Files, nil
@@ -3508,34 +3463,31 @@ func (ec *executionContext) _AddCommentTimelineItem_files(ctx context.Context, f
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]git.Hash)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHash(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHashᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentTimelineItem_createdAt(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.AddCommentTimelineItem().CreatedAt(rctx, obj)
@@ -3545,34 +3497,31 @@ func (ec *executionContext) _AddCommentTimelineItem_createdAt(ctx context.Contex
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentTimelineItem_lastEdit(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.AddCommentTimelineItem().LastEdit(rctx, obj)
@@ -3582,34 +3531,31 @@ func (ec *executionContext) _AddCommentTimelineItem_lastEdit(ctx context.Context
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentTimelineItem_edited(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Edited(), nil
@@ -3619,34 +3565,31 @@ func (ec *executionContext) _AddCommentTimelineItem_edited(ctx context.Context,
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bool)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
func (ec *executionContext) _AddCommentTimelineItem_history(ctx context.Context, field graphql.CollectedField, obj *bug.AddCommentTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "AddCommentTimelineItem",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.History, nil
@@ -3656,34 +3599,31 @@ func (ec *executionContext) _AddCommentTimelineItem_history(ctx context.Context,
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]bug.CommentHistoryStep)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNCommentHistoryStep2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐCommentHistoryStep(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNCommentHistoryStep2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐCommentHistoryStepᚄ(ctx, field.Selections, res)
}
-func (ec *executionContext) _Bug_id(ctx context.Context, field graphql.CollectedField, obj *bug.Snapshot) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Bug_id(ctx context.Context, field graphql.CollectedField, obj models.BugWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Bug",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Bug().ID(rctx, obj)
@@ -3693,34 +3633,31 @@ func (ec *executionContext) _Bug_id(ctx context.Context, field graphql.Collected
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
-func (ec *executionContext) _Bug_humanId(ctx context.Context, field graphql.CollectedField, obj *bug.Snapshot) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Bug_humanId(ctx context.Context, field graphql.CollectedField, obj models.BugWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Bug",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Bug().HumanID(rctx, obj)
@@ -3730,34 +3667,31 @@ func (ec *executionContext) _Bug_humanId(ctx context.Context, field graphql.Coll
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
-func (ec *executionContext) _Bug_status(ctx context.Context, field graphql.CollectedField, obj *bug.Snapshot) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Bug_status(ctx context.Context, field graphql.CollectedField, obj models.BugWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Bug",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Bug().Status(rctx, obj)
@@ -3767,226 +3701,208 @@ func (ec *executionContext) _Bug_status(ctx context.Context, field graphql.Colle
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(models.Status)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNStatus2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐStatus(ctx, field.Selections, res)
}
-func (ec *executionContext) _Bug_title(ctx context.Context, field graphql.CollectedField, obj *bug.Snapshot) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Bug_title(ctx context.Context, field graphql.CollectedField, obj models.BugWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Bug",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Title, nil
+ return obj.Title(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
-func (ec *executionContext) _Bug_labels(ctx context.Context, field graphql.CollectedField, obj *bug.Snapshot) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Bug_labels(ctx context.Context, field graphql.CollectedField, obj models.BugWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Bug",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Labels, nil
+ return obj.Labels(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]bug.Label)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabel(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabelᚄ(ctx, field.Selections, res)
}
-func (ec *executionContext) _Bug_author(ctx context.Context, field graphql.CollectedField, obj *bug.Snapshot) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Bug_author(ctx context.Context, field graphql.CollectedField, obj models.BugWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Bug",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Author, nil
+ return obj.Author()
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
-func (ec *executionContext) _Bug_createdAt(ctx context.Context, field graphql.CollectedField, obj *bug.Snapshot) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Bug_createdAt(ctx context.Context, field graphql.CollectedField, obj models.BugWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Bug",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.CreatedAt, nil
+ return obj.CreatedAt(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2timeᚐTime(ctx, field.Selections, res)
}
-func (ec *executionContext) _Bug_lastEdit(ctx context.Context, field graphql.CollectedField, obj *bug.Snapshot) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Bug_lastEdit(ctx context.Context, field graphql.CollectedField, obj models.BugWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Bug",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return ec.resolvers.Bug().LastEdit(rctx, obj)
+ return obj.LastEdit(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
+ res := resTmp.(time.Time)
+ fc.Result = res
+ return ec.marshalNTime2timeᚐTime(ctx, field.Selections, res)
}
-func (ec *executionContext) _Bug_actors(ctx context.Context, field graphql.CollectedField, obj *bug.Snapshot) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Bug_actors(ctx context.Context, field graphql.CollectedField, obj models.BugWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Bug",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Bug_actors_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Bug().Actors(rctx, obj, args["after"].(*string), args["before"].(*string), args["first"].(*int), args["last"].(*int))
@@ -3996,41 +3912,38 @@ func (ec *executionContext) _Bug_actors(ctx context.Context, field graphql.Colle
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.IdentityConnection)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNIdentityConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityConnection(ctx, field.Selections, res)
}
-func (ec *executionContext) _Bug_participants(ctx context.Context, field graphql.CollectedField, obj *bug.Snapshot) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Bug_participants(ctx context.Context, field graphql.CollectedField, obj models.BugWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Bug",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Bug_participants_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Bug().Participants(rctx, obj, args["after"].(*string), args["before"].(*string), args["first"].(*int), args["last"].(*int))
@@ -4040,41 +3953,38 @@ func (ec *executionContext) _Bug_participants(ctx context.Context, field graphql
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.IdentityConnection)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNIdentityConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityConnection(ctx, field.Selections, res)
}
-func (ec *executionContext) _Bug_comments(ctx context.Context, field graphql.CollectedField, obj *bug.Snapshot) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Bug_comments(ctx context.Context, field graphql.CollectedField, obj models.BugWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Bug",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Bug_comments_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Bug().Comments(rctx, obj, args["after"].(*string), args["before"].(*string), args["first"].(*int), args["last"].(*int))
@@ -4084,41 +3994,38 @@ func (ec *executionContext) _Bug_comments(ctx context.Context, field graphql.Col
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.CommentConnection)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNCommentConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐCommentConnection(ctx, field.Selections, res)
}
-func (ec *executionContext) _Bug_timeline(ctx context.Context, field graphql.CollectedField, obj *bug.Snapshot) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Bug_timeline(ctx context.Context, field graphql.CollectedField, obj models.BugWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Bug",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Bug_timeline_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Bug().Timeline(rctx, obj, args["after"].(*string), args["before"].(*string), args["first"].(*int), args["last"].(*int))
@@ -4128,41 +4035,38 @@ func (ec *executionContext) _Bug_timeline(ctx context.Context, field graphql.Col
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.TimelineItemConnection)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTimelineItemConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐTimelineItemConnection(ctx, field.Selections, res)
}
-func (ec *executionContext) _Bug_operations(ctx context.Context, field graphql.CollectedField, obj *bug.Snapshot) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Bug_operations(ctx context.Context, field graphql.CollectedField, obj models.BugWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Bug",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Bug_operations_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Bug().Operations(rctx, obj, args["after"].(*string), args["before"].(*string), args["first"].(*int), args["last"].(*int))
@@ -4172,34 +4076,31 @@ func (ec *executionContext) _Bug_operations(ctx context.Context, field graphql.C
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.OperationConnection)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNOperationConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐOperationConnection(ctx, field.Selections, res)
}
func (ec *executionContext) _BugConnection_edges(ctx context.Context, field graphql.CollectedField, obj *models.BugConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "BugConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Edges, nil
@@ -4209,34 +4110,31 @@ func (ec *executionContext) _BugConnection_edges(ctx context.Context, field grap
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]*models.BugEdge)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNBugEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugEdge(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNBugEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugEdgeᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _BugConnection_nodes(ctx context.Context, field graphql.CollectedField, obj *models.BugConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "BugConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Nodes, nil
@@ -4246,34 +4144,31 @@ func (ec *executionContext) _BugConnection_nodes(ctx context.Context, field grap
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.([]*bug.Snapshot)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNBug2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx, field.Selections, res)
+ res := resTmp.([]models.BugWrapper)
+ fc.Result = res
+ return ec.marshalNBug2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapperᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _BugConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *models.BugConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "BugConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.PageInfo, nil
@@ -4283,34 +4178,31 @@ func (ec *executionContext) _BugConnection_pageInfo(ctx context.Context, field g
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.PageInfo)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNPageInfo2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐPageInfo(ctx, field.Selections, res)
}
func (ec *executionContext) _BugConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *models.BugConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "BugConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.TotalCount, nil
@@ -4320,34 +4212,31 @@ func (ec *executionContext) _BugConnection_totalCount(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(int)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNInt2int(ctx, field.Selections, res)
}
func (ec *executionContext) _BugEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *models.BugEdge) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "BugEdge",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Cursor, nil
@@ -4357,34 +4246,31 @@ func (ec *executionContext) _BugEdge_cursor(ctx context.Context, field graphql.C
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _BugEdge_node(ctx context.Context, field graphql.CollectedField, obj *models.BugEdge) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "BugEdge",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Node, nil
@@ -4394,34 +4280,31 @@ func (ec *executionContext) _BugEdge_node(ctx context.Context, field graphql.Col
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(*bug.Snapshot)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNBug2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx, field.Selections, res)
+ res := resTmp.(models.BugWrapper)
+ fc.Result = res
+ return ec.marshalNBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _ChangeLabelPayload_clientMutationId(ctx context.Context, field graphql.CollectedField, obj *models.ChangeLabelPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "ChangeLabelPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.ClientMutationID, nil
@@ -4434,28 +4317,25 @@ func (ec *executionContext) _ChangeLabelPayload_clientMutationId(ctx context.Con
return graphql.Null
}
res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) _ChangeLabelPayload_bug(ctx context.Context, field graphql.CollectedField, obj *models.ChangeLabelPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "ChangeLabelPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Bug, nil
@@ -4465,34 +4345,31 @@ func (ec *executionContext) _ChangeLabelPayload_bug(ctx context.Context, field g
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(*bug.Snapshot)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNBug2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx, field.Selections, res)
+ res := resTmp.(models.BugWrapper)
+ fc.Result = res
+ return ec.marshalNBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _ChangeLabelPayload_operation(ctx context.Context, field graphql.CollectedField, obj *models.ChangeLabelPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "ChangeLabelPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Operation, nil
@@ -4502,34 +4379,31 @@ func (ec *executionContext) _ChangeLabelPayload_operation(ctx context.Context, f
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*bug.LabelChangeOperation)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNLabelChangeOperation2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabelChangeOperation(ctx, field.Selections, res)
}
func (ec *executionContext) _ChangeLabelPayload_results(ctx context.Context, field graphql.CollectedField, obj *models.ChangeLabelPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "ChangeLabelPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Results, nil
@@ -4539,34 +4413,31 @@ func (ec *executionContext) _ChangeLabelPayload_results(ctx context.Context, fie
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]*bug.LabelChangeResult)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNLabelChangeResult2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabelChangeResult(ctx, field.Selections, res)
}
func (ec *executionContext) _CloseBugPayload_clientMutationId(ctx context.Context, field graphql.CollectedField, obj *models.CloseBugPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CloseBugPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.ClientMutationID, nil
@@ -4579,28 +4450,25 @@ func (ec *executionContext) _CloseBugPayload_clientMutationId(ctx context.Contex
return graphql.Null
}
res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) _CloseBugPayload_bug(ctx context.Context, field graphql.CollectedField, obj *models.CloseBugPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CloseBugPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Bug, nil
@@ -4610,34 +4478,31 @@ func (ec *executionContext) _CloseBugPayload_bug(ctx context.Context, field grap
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(*bug.Snapshot)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNBug2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx, field.Selections, res)
+ res := resTmp.(models.BugWrapper)
+ fc.Result = res
+ return ec.marshalNBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _CloseBugPayload_operation(ctx context.Context, field graphql.CollectedField, obj *models.CloseBugPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CloseBugPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Operation, nil
@@ -4647,34 +4512,31 @@ func (ec *executionContext) _CloseBugPayload_operation(ctx context.Context, fiel
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*bug.SetStatusOperation)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNSetStatusOperation2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSetStatusOperation(ctx, field.Selections, res)
}
func (ec *executionContext) _Color_R(ctx context.Context, field graphql.CollectedField, obj *color.RGBA) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Color",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Color().R(rctx, obj)
@@ -4684,34 +4546,31 @@ func (ec *executionContext) _Color_R(ctx context.Context, field graphql.Collecte
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(int)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNInt2int(ctx, field.Selections, res)
}
func (ec *executionContext) _Color_G(ctx context.Context, field graphql.CollectedField, obj *color.RGBA) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Color",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Color().G(rctx, obj)
@@ -4721,34 +4580,31 @@ func (ec *executionContext) _Color_G(ctx context.Context, field graphql.Collecte
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(int)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNInt2int(ctx, field.Selections, res)
}
func (ec *executionContext) _Color_B(ctx context.Context, field graphql.CollectedField, obj *color.RGBA) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Color",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Color().B(rctx, obj)
@@ -4758,71 +4614,65 @@ func (ec *executionContext) _Color_B(ctx context.Context, field graphql.Collecte
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(int)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNInt2int(ctx, field.Selections, res)
}
func (ec *executionContext) _Comment_author(ctx context.Context, field graphql.CollectedField, obj *bug.Comment) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Comment",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Author, nil
+ return ec.resolvers.Comment().Author(rctx, obj)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _Comment_message(ctx context.Context, field graphql.CollectedField, obj *bug.Comment) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Comment",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Message, nil
@@ -4832,34 +4682,31 @@ func (ec *executionContext) _Comment_message(ctx context.Context, field graphql.
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _Comment_files(ctx context.Context, field graphql.CollectedField, obj *bug.Comment) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Comment",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Files, nil
@@ -4869,34 +4716,31 @@ func (ec *executionContext) _Comment_files(ctx context.Context, field graphql.Co
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]git.Hash)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHash(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHashᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _CommentConnection_edges(ctx context.Context, field graphql.CollectedField, obj *models.CommentConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CommentConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Edges, nil
@@ -4906,34 +4750,31 @@ func (ec *executionContext) _CommentConnection_edges(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]*models.CommentEdge)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNCommentEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐCommentEdge(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNCommentEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐCommentEdgeᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _CommentConnection_nodes(ctx context.Context, field graphql.CollectedField, obj *models.CommentConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CommentConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Nodes, nil
@@ -4943,34 +4784,31 @@ func (ec *executionContext) _CommentConnection_nodes(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]*bug.Comment)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNComment2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐComment(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNComment2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐCommentᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _CommentConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *models.CommentConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CommentConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.PageInfo, nil
@@ -4980,34 +4818,31 @@ func (ec *executionContext) _CommentConnection_pageInfo(ctx context.Context, fie
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.PageInfo)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNPageInfo2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐPageInfo(ctx, field.Selections, res)
}
func (ec *executionContext) _CommentConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *models.CommentConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CommentConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.TotalCount, nil
@@ -5017,34 +4852,31 @@ func (ec *executionContext) _CommentConnection_totalCount(ctx context.Context, f
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(int)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNInt2int(ctx, field.Selections, res)
}
func (ec *executionContext) _CommentEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *models.CommentEdge) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CommentEdge",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Cursor, nil
@@ -5054,34 +4886,31 @@ func (ec *executionContext) _CommentEdge_cursor(ctx context.Context, field graph
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _CommentEdge_node(ctx context.Context, field graphql.CollectedField, obj *models.CommentEdge) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CommentEdge",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Node, nil
@@ -5091,34 +4920,31 @@ func (ec *executionContext) _CommentEdge_node(ctx context.Context, field graphql
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*bug.Comment)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNComment2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐComment(ctx, field.Selections, res)
}
func (ec *executionContext) _CommentHistoryStep_message(ctx context.Context, field graphql.CollectedField, obj *bug.CommentHistoryStep) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CommentHistoryStep",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Message, nil
@@ -5128,34 +4954,31 @@ func (ec *executionContext) _CommentHistoryStep_message(ctx context.Context, fie
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _CommentHistoryStep_date(ctx context.Context, field graphql.CollectedField, obj *bug.CommentHistoryStep) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CommentHistoryStep",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.CommentHistoryStep().Date(rctx, obj)
@@ -5165,34 +4988,31 @@ func (ec *executionContext) _CommentHistoryStep_date(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _CommitAsNeededPayload_clientMutationId(ctx context.Context, field graphql.CollectedField, obj *models.CommitAsNeededPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CommitAsNeededPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.ClientMutationID, nil
@@ -5205,28 +5025,25 @@ func (ec *executionContext) _CommitAsNeededPayload_clientMutationId(ctx context.
return graphql.Null
}
res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) _CommitAsNeededPayload_bug(ctx context.Context, field graphql.CollectedField, obj *models.CommitAsNeededPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CommitAsNeededPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Bug, nil
@@ -5236,34 +5053,31 @@ func (ec *executionContext) _CommitAsNeededPayload_bug(ctx context.Context, fiel
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(*bug.Snapshot)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNBug2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx, field.Selections, res)
+ res := resTmp.(models.BugWrapper)
+ fc.Result = res
+ return ec.marshalNBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _CommitPayload_clientMutationId(ctx context.Context, field graphql.CollectedField, obj *models.CommitPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CommitPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.ClientMutationID, nil
@@ -5276,28 +5090,25 @@ func (ec *executionContext) _CommitPayload_clientMutationId(ctx context.Context,
return graphql.Null
}
res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) _CommitPayload_bug(ctx context.Context, field graphql.CollectedField, obj *models.CommitPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CommitPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Bug, nil
@@ -5307,34 +5118,31 @@ func (ec *executionContext) _CommitPayload_bug(ctx context.Context, field graphq
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(*bug.Snapshot)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNBug2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx, field.Selections, res)
+ res := resTmp.(models.BugWrapper)
+ fc.Result = res
+ return ec.marshalNBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateOperation_id(ctx context.Context, field graphql.CollectedField, obj *bug.CreateOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.CreateOperation().ID(rctx, obj)
@@ -5344,71 +5152,65 @@ func (ec *executionContext) _CreateOperation_id(ctx context.Context, field graph
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateOperation_author(ctx context.Context, field graphql.CollectedField, obj *bug.CreateOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateOperation",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Author, nil
+ return ec.resolvers.CreateOperation().Author(rctx, obj)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateOperation_date(ctx context.Context, field graphql.CollectedField, obj *bug.CreateOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.CreateOperation().Date(rctx, obj)
@@ -5418,34 +5220,31 @@ func (ec *executionContext) _CreateOperation_date(ctx context.Context, field gra
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateOperation_title(ctx context.Context, field graphql.CollectedField, obj *bug.CreateOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateOperation",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Title, nil
@@ -5455,34 +5254,31 @@ func (ec *executionContext) _CreateOperation_title(ctx context.Context, field gr
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateOperation_message(ctx context.Context, field graphql.CollectedField, obj *bug.CreateOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateOperation",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Message, nil
@@ -5492,34 +5288,31 @@ func (ec *executionContext) _CreateOperation_message(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateOperation_files(ctx context.Context, field graphql.CollectedField, obj *bug.CreateOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateOperation",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Files, nil
@@ -5529,34 +5322,31 @@ func (ec *executionContext) _CreateOperation_files(ctx context.Context, field gr
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]git.Hash)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHash(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHashᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateTimelineItem_id(ctx context.Context, field graphql.CollectedField, obj *bug.CreateTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.CreateTimelineItem().ID(rctx, obj)
@@ -5566,71 +5356,65 @@ func (ec *executionContext) _CreateTimelineItem_id(ctx context.Context, field gr
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateTimelineItem_author(ctx context.Context, field graphql.CollectedField, obj *bug.CreateTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateTimelineItem",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Author, nil
+ return ec.resolvers.CreateTimelineItem().Author(rctx, obj)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateTimelineItem_message(ctx context.Context, field graphql.CollectedField, obj *bug.CreateTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateTimelineItem",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Message, nil
@@ -5640,34 +5424,31 @@ func (ec *executionContext) _CreateTimelineItem_message(ctx context.Context, fie
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateTimelineItem_messageIsEmpty(ctx context.Context, field graphql.CollectedField, obj *bug.CreateTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.MessageIsEmpty(), nil
@@ -5677,34 +5458,31 @@ func (ec *executionContext) _CreateTimelineItem_messageIsEmpty(ctx context.Conte
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bool)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateTimelineItem_files(ctx context.Context, field graphql.CollectedField, obj *bug.CreateTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateTimelineItem",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Files, nil
@@ -5714,34 +5492,31 @@ func (ec *executionContext) _CreateTimelineItem_files(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]git.Hash)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHash(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHashᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateTimelineItem_createdAt(ctx context.Context, field graphql.CollectedField, obj *bug.CreateTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.CreateTimelineItem().CreatedAt(rctx, obj)
@@ -5751,34 +5526,31 @@ func (ec *executionContext) _CreateTimelineItem_createdAt(ctx context.Context, f
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateTimelineItem_lastEdit(ctx context.Context, field graphql.CollectedField, obj *bug.CreateTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.CreateTimelineItem().LastEdit(rctx, obj)
@@ -5788,34 +5560,31 @@ func (ec *executionContext) _CreateTimelineItem_lastEdit(ctx context.Context, fi
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateTimelineItem_edited(ctx context.Context, field graphql.CollectedField, obj *bug.CreateTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Edited(), nil
@@ -5825,34 +5594,31 @@ func (ec *executionContext) _CreateTimelineItem_edited(ctx context.Context, fiel
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bool)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
func (ec *executionContext) _CreateTimelineItem_history(ctx context.Context, field graphql.CollectedField, obj *bug.CreateTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "CreateTimelineItem",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.History, nil
@@ -5862,34 +5628,31 @@ func (ec *executionContext) _CreateTimelineItem_history(ctx context.Context, fie
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]bug.CommentHistoryStep)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNCommentHistoryStep2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐCommentHistoryStep(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNCommentHistoryStep2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐCommentHistoryStepᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _EditCommentOperation_id(ctx context.Context, field graphql.CollectedField, obj *bug.EditCommentOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "EditCommentOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.EditCommentOperation().ID(rctx, obj)
@@ -5899,71 +5662,65 @@ func (ec *executionContext) _EditCommentOperation_id(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _EditCommentOperation_author(ctx context.Context, field graphql.CollectedField, obj *bug.EditCommentOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "EditCommentOperation",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Author, nil
+ return ec.resolvers.EditCommentOperation().Author(rctx, obj)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _EditCommentOperation_date(ctx context.Context, field graphql.CollectedField, obj *bug.EditCommentOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "EditCommentOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.EditCommentOperation().Date(rctx, obj)
@@ -5973,34 +5730,31 @@ func (ec *executionContext) _EditCommentOperation_date(ctx context.Context, fiel
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _EditCommentOperation_target(ctx context.Context, field graphql.CollectedField, obj *bug.EditCommentOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "EditCommentOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.EditCommentOperation().Target(rctx, obj)
@@ -6010,34 +5764,31 @@ func (ec *executionContext) _EditCommentOperation_target(ctx context.Context, fi
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _EditCommentOperation_message(ctx context.Context, field graphql.CollectedField, obj *bug.EditCommentOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "EditCommentOperation",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Message, nil
@@ -6047,34 +5798,31 @@ func (ec *executionContext) _EditCommentOperation_message(ctx context.Context, f
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _EditCommentOperation_files(ctx context.Context, field graphql.CollectedField, obj *bug.EditCommentOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "EditCommentOperation",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Files, nil
@@ -6084,34 +5832,31 @@ func (ec *executionContext) _EditCommentOperation_files(ctx context.Context, fie
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]git.Hash)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHash(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHashᚄ(ctx, field.Selections, res)
}
-func (ec *executionContext) _Identity_id(ctx context.Context, field graphql.CollectedField, obj *identity.Interface) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Identity_id(ctx context.Context, field graphql.CollectedField, obj models.IdentityWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Identity",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Identity().ID(rctx, obj)
@@ -6121,34 +5866,31 @@ func (ec *executionContext) _Identity_id(ctx context.Context, field graphql.Coll
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
-func (ec *executionContext) _Identity_humanId(ctx context.Context, field graphql.CollectedField, obj *identity.Interface) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Identity_humanId(ctx context.Context, field graphql.CollectedField, obj models.IdentityWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Identity",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Identity().HumanID(rctx, obj)
@@ -6158,71 +5900,34 @@ func (ec *executionContext) _Identity_humanId(ctx context.Context, field graphql
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
-func (ec *executionContext) _Identity_name(ctx context.Context, field graphql.CollectedField, obj *identity.Interface) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Identity_name(ctx context.Context, field graphql.CollectedField, obj models.IdentityWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Identity",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
- resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
- ctx = rctx // use context from middleware stack in children
- return ec.resolvers.Identity().Name(rctx, obj)
- })
- if err != nil {
- ec.Error(ctx, err)
- return graphql.Null
- }
- if resTmp == nil {
- return graphql.Null
- }
- res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
-}
-func (ec *executionContext) _Identity_email(ctx context.Context, field graphql.CollectedField, obj *identity.Interface) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
- defer func() {
- if r := recover(); r != nil {
- ec.Error(ctx, ec.Recover(ctx, r))
- ret = graphql.Null
- }
- ec.Tracer.EndFieldExecution(ctx)
- }()
- rctx := &graphql.ResolverContext{
- Object: "Identity",
- Field: field,
- Args: nil,
- IsMethod: true,
- }
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return ec.resolvers.Identity().Email(rctx, obj)
+ return obj.Name(), nil
})
if err != nil {
ec.Error(ctx, err)
@@ -6231,32 +5936,29 @@ func (ec *executionContext) _Identity_email(ctx context.Context, field graphql.C
if resTmp == nil {
return graphql.Null
}
- res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
+ res := resTmp.(string)
+ fc.Result = res
+ return ec.marshalOString2string(ctx, field.Selections, res)
}
-func (ec *executionContext) _Identity_login(ctx context.Context, field graphql.CollectedField, obj *identity.Interface) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Identity_email(ctx context.Context, field graphql.CollectedField, obj models.IdentityWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Identity",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return ec.resolvers.Identity().Login(rctx, obj)
+ return obj.Email()
})
if err != nil {
ec.Error(ctx, err)
@@ -6265,69 +5967,63 @@ func (ec *executionContext) _Identity_login(ctx context.Context, field graphql.C
if resTmp == nil {
return graphql.Null
}
- res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
+ res := resTmp.(string)
+ fc.Result = res
+ return ec.marshalOString2string(ctx, field.Selections, res)
}
-func (ec *executionContext) _Identity_displayName(ctx context.Context, field graphql.CollectedField, obj *identity.Interface) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Identity_displayName(ctx context.Context, field graphql.CollectedField, obj models.IdentityWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Identity",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return ec.resolvers.Identity().DisplayName(rctx, obj)
+ return obj.DisplayName(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
-func (ec *executionContext) _Identity_avatarUrl(ctx context.Context, field graphql.CollectedField, obj *identity.Interface) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Identity_avatarUrl(ctx context.Context, field graphql.CollectedField, obj models.IdentityWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Identity",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return ec.resolvers.Identity().AvatarURL(rctx, obj)
+ return obj.AvatarUrl()
})
if err != nil {
ec.Error(ctx, err)
@@ -6336,66 +6032,60 @@ func (ec *executionContext) _Identity_avatarUrl(ctx context.Context, field graph
if resTmp == nil {
return graphql.Null
}
- res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
+ res := resTmp.(string)
+ fc.Result = res
+ return ec.marshalOString2string(ctx, field.Selections, res)
}
-func (ec *executionContext) _Identity_isProtected(ctx context.Context, field graphql.CollectedField, obj *identity.Interface) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
+func (ec *executionContext) _Identity_isProtected(ctx context.Context, field graphql.CollectedField, obj models.IdentityWrapper) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Identity",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return ec.resolvers.Identity().IsProtected(rctx, obj)
+ return obj.IsProtected()
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bool)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
func (ec *executionContext) _IdentityConnection_edges(ctx context.Context, field graphql.CollectedField, obj *models.IdentityConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "IdentityConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Edges, nil
@@ -6405,34 +6095,31 @@ func (ec *executionContext) _IdentityConnection_edges(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]*models.IdentityEdge)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentityEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityEdge(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNIdentityEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityEdgeᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _IdentityConnection_nodes(ctx context.Context, field graphql.CollectedField, obj *models.IdentityConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "IdentityConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Nodes, nil
@@ -6442,34 +6129,31 @@ func (ec *executionContext) _IdentityConnection_nodes(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.([]identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.([]models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapperᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _IdentityConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *models.IdentityConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "IdentityConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.PageInfo, nil
@@ -6479,34 +6163,31 @@ func (ec *executionContext) _IdentityConnection_pageInfo(ctx context.Context, fi
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.PageInfo)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNPageInfo2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐPageInfo(ctx, field.Selections, res)
}
func (ec *executionContext) _IdentityConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *models.IdentityConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "IdentityConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.TotalCount, nil
@@ -6516,34 +6197,31 @@ func (ec *executionContext) _IdentityConnection_totalCount(ctx context.Context,
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(int)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNInt2int(ctx, field.Selections, res)
}
func (ec *executionContext) _IdentityEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *models.IdentityEdge) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "IdentityEdge",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Cursor, nil
@@ -6553,34 +6231,31 @@ func (ec *executionContext) _IdentityEdge_cursor(ctx context.Context, field grap
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _IdentityEdge_node(ctx context.Context, field graphql.CollectedField, obj *models.IdentityEdge) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "IdentityEdge",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Node, nil
@@ -6590,34 +6265,31 @@ func (ec *executionContext) _IdentityEdge_node(ctx context.Context, field graphq
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _Label_name(ctx context.Context, field graphql.CollectedField, obj *bug.Label) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Label",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Label().Name(rctx, obj)
@@ -6627,34 +6299,31 @@ func (ec *executionContext) _Label_name(ctx context.Context, field graphql.Colle
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _Label_color(ctx context.Context, field graphql.CollectedField, obj *bug.Label) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Label",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Label().Color(rctx, obj)
@@ -6664,34 +6333,31 @@ func (ec *executionContext) _Label_color(ctx context.Context, field graphql.Coll
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*color.RGBA)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNColor2ᚖimageᚋcolorᚐRGBA(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelChangeOperation_id(ctx context.Context, field graphql.CollectedField, obj *bug.LabelChangeOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelChangeOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.LabelChangeOperation().ID(rctx, obj)
@@ -6701,71 +6367,65 @@ func (ec *executionContext) _LabelChangeOperation_id(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelChangeOperation_author(ctx context.Context, field graphql.CollectedField, obj *bug.LabelChangeOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelChangeOperation",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Author, nil
+ return ec.resolvers.LabelChangeOperation().Author(rctx, obj)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelChangeOperation_date(ctx context.Context, field graphql.CollectedField, obj *bug.LabelChangeOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelChangeOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.LabelChangeOperation().Date(rctx, obj)
@@ -6775,34 +6435,31 @@ func (ec *executionContext) _LabelChangeOperation_date(ctx context.Context, fiel
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelChangeOperation_added(ctx context.Context, field graphql.CollectedField, obj *bug.LabelChangeOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelChangeOperation",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Added, nil
@@ -6812,34 +6469,31 @@ func (ec *executionContext) _LabelChangeOperation_added(ctx context.Context, fie
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]bug.Label)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabel(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabelᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelChangeOperation_removed(ctx context.Context, field graphql.CollectedField, obj *bug.LabelChangeOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelChangeOperation",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Removed, nil
@@ -6849,34 +6503,31 @@ func (ec *executionContext) _LabelChangeOperation_removed(ctx context.Context, f
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]bug.Label)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabel(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabelᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelChangeResult_label(ctx context.Context, field graphql.CollectedField, obj *bug.LabelChangeResult) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelChangeResult",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Label, nil
@@ -6886,34 +6537,31 @@ func (ec *executionContext) _LabelChangeResult_label(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bug.Label)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNLabel2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabel(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelChangeResult_status(ctx context.Context, field graphql.CollectedField, obj *bug.LabelChangeResult) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelChangeResult",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.LabelChangeResult().Status(rctx, obj)
@@ -6923,34 +6571,31 @@ func (ec *executionContext) _LabelChangeResult_status(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(models.LabelChangeStatus)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNLabelChangeStatus2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐLabelChangeStatus(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelChangeTimelineItem_id(ctx context.Context, field graphql.CollectedField, obj *bug.LabelChangeTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelChangeTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.LabelChangeTimelineItem().ID(rctx, obj)
@@ -6960,71 +6605,65 @@ func (ec *executionContext) _LabelChangeTimelineItem_id(ctx context.Context, fie
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelChangeTimelineItem_author(ctx context.Context, field graphql.CollectedField, obj *bug.LabelChangeTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelChangeTimelineItem",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Author, nil
+ return ec.resolvers.LabelChangeTimelineItem().Author(rctx, obj)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelChangeTimelineItem_date(ctx context.Context, field graphql.CollectedField, obj *bug.LabelChangeTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelChangeTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.LabelChangeTimelineItem().Date(rctx, obj)
@@ -7034,34 +6673,31 @@ func (ec *executionContext) _LabelChangeTimelineItem_date(ctx context.Context, f
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelChangeTimelineItem_added(ctx context.Context, field graphql.CollectedField, obj *bug.LabelChangeTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelChangeTimelineItem",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Added, nil
@@ -7071,34 +6707,31 @@ func (ec *executionContext) _LabelChangeTimelineItem_added(ctx context.Context,
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]bug.Label)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabel(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabelᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelChangeTimelineItem_removed(ctx context.Context, field graphql.CollectedField, obj *bug.LabelChangeTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelChangeTimelineItem",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Removed, nil
@@ -7108,34 +6741,31 @@ func (ec *executionContext) _LabelChangeTimelineItem_removed(ctx context.Context
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]bug.Label)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabel(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabelᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelConnection_edges(ctx context.Context, field graphql.CollectedField, obj *models.LabelConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Edges, nil
@@ -7145,34 +6775,31 @@ func (ec *executionContext) _LabelConnection_edges(ctx context.Context, field gr
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]*models.LabelEdge)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNLabelEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐLabelEdge(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNLabelEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐLabelEdgeᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelConnection_nodes(ctx context.Context, field graphql.CollectedField, obj *models.LabelConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Nodes, nil
@@ -7182,34 +6809,31 @@ func (ec *executionContext) _LabelConnection_nodes(ctx context.Context, field gr
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]bug.Label)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabel(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabelᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *models.LabelConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.PageInfo, nil
@@ -7219,34 +6843,31 @@ func (ec *executionContext) _LabelConnection_pageInfo(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.PageInfo)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNPageInfo2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐPageInfo(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *models.LabelConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.TotalCount, nil
@@ -7256,34 +6877,31 @@ func (ec *executionContext) _LabelConnection_totalCount(ctx context.Context, fie
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(int)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNInt2int(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *models.LabelEdge) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelEdge",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Cursor, nil
@@ -7293,34 +6911,31 @@ func (ec *executionContext) _LabelEdge_cursor(ctx context.Context, field graphql
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _LabelEdge_node(ctx context.Context, field graphql.CollectedField, obj *models.LabelEdge) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "LabelEdge",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Node, nil
@@ -7330,41 +6945,38 @@ func (ec *executionContext) _LabelEdge_node(ctx context.Context, field graphql.C
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bug.Label)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNLabel2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabel(ctx, field.Selections, res)
}
func (ec *executionContext) _Mutation_newBug(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Mutation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_newBug_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Mutation().NewBug(rctx, args["input"].(models.NewBugInput))
@@ -7374,41 +6986,38 @@ func (ec *executionContext) _Mutation_newBug(ctx context.Context, field graphql.
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.NewBugPayload)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNNewBugPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐNewBugPayload(ctx, field.Selections, res)
}
func (ec *executionContext) _Mutation_addComment(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Mutation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_addComment_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Mutation().AddComment(rctx, args["input"].(models.AddCommentInput))
@@ -7418,41 +7027,38 @@ func (ec *executionContext) _Mutation_addComment(ctx context.Context, field grap
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.AddCommentPayload)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNAddCommentPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐAddCommentPayload(ctx, field.Selections, res)
}
func (ec *executionContext) _Mutation_changeLabels(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Mutation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_changeLabels_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Mutation().ChangeLabels(rctx, args["input"].(*models.ChangeLabelInput))
@@ -7462,41 +7068,38 @@ func (ec *executionContext) _Mutation_changeLabels(ctx context.Context, field gr
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.ChangeLabelPayload)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNChangeLabelPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐChangeLabelPayload(ctx, field.Selections, res)
}
func (ec *executionContext) _Mutation_openBug(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Mutation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_openBug_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Mutation().OpenBug(rctx, args["input"].(models.OpenBugInput))
@@ -7506,41 +7109,38 @@ func (ec *executionContext) _Mutation_openBug(ctx context.Context, field graphql
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.OpenBugPayload)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNOpenBugPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐOpenBugPayload(ctx, field.Selections, res)
}
func (ec *executionContext) _Mutation_closeBug(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Mutation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_closeBug_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Mutation().CloseBug(rctx, args["input"].(models.CloseBugInput))
@@ -7550,41 +7150,38 @@ func (ec *executionContext) _Mutation_closeBug(ctx context.Context, field graphq
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.CloseBugPayload)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNCloseBugPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐCloseBugPayload(ctx, field.Selections, res)
}
func (ec *executionContext) _Mutation_setTitle(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Mutation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_setTitle_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Mutation().SetTitle(rctx, args["input"].(models.SetTitleInput))
@@ -7594,41 +7191,38 @@ func (ec *executionContext) _Mutation_setTitle(ctx context.Context, field graphq
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.SetTitlePayload)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNSetTitlePayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐSetTitlePayload(ctx, field.Selections, res)
}
func (ec *executionContext) _Mutation_commit(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Mutation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_commit_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Mutation().Commit(rctx, args["input"].(models.CommitInput))
@@ -7638,41 +7232,38 @@ func (ec *executionContext) _Mutation_commit(ctx context.Context, field graphql.
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.CommitPayload)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNCommitPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐCommitPayload(ctx, field.Selections, res)
}
func (ec *executionContext) _Mutation_commitAsNeeded(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Mutation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_commitAsNeeded_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Mutation().CommitAsNeeded(rctx, args["input"].(models.CommitAsNeededInput))
@@ -7682,34 +7273,31 @@ func (ec *executionContext) _Mutation_commitAsNeeded(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.CommitAsNeededPayload)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNCommitAsNeededPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐCommitAsNeededPayload(ctx, field.Selections, res)
}
func (ec *executionContext) _NewBugPayload_clientMutationId(ctx context.Context, field graphql.CollectedField, obj *models.NewBugPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "NewBugPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.ClientMutationID, nil
@@ -7722,28 +7310,25 @@ func (ec *executionContext) _NewBugPayload_clientMutationId(ctx context.Context,
return graphql.Null
}
res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) _NewBugPayload_bug(ctx context.Context, field graphql.CollectedField, obj *models.NewBugPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "NewBugPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Bug, nil
@@ -7753,34 +7338,31 @@ func (ec *executionContext) _NewBugPayload_bug(ctx context.Context, field graphq
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(*bug.Snapshot)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNBug2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx, field.Selections, res)
+ res := resTmp.(models.BugWrapper)
+ fc.Result = res
+ return ec.marshalNBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _NewBugPayload_operation(ctx context.Context, field graphql.CollectedField, obj *models.NewBugPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "NewBugPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Operation, nil
@@ -7790,34 +7372,31 @@ func (ec *executionContext) _NewBugPayload_operation(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*bug.CreateOperation)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNCreateOperation2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐCreateOperation(ctx, field.Selections, res)
}
func (ec *executionContext) _OpenBugPayload_clientMutationId(ctx context.Context, field graphql.CollectedField, obj *models.OpenBugPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "OpenBugPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.ClientMutationID, nil
@@ -7830,28 +7409,25 @@ func (ec *executionContext) _OpenBugPayload_clientMutationId(ctx context.Context
return graphql.Null
}
res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) _OpenBugPayload_bug(ctx context.Context, field graphql.CollectedField, obj *models.OpenBugPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "OpenBugPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Bug, nil
@@ -7861,34 +7437,31 @@ func (ec *executionContext) _OpenBugPayload_bug(ctx context.Context, field graph
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(*bug.Snapshot)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNBug2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx, field.Selections, res)
+ res := resTmp.(models.BugWrapper)
+ fc.Result = res
+ return ec.marshalNBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _OpenBugPayload_operation(ctx context.Context, field graphql.CollectedField, obj *models.OpenBugPayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "OpenBugPayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Operation, nil
@@ -7898,34 +7471,31 @@ func (ec *executionContext) _OpenBugPayload_operation(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*bug.SetStatusOperation)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNSetStatusOperation2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSetStatusOperation(ctx, field.Selections, res)
}
func (ec *executionContext) _OperationConnection_edges(ctx context.Context, field graphql.CollectedField, obj *models.OperationConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "OperationConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Edges, nil
@@ -7935,34 +7505,31 @@ func (ec *executionContext) _OperationConnection_edges(ctx context.Context, fiel
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]*models.OperationEdge)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNOperationEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐOperationEdge(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNOperationEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐOperationEdgeᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _OperationConnection_nodes(ctx context.Context, field graphql.CollectedField, obj *models.OperationConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "OperationConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Nodes, nil
@@ -7972,34 +7539,31 @@ func (ec *executionContext) _OperationConnection_nodes(ctx context.Context, fiel
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]bug.Operation)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNOperation2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐOperation(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNOperation2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐOperationᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _OperationConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *models.OperationConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "OperationConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.PageInfo, nil
@@ -8009,34 +7573,31 @@ func (ec *executionContext) _OperationConnection_pageInfo(ctx context.Context, f
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.PageInfo)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNPageInfo2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐPageInfo(ctx, field.Selections, res)
}
func (ec *executionContext) _OperationConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *models.OperationConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "OperationConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.TotalCount, nil
@@ -8046,34 +7607,31 @@ func (ec *executionContext) _OperationConnection_totalCount(ctx context.Context,
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(int)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNInt2int(ctx, field.Selections, res)
}
func (ec *executionContext) _OperationEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *models.OperationEdge) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "OperationEdge",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Cursor, nil
@@ -8083,34 +7641,31 @@ func (ec *executionContext) _OperationEdge_cursor(ctx context.Context, field gra
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _OperationEdge_node(ctx context.Context, field graphql.CollectedField, obj *models.OperationEdge) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "OperationEdge",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Node, nil
@@ -8120,34 +7675,31 @@ func (ec *executionContext) _OperationEdge_node(ctx context.Context, field graph
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bug.Operation)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNOperation2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐOperation(ctx, field.Selections, res)
}
func (ec *executionContext) _PageInfo_hasNextPage(ctx context.Context, field graphql.CollectedField, obj *models.PageInfo) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "PageInfo",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.HasNextPage, nil
@@ -8157,34 +7709,31 @@ func (ec *executionContext) _PageInfo_hasNextPage(ctx context.Context, field gra
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bool)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
func (ec *executionContext) _PageInfo_hasPreviousPage(ctx context.Context, field graphql.CollectedField, obj *models.PageInfo) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "PageInfo",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.HasPreviousPage, nil
@@ -8194,34 +7743,31 @@ func (ec *executionContext) _PageInfo_hasPreviousPage(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bool)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
func (ec *executionContext) _PageInfo_startCursor(ctx context.Context, field graphql.CollectedField, obj *models.PageInfo) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "PageInfo",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.StartCursor, nil
@@ -8231,34 +7777,31 @@ func (ec *executionContext) _PageInfo_startCursor(ctx context.Context, field gra
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _PageInfo_endCursor(ctx context.Context, field graphql.CollectedField, obj *models.PageInfo) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "PageInfo",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.EndCursor, nil
@@ -8268,34 +7811,31 @@ func (ec *executionContext) _PageInfo_endCursor(ctx context.Context, field graph
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _Query_defaultRepository(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Query",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Query().DefaultRepository(rctx)
@@ -8308,35 +7848,32 @@ func (ec *executionContext) _Query_defaultRepository(ctx context.Context, field
return graphql.Null
}
res := resTmp.(*models.Repository)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalORepository2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐRepository(ctx, field.Selections, res)
}
func (ec *executionContext) _Query_repository(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Query",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Query_repository_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Query().Repository(rctx, args["ref"].(string))
@@ -8349,35 +7886,32 @@ func (ec *executionContext) _Query_repository(ctx context.Context, field graphql
return graphql.Null
}
res := resTmp.(*models.Repository)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalORepository2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐRepository(ctx, field.Selections, res)
}
func (ec *executionContext) _Query___type(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Query",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Query___type_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.introspectType(args["name"].(string))
@@ -8390,28 +7924,25 @@ func (ec *executionContext) _Query___type(ctx context.Context, field graphql.Col
return graphql.Null
}
res := resTmp.(*introspection.Type)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalO__Type2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
func (ec *executionContext) _Query___schema(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Query",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.introspectSchema()
@@ -8424,35 +7955,32 @@ func (ec *executionContext) _Query___schema(ctx context.Context, field graphql.C
return graphql.Null
}
res := resTmp.(*introspection.Schema)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalO__Schema2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalO__Schema2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx, field.Selections, res)
}
func (ec *executionContext) _Repository_allBugs(ctx context.Context, field graphql.CollectedField, obj *models.Repository) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Repository",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Repository_allBugs_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Repository().AllBugs(rctx, obj, args["after"].(*string), args["before"].(*string), args["first"].(*int), args["last"].(*int), args["query"].(*string))
@@ -8462,41 +7990,38 @@ func (ec *executionContext) _Repository_allBugs(ctx context.Context, field graph
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.BugConnection)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNBugConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugConnection(ctx, field.Selections, res)
}
func (ec *executionContext) _Repository_bug(ctx context.Context, field graphql.CollectedField, obj *models.Repository) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Repository",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Repository_bug_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Repository().Bug(rctx, obj, args["prefix"].(string))
@@ -8508,36 +8033,33 @@ func (ec *executionContext) _Repository_bug(ctx context.Context, field graphql.C
if resTmp == nil {
return graphql.Null
}
- res := resTmp.(*bug.Snapshot)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalOBug2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx, field.Selections, res)
+ res := resTmp.(models.BugWrapper)
+ fc.Result = res
+ return ec.marshalOBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _Repository_allIdentities(ctx context.Context, field graphql.CollectedField, obj *models.Repository) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Repository",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Repository_allIdentities_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Repository().AllIdentities(rctx, obj, args["after"].(*string), args["before"].(*string), args["first"].(*int), args["last"].(*int))
@@ -8547,41 +8069,38 @@ func (ec *executionContext) _Repository_allIdentities(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.IdentityConnection)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNIdentityConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityConnection(ctx, field.Selections, res)
}
func (ec *executionContext) _Repository_identity(ctx context.Context, field graphql.CollectedField, obj *models.Repository) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Repository",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Repository_identity_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Repository().Identity(rctx, obj, args["prefix"].(string))
@@ -8593,29 +8112,26 @@ func (ec *executionContext) _Repository_identity(ctx context.Context, field grap
if resTmp == nil {
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalOIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalOIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _Repository_userIdentity(ctx context.Context, field graphql.CollectedField, obj *models.Repository) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Repository",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Repository().UserIdentity(rctx, obj)
@@ -8627,36 +8143,33 @@ func (ec *executionContext) _Repository_userIdentity(ctx context.Context, field
if resTmp == nil {
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalOIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalOIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _Repository_validLabels(ctx context.Context, field graphql.CollectedField, obj *models.Repository) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "Repository",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Repository_validLabels_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Repository().ValidLabels(rctx, obj, args["after"].(*string), args["before"].(*string), args["first"].(*int), args["last"].(*int))
@@ -8666,34 +8179,31 @@ func (ec *executionContext) _Repository_validLabels(ctx context.Context, field g
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.LabelConnection)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNLabelConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐLabelConnection(ctx, field.Selections, res)
}
func (ec *executionContext) _SetStatusOperation_id(ctx context.Context, field graphql.CollectedField, obj *bug.SetStatusOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetStatusOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.SetStatusOperation().ID(rctx, obj)
@@ -8703,71 +8213,65 @@ func (ec *executionContext) _SetStatusOperation_id(ctx context.Context, field gr
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _SetStatusOperation_author(ctx context.Context, field graphql.CollectedField, obj *bug.SetStatusOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetStatusOperation",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Author, nil
+ return ec.resolvers.SetStatusOperation().Author(rctx, obj)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _SetStatusOperation_date(ctx context.Context, field graphql.CollectedField, obj *bug.SetStatusOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetStatusOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.SetStatusOperation().Date(rctx, obj)
@@ -8777,34 +8281,31 @@ func (ec *executionContext) _SetStatusOperation_date(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _SetStatusOperation_status(ctx context.Context, field graphql.CollectedField, obj *bug.SetStatusOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetStatusOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.SetStatusOperation().Status(rctx, obj)
@@ -8814,34 +8315,31 @@ func (ec *executionContext) _SetStatusOperation_status(ctx context.Context, fiel
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(models.Status)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNStatus2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐStatus(ctx, field.Selections, res)
}
func (ec *executionContext) _SetStatusTimelineItem_id(ctx context.Context, field graphql.CollectedField, obj *bug.SetStatusTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetStatusTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.SetStatusTimelineItem().ID(rctx, obj)
@@ -8851,71 +8349,65 @@ func (ec *executionContext) _SetStatusTimelineItem_id(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _SetStatusTimelineItem_author(ctx context.Context, field graphql.CollectedField, obj *bug.SetStatusTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetStatusTimelineItem",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Author, nil
+ return ec.resolvers.SetStatusTimelineItem().Author(rctx, obj)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _SetStatusTimelineItem_date(ctx context.Context, field graphql.CollectedField, obj *bug.SetStatusTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetStatusTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.SetStatusTimelineItem().Date(rctx, obj)
@@ -8925,34 +8417,31 @@ func (ec *executionContext) _SetStatusTimelineItem_date(ctx context.Context, fie
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _SetStatusTimelineItem_status(ctx context.Context, field graphql.CollectedField, obj *bug.SetStatusTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetStatusTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.SetStatusTimelineItem().Status(rctx, obj)
@@ -8962,34 +8451,31 @@ func (ec *executionContext) _SetStatusTimelineItem_status(ctx context.Context, f
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(models.Status)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNStatus2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐStatus(ctx, field.Selections, res)
}
func (ec *executionContext) _SetTitleOperation_id(ctx context.Context, field graphql.CollectedField, obj *bug.SetTitleOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetTitleOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.SetTitleOperation().ID(rctx, obj)
@@ -8999,71 +8485,65 @@ func (ec *executionContext) _SetTitleOperation_id(ctx context.Context, field gra
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _SetTitleOperation_author(ctx context.Context, field graphql.CollectedField, obj *bug.SetTitleOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetTitleOperation",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Author, nil
+ return ec.resolvers.SetTitleOperation().Author(rctx, obj)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _SetTitleOperation_date(ctx context.Context, field graphql.CollectedField, obj *bug.SetTitleOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetTitleOperation",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.SetTitleOperation().Date(rctx, obj)
@@ -9073,34 +8553,31 @@ func (ec *executionContext) _SetTitleOperation_date(ctx context.Context, field g
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _SetTitleOperation_title(ctx context.Context, field graphql.CollectedField, obj *bug.SetTitleOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetTitleOperation",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Title, nil
@@ -9110,34 +8587,31 @@ func (ec *executionContext) _SetTitleOperation_title(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _SetTitleOperation_was(ctx context.Context, field graphql.CollectedField, obj *bug.SetTitleOperation) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetTitleOperation",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Was, nil
@@ -9147,34 +8621,31 @@ func (ec *executionContext) _SetTitleOperation_was(ctx context.Context, field gr
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _SetTitlePayload_clientMutationId(ctx context.Context, field graphql.CollectedField, obj *models.SetTitlePayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetTitlePayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.ClientMutationID, nil
@@ -9187,28 +8658,25 @@ func (ec *executionContext) _SetTitlePayload_clientMutationId(ctx context.Contex
return graphql.Null
}
res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) _SetTitlePayload_bug(ctx context.Context, field graphql.CollectedField, obj *models.SetTitlePayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetTitlePayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Bug, nil
@@ -9218,34 +8686,31 @@ func (ec *executionContext) _SetTitlePayload_bug(ctx context.Context, field grap
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(*bug.Snapshot)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNBug2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx, field.Selections, res)
+ res := resTmp.(models.BugWrapper)
+ fc.Result = res
+ return ec.marshalNBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _SetTitlePayload_operation(ctx context.Context, field graphql.CollectedField, obj *models.SetTitlePayload) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetTitlePayload",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Operation, nil
@@ -9255,34 +8720,31 @@ func (ec *executionContext) _SetTitlePayload_operation(ctx context.Context, fiel
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*bug.SetTitleOperation)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNSetTitleOperation2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSetTitleOperation(ctx, field.Selections, res)
}
func (ec *executionContext) _SetTitleTimelineItem_id(ctx context.Context, field graphql.CollectedField, obj *bug.SetTitleTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetTitleTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.SetTitleTimelineItem().ID(rctx, obj)
@@ -9292,71 +8754,65 @@ func (ec *executionContext) _SetTitleTimelineItem_id(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _SetTitleTimelineItem_author(ctx context.Context, field graphql.CollectedField, obj *bug.SetTitleTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetTitleTimelineItem",
Field: field,
Args: nil,
- IsMethod: false,
+ IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
- return obj.Author, nil
+ return ec.resolvers.SetTitleTimelineItem().Author(rctx, obj)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
- res := resTmp.(identity.Interface)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, field.Selections, res)
+ res := resTmp.(models.IdentityWrapper)
+ fc.Result = res
+ return ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, field.Selections, res)
}
func (ec *executionContext) _SetTitleTimelineItem_date(ctx context.Context, field graphql.CollectedField, obj *bug.SetTitleTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetTitleTimelineItem",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.SetTitleTimelineItem().Date(rctx, obj)
@@ -9366,34 +8822,31 @@ func (ec *executionContext) _SetTitleTimelineItem_date(ctx context.Context, fiel
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*time.Time)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTime2ᚖtimeᚐTime(ctx, field.Selections, res)
}
func (ec *executionContext) _SetTitleTimelineItem_title(ctx context.Context, field graphql.CollectedField, obj *bug.SetTitleTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetTitleTimelineItem",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Title, nil
@@ -9403,34 +8856,31 @@ func (ec *executionContext) _SetTitleTimelineItem_title(ctx context.Context, fie
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _SetTitleTimelineItem_was(ctx context.Context, field graphql.CollectedField, obj *bug.SetTitleTimelineItem) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "SetTitleTimelineItem",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Was, nil
@@ -9440,34 +8890,31 @@ func (ec *executionContext) _SetTitleTimelineItem_was(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _TimelineItemConnection_edges(ctx context.Context, field graphql.CollectedField, obj *models.TimelineItemConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "TimelineItemConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Edges, nil
@@ -9477,34 +8924,31 @@ func (ec *executionContext) _TimelineItemConnection_edges(ctx context.Context, f
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]*models.TimelineItemEdge)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNTimelineItemEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐTimelineItemEdge(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNTimelineItemEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐTimelineItemEdgeᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _TimelineItemConnection_nodes(ctx context.Context, field graphql.CollectedField, obj *models.TimelineItemConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "TimelineItemConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Nodes, nil
@@ -9514,34 +8958,31 @@ func (ec *executionContext) _TimelineItemConnection_nodes(ctx context.Context, f
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]bug.TimelineItem)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalNTimelineItem2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐTimelineItem(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalNTimelineItem2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐTimelineItemᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) _TimelineItemConnection_pageInfo(ctx context.Context, field graphql.CollectedField, obj *models.TimelineItemConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "TimelineItemConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.PageInfo, nil
@@ -9551,34 +8992,31 @@ func (ec *executionContext) _TimelineItemConnection_pageInfo(ctx context.Context
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*models.PageInfo)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNPageInfo2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐPageInfo(ctx, field.Selections, res)
}
func (ec *executionContext) _TimelineItemConnection_totalCount(ctx context.Context, field graphql.CollectedField, obj *models.TimelineItemConnection) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "TimelineItemConnection",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.TotalCount, nil
@@ -9588,34 +9026,31 @@ func (ec *executionContext) _TimelineItemConnection_totalCount(ctx context.Conte
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(int)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNInt2int(ctx, field.Selections, res)
}
func (ec *executionContext) _TimelineItemEdge_cursor(ctx context.Context, field graphql.CollectedField, obj *models.TimelineItemEdge) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "TimelineItemEdge",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Cursor, nil
@@ -9625,34 +9060,31 @@ func (ec *executionContext) _TimelineItemEdge_cursor(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _TimelineItemEdge_node(ctx context.Context, field graphql.CollectedField, obj *models.TimelineItemEdge) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "TimelineItemEdge",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Node, nil
@@ -9662,34 +9094,31 @@ func (ec *executionContext) _TimelineItemEdge_node(ctx context.Context, field gr
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bug.TimelineItem)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNTimelineItem2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐTimelineItem(ctx, field.Selections, res)
}
func (ec *executionContext) ___Directive_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Directive",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Name, nil
@@ -9699,34 +9128,31 @@ func (ec *executionContext) ___Directive_name(ctx context.Context, field graphql
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___Directive_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Directive",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Description, nil
@@ -9739,28 +9165,25 @@ func (ec *executionContext) ___Directive_description(ctx context.Context, field
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___Directive_locations(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Directive",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Locations, nil
@@ -9770,34 +9193,31 @@ func (ec *executionContext) ___Directive_locations(ctx context.Context, field gr
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalN__DirectiveLocation2ᚕstring(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalN__DirectiveLocation2ᚕstringᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Directive_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Directive",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Args, nil
@@ -9807,34 +9227,31 @@ func (ec *executionContext) ___Directive_args(ctx context.Context, field graphql
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]introspection.InputValue)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalN__InputValue2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___EnumValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__EnumValue",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Name, nil
@@ -9844,34 +9261,31 @@ func (ec *executionContext) ___EnumValue_name(ctx context.Context, field graphql
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___EnumValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__EnumValue",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Description, nil
@@ -9884,28 +9298,25 @@ func (ec *executionContext) ___EnumValue_description(ctx context.Context, field
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___EnumValue_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__EnumValue",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.IsDeprecated(), nil
@@ -9915,34 +9326,31 @@ func (ec *executionContext) ___EnumValue_isDeprecated(ctx context.Context, field
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bool)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
func (ec *executionContext) ___EnumValue_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__EnumValue",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.DeprecationReason(), nil
@@ -9955,28 +9363,25 @@ func (ec *executionContext) ___EnumValue_deprecationReason(ctx context.Context,
return graphql.Null
}
res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) ___Field_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Field",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Name, nil
@@ -9986,34 +9391,31 @@ func (ec *executionContext) ___Field_name(ctx context.Context, field graphql.Col
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___Field_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Field",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Description, nil
@@ -10026,28 +9428,25 @@ func (ec *executionContext) ___Field_description(ctx context.Context, field grap
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___Field_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Field",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Args, nil
@@ -10057,34 +9456,31 @@ func (ec *executionContext) ___Field_args(ctx context.Context, field graphql.Col
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]introspection.InputValue)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalN__InputValue2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Field_type(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Field",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Type, nil
@@ -10094,34 +9490,31 @@ func (ec *executionContext) ___Field_type(ctx context.Context, field graphql.Col
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*introspection.Type)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalN__Type2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
func (ec *executionContext) ___Field_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Field",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.IsDeprecated(), nil
@@ -10131,34 +9524,31 @@ func (ec *executionContext) ___Field_isDeprecated(ctx context.Context, field gra
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bool)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
func (ec *executionContext) ___Field_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Field",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.DeprecationReason(), nil
@@ -10171,28 +9561,25 @@ func (ec *executionContext) ___Field_deprecationReason(ctx context.Context, fiel
return graphql.Null
}
res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) ___InputValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__InputValue",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Name, nil
@@ -10202,34 +9589,31 @@ func (ec *executionContext) ___InputValue_name(ctx context.Context, field graphq
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___InputValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__InputValue",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Description, nil
@@ -10242,28 +9626,25 @@ func (ec *executionContext) ___InputValue_description(ctx context.Context, field
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___InputValue_type(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__InputValue",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Type, nil
@@ -10273,34 +9654,31 @@ func (ec *executionContext) ___InputValue_type(ctx context.Context, field graphq
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*introspection.Type)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalN__Type2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
func (ec *executionContext) ___InputValue_defaultValue(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__InputValue",
Field: field,
Args: nil,
IsMethod: false,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.DefaultValue, nil
@@ -10313,28 +9691,25 @@ func (ec *executionContext) ___InputValue_defaultValue(ctx context.Context, fiel
return graphql.Null
}
res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) ___Schema_types(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Schema",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Types(), nil
@@ -10344,34 +9719,31 @@ func (ec *executionContext) ___Schema_types(ctx context.Context, field graphql.C
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]introspection.Type)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalN__Type2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Schema_queryType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Schema",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.QueryType(), nil
@@ -10381,34 +9753,31 @@ func (ec *executionContext) ___Schema_queryType(ctx context.Context, field graph
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*introspection.Type)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalN__Type2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
func (ec *executionContext) ___Schema_mutationType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Schema",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.MutationType(), nil
@@ -10421,28 +9790,25 @@ func (ec *executionContext) ___Schema_mutationType(ctx context.Context, field gr
return graphql.Null
}
res := resTmp.(*introspection.Type)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalO__Type2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
func (ec *executionContext) ___Schema_subscriptionType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Schema",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.SubscriptionType(), nil
@@ -10455,28 +9821,25 @@ func (ec *executionContext) ___Schema_subscriptionType(ctx context.Context, fiel
return graphql.Null
}
res := resTmp.(*introspection.Type)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalO__Type2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
func (ec *executionContext) ___Schema_directives(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Schema",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Directives(), nil
@@ -10486,34 +9849,31 @@ func (ec *executionContext) ___Schema_directives(ctx context.Context, field grap
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]introspection.Directive)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalN__Directive2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalN__Directive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirectiveᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_kind(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Kind(), nil
@@ -10523,34 +9883,31 @@ func (ec *executionContext) ___Type_kind(ctx context.Context, field graphql.Coll
return graphql.Null
}
if resTmp == nil {
- if !ec.HasError(rctx) {
+ if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalN__TypeKind2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Name(), nil
@@ -10563,28 +9920,25 @@ func (ec *executionContext) ___Type_name(ctx context.Context, field graphql.Coll
return graphql.Null
}
res := resTmp.(*string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Description(), nil
@@ -10597,35 +9951,32 @@ func (ec *executionContext) ___Type_description(ctx context.Context, field graph
return graphql.Null
}
res := resTmp.(string)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
+ fc.Result = res
return ec.marshalOString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_fields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field___Type_fields_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Fields(args["includeDeprecated"].(bool)), nil
@@ -10638,28 +9989,25 @@ func (ec *executionContext) ___Type_fields(ctx context.Context, field graphql.Co
return graphql.Null
}
res := resTmp.([]introspection.Field)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalO__Field2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalO__Field2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐFieldᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_interfaces(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Interfaces(), nil
@@ -10672,28 +10020,25 @@ func (ec *executionContext) ___Type_interfaces(ctx context.Context, field graphq
return graphql.Null
}
res := resTmp.([]introspection.Type)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalO__Type2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_possibleTypes(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.PossibleTypes(), nil
@@ -10706,35 +10051,32 @@ func (ec *executionContext) ___Type_possibleTypes(ctx context.Context, field gra
return graphql.Null
}
res := resTmp.([]introspection.Type)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalO__Type2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_enumValues(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field___Type_enumValues_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
- rctx.Args = args
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+ fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.EnumValues(args["includeDeprecated"].(bool)), nil
@@ -10747,28 +10089,25 @@ func (ec *executionContext) ___Type_enumValues(ctx context.Context, field graphq
return graphql.Null
}
res := resTmp.([]introspection.EnumValue)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalO__EnumValue2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalO__EnumValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValueᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_inputFields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.InputFields(), nil
@@ -10781,28 +10120,25 @@ func (ec *executionContext) ___Type_inputFields(ctx context.Context, field graph
return graphql.Null
}
res := resTmp.([]introspection.InputValue)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalO__InputValue2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalO__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_ofType(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
- ctx = ec.Tracer.StartFieldExecution(ctx, field)
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
- ec.Tracer.EndFieldExecution(ctx)
}()
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
}
- ctx = graphql.WithResolverContext(ctx, rctx)
- ctx = ec.Tracer.StartFieldResolverExecution(ctx, rctx)
+
+ ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.OfType(), nil
@@ -10815,9 +10151,8 @@ func (ec *executionContext) ___Type_ofType(ctx context.Context, field graphql.Co
return graphql.Null
}
res := resTmp.(*introspection.Type)
- rctx.Result = res
- ctx = ec.Tracer.StartFieldChildExecution(ctx)
- return ec.marshalO__Type2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
+ fc.Result = res
+ return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
// endregion **************************** field.gotpl *****************************
@@ -10856,7 +10191,7 @@ func (ec *executionContext) unmarshalInputAddCommentInput(ctx context.Context, o
}
case "files":
var err error
- it.Files, err = ec.unmarshalOHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHash(ctx, v)
+ it.Files, err = ec.unmarshalOHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHashᚄ(ctx, v)
if err != nil {
return it, err
}
@@ -10892,13 +10227,13 @@ func (ec *executionContext) unmarshalInputChangeLabelInput(ctx context.Context,
}
case "added":
var err error
- it.Added, err = ec.unmarshalOString2ᚕstring(ctx, v)
+ it.Added, err = ec.unmarshalOString2ᚕstringᚄ(ctx, v)
if err != nil {
return it, err
}
case "Removed":
var err error
- it.Removed, err = ec.unmarshalOString2ᚕstring(ctx, v)
+ it.Removed, err = ec.unmarshalOString2ᚕstringᚄ(ctx, v)
if err != nil {
return it, err
}
@@ -11030,7 +10365,7 @@ func (ec *executionContext) unmarshalInputNewBugInput(ctx context.Context, obj i
}
case "files":
var err error
- it.Files, err = ec.unmarshalOHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHash(ctx, v)
+ it.Files, err = ec.unmarshalOHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHashᚄ(ctx, v)
if err != nil {
return it, err
}
@@ -11110,83 +10445,155 @@ func (ec *executionContext) unmarshalInputSetTitleInput(ctx context.Context, obj
// region ************************** interface.gotpl ***************************
-func (ec *executionContext) _Authored(ctx context.Context, sel ast.SelectionSet, obj *models.Authored) graphql.Marshaler {
- switch obj := (*obj).(type) {
+func (ec *executionContext) _Authored(ctx context.Context, sel ast.SelectionSet, obj models.Authored) graphql.Marshaler {
+ switch obj := (obj).(type) {
case nil:
return graphql.Null
case bug.Comment:
return ec._Comment(ctx, sel, &obj)
case *bug.Comment:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._Comment(ctx, sel, obj)
- case *bug.Snapshot:
+ case models.BugWrapper:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._Bug(ctx, sel, obj)
case *bug.CreateOperation:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._CreateOperation(ctx, sel, obj)
case *bug.SetTitleOperation:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._SetTitleOperation(ctx, sel, obj)
case *bug.AddCommentOperation:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._AddCommentOperation(ctx, sel, obj)
case *bug.EditCommentOperation:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._EditCommentOperation(ctx, sel, obj)
case *bug.SetStatusOperation:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._SetStatusOperation(ctx, sel, obj)
case *bug.LabelChangeOperation:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._LabelChangeOperation(ctx, sel, obj)
case *bug.CreateTimelineItem:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._CreateTimelineItem(ctx, sel, obj)
case *bug.AddCommentTimelineItem:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._AddCommentTimelineItem(ctx, sel, obj)
case *bug.LabelChangeTimelineItem:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._LabelChangeTimelineItem(ctx, sel, obj)
case *bug.SetStatusTimelineItem:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._SetStatusTimelineItem(ctx, sel, obj)
case *bug.SetTitleTimelineItem:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._SetTitleTimelineItem(ctx, sel, obj)
default:
panic(fmt.Errorf("unexpected type %T", obj))
}
}
-func (ec *executionContext) _Operation(ctx context.Context, sel ast.SelectionSet, obj *bug.Operation) graphql.Marshaler {
- switch obj := (*obj).(type) {
+func (ec *executionContext) _Operation(ctx context.Context, sel ast.SelectionSet, obj bug.Operation) graphql.Marshaler {
+ switch obj := (obj).(type) {
case nil:
return graphql.Null
case *bug.CreateOperation:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._CreateOperation(ctx, sel, obj)
case *bug.SetTitleOperation:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._SetTitleOperation(ctx, sel, obj)
case *bug.AddCommentOperation:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._AddCommentOperation(ctx, sel, obj)
case *bug.EditCommentOperation:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._EditCommentOperation(ctx, sel, obj)
case *bug.SetStatusOperation:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._SetStatusOperation(ctx, sel, obj)
case *bug.LabelChangeOperation:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._LabelChangeOperation(ctx, sel, obj)
default:
panic(fmt.Errorf("unexpected type %T", obj))
}
}
-func (ec *executionContext) _TimelineItem(ctx context.Context, sel ast.SelectionSet, obj *bug.TimelineItem) graphql.Marshaler {
- switch obj := (*obj).(type) {
+func (ec *executionContext) _TimelineItem(ctx context.Context, sel ast.SelectionSet, obj bug.TimelineItem) graphql.Marshaler {
+ switch obj := (obj).(type) {
case nil:
return graphql.Null
case *bug.CreateTimelineItem:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._CreateTimelineItem(ctx, sel, obj)
case *bug.AddCommentTimelineItem:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._AddCommentTimelineItem(ctx, sel, obj)
case bug.LabelChangeTimelineItem:
return ec._LabelChangeTimelineItem(ctx, sel, &obj)
case *bug.LabelChangeTimelineItem:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._LabelChangeTimelineItem(ctx, sel, obj)
case bug.SetStatusTimelineItem:
return ec._SetStatusTimelineItem(ctx, sel, &obj)
case *bug.SetStatusTimelineItem:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._SetStatusTimelineItem(ctx, sel, obj)
case bug.SetTitleTimelineItem:
return ec._SetTitleTimelineItem(ctx, sel, &obj)
case *bug.SetTitleTimelineItem:
+ if obj == nil {
+ return graphql.Null
+ }
return ec._SetTitleTimelineItem(ctx, sel, obj)
default:
panic(fmt.Errorf("unexpected type %T", obj))
@@ -11200,7 +10607,7 @@ func (ec *executionContext) _TimelineItem(ctx context.Context, sel ast.Selection
var addCommentOperationImplementors = []string{"AddCommentOperation", "Operation", "Authored"}
func (ec *executionContext) _AddCommentOperation(ctx context.Context, sel ast.SelectionSet, obj *bug.AddCommentOperation) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, addCommentOperationImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, addCommentOperationImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11223,10 +10630,19 @@ func (ec *executionContext) _AddCommentOperation(ctx context.Context, sel ast.Se
return res
})
case "author":
- out.Values[i] = ec._AddCommentOperation_author(ctx, field, obj)
- if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
+ field := field
+ out.Concurrently(i, func() (res graphql.Marshaler) {
+ defer func() {
+ if r := recover(); r != nil {
+ ec.Error(ctx, ec.Recover(ctx, r))
+ }
+ }()
+ res = ec._AddCommentOperation_author(ctx, field, obj)
+ if res == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
+ return res
+ })
case "date":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
@@ -11265,7 +10681,7 @@ func (ec *executionContext) _AddCommentOperation(ctx context.Context, sel ast.Se
var addCommentPayloadImplementors = []string{"AddCommentPayload"}
func (ec *executionContext) _AddCommentPayload(ctx context.Context, sel ast.SelectionSet, obj *models.AddCommentPayload) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, addCommentPayloadImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, addCommentPayloadImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11299,7 +10715,7 @@ func (ec *executionContext) _AddCommentPayload(ctx context.Context, sel ast.Sele
var addCommentTimelineItemImplementors = []string{"AddCommentTimelineItem", "TimelineItem", "Authored"}
func (ec *executionContext) _AddCommentTimelineItem(ctx context.Context, sel ast.SelectionSet, obj *bug.AddCommentTimelineItem) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, addCommentTimelineItemImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, addCommentTimelineItemImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11322,10 +10738,19 @@ func (ec *executionContext) _AddCommentTimelineItem(ctx context.Context, sel ast
return res
})
case "author":
- out.Values[i] = ec._AddCommentTimelineItem_author(ctx, field, obj)
- if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
+ field := field
+ out.Concurrently(i, func() (res graphql.Marshaler) {
+ defer func() {
+ if r := recover(); r != nil {
+ ec.Error(ctx, ec.Recover(ctx, r))
+ }
+ }()
+ res = ec._AddCommentTimelineItem_author(ctx, field, obj)
+ if res == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
+ return res
+ })
case "message":
out.Values[i] = ec._AddCommentTimelineItem_message(ctx, field, obj)
if out.Values[i] == graphql.Null {
@@ -11392,8 +10817,8 @@ func (ec *executionContext) _AddCommentTimelineItem(ctx context.Context, sel ast
var bugImplementors = []string{"Bug", "Authored"}
-func (ec *executionContext) _Bug(ctx context.Context, sel ast.SelectionSet, obj *bug.Snapshot) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, bugImplementors)
+func (ec *executionContext) _Bug(ctx context.Context, sel ast.SelectionSet, obj models.BugWrapper) graphql.Marshaler {
+ fields := graphql.CollectFields(ec.OperationContext, sel, bugImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11464,19 +10889,10 @@ func (ec *executionContext) _Bug(ctx context.Context, sel ast.SelectionSet, obj
atomic.AddUint32(&invalids, 1)
}
case "lastEdit":
- field := field
- out.Concurrently(i, func() (res graphql.Marshaler) {
- defer func() {
- if r := recover(); r != nil {
- ec.Error(ctx, ec.Recover(ctx, r))
- }
- }()
- res = ec._Bug_lastEdit(ctx, field, obj)
- if res == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
- return res
- })
+ out.Values[i] = ec._Bug_lastEdit(ctx, field, obj)
+ if out.Values[i] == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
case "actors":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
@@ -11561,7 +10977,7 @@ func (ec *executionContext) _Bug(ctx context.Context, sel ast.SelectionSet, obj
var bugConnectionImplementors = []string{"BugConnection"}
func (ec *executionContext) _BugConnection(ctx context.Context, sel ast.SelectionSet, obj *models.BugConnection) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, bugConnectionImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, bugConnectionImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11603,7 +11019,7 @@ func (ec *executionContext) _BugConnection(ctx context.Context, sel ast.Selectio
var bugEdgeImplementors = []string{"BugEdge"}
func (ec *executionContext) _BugEdge(ctx context.Context, sel ast.SelectionSet, obj *models.BugEdge) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, bugEdgeImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, bugEdgeImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11635,7 +11051,7 @@ func (ec *executionContext) _BugEdge(ctx context.Context, sel ast.SelectionSet,
var changeLabelPayloadImplementors = []string{"ChangeLabelPayload"}
func (ec *executionContext) _ChangeLabelPayload(ctx context.Context, sel ast.SelectionSet, obj *models.ChangeLabelPayload) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, changeLabelPayloadImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, changeLabelPayloadImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11674,7 +11090,7 @@ func (ec *executionContext) _ChangeLabelPayload(ctx context.Context, sel ast.Sel
var closeBugPayloadImplementors = []string{"CloseBugPayload"}
func (ec *executionContext) _CloseBugPayload(ctx context.Context, sel ast.SelectionSet, obj *models.CloseBugPayload) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, closeBugPayloadImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, closeBugPayloadImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11708,7 +11124,7 @@ func (ec *executionContext) _CloseBugPayload(ctx context.Context, sel ast.Select
var colorImplementors = []string{"Color"}
func (ec *executionContext) _Color(ctx context.Context, sel ast.SelectionSet, obj *color.RGBA) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, colorImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, colorImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11772,7 +11188,7 @@ func (ec *executionContext) _Color(ctx context.Context, sel ast.SelectionSet, ob
var commentImplementors = []string{"Comment", "Authored"}
func (ec *executionContext) _Comment(ctx context.Context, sel ast.SelectionSet, obj *bug.Comment) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, commentImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, commentImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11781,19 +11197,28 @@ func (ec *executionContext) _Comment(ctx context.Context, sel ast.SelectionSet,
case "__typename":
out.Values[i] = graphql.MarshalString("Comment")
case "author":
- out.Values[i] = ec._Comment_author(ctx, field, obj)
- if out.Values[i] == graphql.Null {
- invalids++
- }
+ field := field
+ out.Concurrently(i, func() (res graphql.Marshaler) {
+ defer func() {
+ if r := recover(); r != nil {
+ ec.Error(ctx, ec.Recover(ctx, r))
+ }
+ }()
+ res = ec._Comment_author(ctx, field, obj)
+ if res == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
+ return res
+ })
case "message":
out.Values[i] = ec._Comment_message(ctx, field, obj)
if out.Values[i] == graphql.Null {
- invalids++
+ atomic.AddUint32(&invalids, 1)
}
case "files":
out.Values[i] = ec._Comment_files(ctx, field, obj)
if out.Values[i] == graphql.Null {
- invalids++
+ atomic.AddUint32(&invalids, 1)
}
default:
panic("unknown field " + strconv.Quote(field.Name))
@@ -11809,7 +11234,7 @@ func (ec *executionContext) _Comment(ctx context.Context, sel ast.SelectionSet,
var commentConnectionImplementors = []string{"CommentConnection"}
func (ec *executionContext) _CommentConnection(ctx context.Context, sel ast.SelectionSet, obj *models.CommentConnection) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, commentConnectionImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, commentConnectionImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11851,7 +11276,7 @@ func (ec *executionContext) _CommentConnection(ctx context.Context, sel ast.Sele
var commentEdgeImplementors = []string{"CommentEdge"}
func (ec *executionContext) _CommentEdge(ctx context.Context, sel ast.SelectionSet, obj *models.CommentEdge) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, commentEdgeImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, commentEdgeImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11883,7 +11308,7 @@ func (ec *executionContext) _CommentEdge(ctx context.Context, sel ast.SelectionS
var commentHistoryStepImplementors = []string{"CommentHistoryStep"}
func (ec *executionContext) _CommentHistoryStep(ctx context.Context, sel ast.SelectionSet, obj *bug.CommentHistoryStep) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, commentHistoryStepImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, commentHistoryStepImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11924,7 +11349,7 @@ func (ec *executionContext) _CommentHistoryStep(ctx context.Context, sel ast.Sel
var commitAsNeededPayloadImplementors = []string{"CommitAsNeededPayload"}
func (ec *executionContext) _CommitAsNeededPayload(ctx context.Context, sel ast.SelectionSet, obj *models.CommitAsNeededPayload) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, commitAsNeededPayloadImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, commitAsNeededPayloadImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11953,7 +11378,7 @@ func (ec *executionContext) _CommitAsNeededPayload(ctx context.Context, sel ast.
var commitPayloadImplementors = []string{"CommitPayload"}
func (ec *executionContext) _CommitPayload(ctx context.Context, sel ast.SelectionSet, obj *models.CommitPayload) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, commitPayloadImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, commitPayloadImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -11982,7 +11407,7 @@ func (ec *executionContext) _CommitPayload(ctx context.Context, sel ast.Selectio
var createOperationImplementors = []string{"CreateOperation", "Operation", "Authored"}
func (ec *executionContext) _CreateOperation(ctx context.Context, sel ast.SelectionSet, obj *bug.CreateOperation) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, createOperationImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, createOperationImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12005,10 +11430,19 @@ func (ec *executionContext) _CreateOperation(ctx context.Context, sel ast.Select
return res
})
case "author":
- out.Values[i] = ec._CreateOperation_author(ctx, field, obj)
- if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
+ field := field
+ out.Concurrently(i, func() (res graphql.Marshaler) {
+ defer func() {
+ if r := recover(); r != nil {
+ ec.Error(ctx, ec.Recover(ctx, r))
+ }
+ }()
+ res = ec._CreateOperation_author(ctx, field, obj)
+ if res == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
+ return res
+ })
case "date":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
@@ -12052,7 +11486,7 @@ func (ec *executionContext) _CreateOperation(ctx context.Context, sel ast.Select
var createTimelineItemImplementors = []string{"CreateTimelineItem", "TimelineItem", "Authored"}
func (ec *executionContext) _CreateTimelineItem(ctx context.Context, sel ast.SelectionSet, obj *bug.CreateTimelineItem) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, createTimelineItemImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, createTimelineItemImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12075,10 +11509,19 @@ func (ec *executionContext) _CreateTimelineItem(ctx context.Context, sel ast.Sel
return res
})
case "author":
- out.Values[i] = ec._CreateTimelineItem_author(ctx, field, obj)
- if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
+ field := field
+ out.Concurrently(i, func() (res graphql.Marshaler) {
+ defer func() {
+ if r := recover(); r != nil {
+ ec.Error(ctx, ec.Recover(ctx, r))
+ }
+ }()
+ res = ec._CreateTimelineItem_author(ctx, field, obj)
+ if res == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
+ return res
+ })
case "message":
out.Values[i] = ec._CreateTimelineItem_message(ctx, field, obj)
if out.Values[i] == graphql.Null {
@@ -12146,7 +11589,7 @@ func (ec *executionContext) _CreateTimelineItem(ctx context.Context, sel ast.Sel
var editCommentOperationImplementors = []string{"EditCommentOperation", "Operation", "Authored"}
func (ec *executionContext) _EditCommentOperation(ctx context.Context, sel ast.SelectionSet, obj *bug.EditCommentOperation) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, editCommentOperationImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, editCommentOperationImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12169,10 +11612,19 @@ func (ec *executionContext) _EditCommentOperation(ctx context.Context, sel ast.S
return res
})
case "author":
- out.Values[i] = ec._EditCommentOperation_author(ctx, field, obj)
- if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
+ field := field
+ out.Concurrently(i, func() (res graphql.Marshaler) {
+ defer func() {
+ if r := recover(); r != nil {
+ ec.Error(ctx, ec.Recover(ctx, r))
+ }
+ }()
+ res = ec._EditCommentOperation_author(ctx, field, obj)
+ if res == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
+ return res
+ })
case "date":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
@@ -12224,8 +11676,8 @@ func (ec *executionContext) _EditCommentOperation(ctx context.Context, sel ast.S
var identityImplementors = []string{"Identity"}
-func (ec *executionContext) _Identity(ctx context.Context, sel ast.SelectionSet, obj *identity.Interface) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, identityImplementors)
+func (ec *executionContext) _Identity(ctx context.Context, sel ast.SelectionSet, obj models.IdentityWrapper) graphql.Marshaler {
+ fields := graphql.CollectFields(ec.OperationContext, sel, identityImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12262,77 +11714,21 @@ func (ec *executionContext) _Identity(ctx context.Context, sel ast.SelectionSet,
return res
})
case "name":
- field := field
- out.Concurrently(i, func() (res graphql.Marshaler) {
- defer func() {
- if r := recover(); r != nil {
- ec.Error(ctx, ec.Recover(ctx, r))
- }
- }()
- res = ec._Identity_name(ctx, field, obj)
- return res
- })
+ out.Values[i] = ec._Identity_name(ctx, field, obj)
case "email":
- field := field
- out.Concurrently(i, func() (res graphql.Marshaler) {
- defer func() {
- if r := recover(); r != nil {
- ec.Error(ctx, ec.Recover(ctx, r))
- }
- }()
- res = ec._Identity_email(ctx, field, obj)
- return res
- })
- case "login":
- field := field
- out.Concurrently(i, func() (res graphql.Marshaler) {
- defer func() {
- if r := recover(); r != nil {
- ec.Error(ctx, ec.Recover(ctx, r))
- }
- }()
- res = ec._Identity_login(ctx, field, obj)
- return res
- })
+ out.Values[i] = ec._Identity_email(ctx, field, obj)
case "displayName":
- field := field
- out.Concurrently(i, func() (res graphql.Marshaler) {
- defer func() {
- if r := recover(); r != nil {
- ec.Error(ctx, ec.Recover(ctx, r))
- }
- }()
- res = ec._Identity_displayName(ctx, field, obj)
- if res == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
- return res
- })
+ out.Values[i] = ec._Identity_displayName(ctx, field, obj)
+ if out.Values[i] == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
case "avatarUrl":
- field := field
- out.Concurrently(i, func() (res graphql.Marshaler) {
- defer func() {
- if r := recover(); r != nil {
- ec.Error(ctx, ec.Recover(ctx, r))
- }
- }()
- res = ec._Identity_avatarUrl(ctx, field, obj)
- return res
- })
+ out.Values[i] = ec._Identity_avatarUrl(ctx, field, obj)
case "isProtected":
- field := field
- out.Concurrently(i, func() (res graphql.Marshaler) {
- defer func() {
- if r := recover(); r != nil {
- ec.Error(ctx, ec.Recover(ctx, r))
- }
- }()
- res = ec._Identity_isProtected(ctx, field, obj)
- if res == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
- return res
- })
+ out.Values[i] = ec._Identity_isProtected(ctx, field, obj)
+ if out.Values[i] == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
default:
panic("unknown field " + strconv.Quote(field.Name))
}
@@ -12347,7 +11743,7 @@ func (ec *executionContext) _Identity(ctx context.Context, sel ast.SelectionSet,
var identityConnectionImplementors = []string{"IdentityConnection"}
func (ec *executionContext) _IdentityConnection(ctx context.Context, sel ast.SelectionSet, obj *models.IdentityConnection) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, identityConnectionImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, identityConnectionImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12389,7 +11785,7 @@ func (ec *executionContext) _IdentityConnection(ctx context.Context, sel ast.Sel
var identityEdgeImplementors = []string{"IdentityEdge"}
func (ec *executionContext) _IdentityEdge(ctx context.Context, sel ast.SelectionSet, obj *models.IdentityEdge) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, identityEdgeImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, identityEdgeImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12421,7 +11817,7 @@ func (ec *executionContext) _IdentityEdge(ctx context.Context, sel ast.Selection
var labelImplementors = []string{"Label"}
func (ec *executionContext) _Label(ctx context.Context, sel ast.SelectionSet, obj *bug.Label) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, labelImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, labelImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12471,7 +11867,7 @@ func (ec *executionContext) _Label(ctx context.Context, sel ast.SelectionSet, ob
var labelChangeOperationImplementors = []string{"LabelChangeOperation", "Operation", "Authored"}
func (ec *executionContext) _LabelChangeOperation(ctx context.Context, sel ast.SelectionSet, obj *bug.LabelChangeOperation) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, labelChangeOperationImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, labelChangeOperationImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12494,10 +11890,19 @@ func (ec *executionContext) _LabelChangeOperation(ctx context.Context, sel ast.S
return res
})
case "author":
- out.Values[i] = ec._LabelChangeOperation_author(ctx, field, obj)
- if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
+ field := field
+ out.Concurrently(i, func() (res graphql.Marshaler) {
+ defer func() {
+ if r := recover(); r != nil {
+ ec.Error(ctx, ec.Recover(ctx, r))
+ }
+ }()
+ res = ec._LabelChangeOperation_author(ctx, field, obj)
+ if res == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
+ return res
+ })
case "date":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
@@ -12536,7 +11941,7 @@ func (ec *executionContext) _LabelChangeOperation(ctx context.Context, sel ast.S
var labelChangeResultImplementors = []string{"LabelChangeResult"}
func (ec *executionContext) _LabelChangeResult(ctx context.Context, sel ast.SelectionSet, obj *bug.LabelChangeResult) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, labelChangeResultImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, labelChangeResultImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12577,7 +11982,7 @@ func (ec *executionContext) _LabelChangeResult(ctx context.Context, sel ast.Sele
var labelChangeTimelineItemImplementors = []string{"LabelChangeTimelineItem", "TimelineItem", "Authored"}
func (ec *executionContext) _LabelChangeTimelineItem(ctx context.Context, sel ast.SelectionSet, obj *bug.LabelChangeTimelineItem) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, labelChangeTimelineItemImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, labelChangeTimelineItemImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12600,10 +12005,19 @@ func (ec *executionContext) _LabelChangeTimelineItem(ctx context.Context, sel as
return res
})
case "author":
- out.Values[i] = ec._LabelChangeTimelineItem_author(ctx, field, obj)
- if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
+ field := field
+ out.Concurrently(i, func() (res graphql.Marshaler) {
+ defer func() {
+ if r := recover(); r != nil {
+ ec.Error(ctx, ec.Recover(ctx, r))
+ }
+ }()
+ res = ec._LabelChangeTimelineItem_author(ctx, field, obj)
+ if res == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
+ return res
+ })
case "date":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
@@ -12642,7 +12056,7 @@ func (ec *executionContext) _LabelChangeTimelineItem(ctx context.Context, sel as
var labelConnectionImplementors = []string{"LabelConnection"}
func (ec *executionContext) _LabelConnection(ctx context.Context, sel ast.SelectionSet, obj *models.LabelConnection) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, labelConnectionImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, labelConnectionImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12684,7 +12098,7 @@ func (ec *executionContext) _LabelConnection(ctx context.Context, sel ast.Select
var labelEdgeImplementors = []string{"LabelEdge"}
func (ec *executionContext) _LabelEdge(ctx context.Context, sel ast.SelectionSet, obj *models.LabelEdge) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, labelEdgeImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, labelEdgeImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12716,9 +12130,9 @@ func (ec *executionContext) _LabelEdge(ctx context.Context, sel ast.SelectionSet
var mutationImplementors = []string{"Mutation"}
func (ec *executionContext) _Mutation(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, mutationImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, mutationImplementors)
- ctx = graphql.WithResolverContext(ctx, &graphql.ResolverContext{
+ ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{
Object: "Mutation",
})
@@ -12782,7 +12196,7 @@ func (ec *executionContext) _Mutation(ctx context.Context, sel ast.SelectionSet)
var newBugPayloadImplementors = []string{"NewBugPayload"}
func (ec *executionContext) _NewBugPayload(ctx context.Context, sel ast.SelectionSet, obj *models.NewBugPayload) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, newBugPayloadImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, newBugPayloadImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12816,7 +12230,7 @@ func (ec *executionContext) _NewBugPayload(ctx context.Context, sel ast.Selectio
var openBugPayloadImplementors = []string{"OpenBugPayload"}
func (ec *executionContext) _OpenBugPayload(ctx context.Context, sel ast.SelectionSet, obj *models.OpenBugPayload) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, openBugPayloadImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, openBugPayloadImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12850,7 +12264,7 @@ func (ec *executionContext) _OpenBugPayload(ctx context.Context, sel ast.Selecti
var operationConnectionImplementors = []string{"OperationConnection"}
func (ec *executionContext) _OperationConnection(ctx context.Context, sel ast.SelectionSet, obj *models.OperationConnection) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, operationConnectionImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, operationConnectionImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12892,7 +12306,7 @@ func (ec *executionContext) _OperationConnection(ctx context.Context, sel ast.Se
var operationEdgeImplementors = []string{"OperationEdge"}
func (ec *executionContext) _OperationEdge(ctx context.Context, sel ast.SelectionSet, obj *models.OperationEdge) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, operationEdgeImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, operationEdgeImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12924,7 +12338,7 @@ func (ec *executionContext) _OperationEdge(ctx context.Context, sel ast.Selectio
var pageInfoImplementors = []string{"PageInfo"}
func (ec *executionContext) _PageInfo(ctx context.Context, sel ast.SelectionSet, obj *models.PageInfo) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, pageInfoImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, pageInfoImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -12966,9 +12380,9 @@ func (ec *executionContext) _PageInfo(ctx context.Context, sel ast.SelectionSet,
var queryImplementors = []string{"Query"}
func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, queryImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, queryImplementors)
- ctx = graphql.WithResolverContext(ctx, &graphql.ResolverContext{
+ ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{
Object: "Query",
})
@@ -13018,7 +12432,7 @@ func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) gr
var repositoryImplementors = []string{"Repository"}
func (ec *executionContext) _Repository(ctx context.Context, sel ast.SelectionSet, obj *models.Repository) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, repositoryImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, repositoryImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13115,7 +12529,7 @@ func (ec *executionContext) _Repository(ctx context.Context, sel ast.SelectionSe
var setStatusOperationImplementors = []string{"SetStatusOperation", "Operation", "Authored"}
func (ec *executionContext) _SetStatusOperation(ctx context.Context, sel ast.SelectionSet, obj *bug.SetStatusOperation) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, setStatusOperationImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, setStatusOperationImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13138,10 +12552,19 @@ func (ec *executionContext) _SetStatusOperation(ctx context.Context, sel ast.Sel
return res
})
case "author":
- out.Values[i] = ec._SetStatusOperation_author(ctx, field, obj)
- if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
+ field := field
+ out.Concurrently(i, func() (res graphql.Marshaler) {
+ defer func() {
+ if r := recover(); r != nil {
+ ec.Error(ctx, ec.Recover(ctx, r))
+ }
+ }()
+ res = ec._SetStatusOperation_author(ctx, field, obj)
+ if res == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
+ return res
+ })
case "date":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
@@ -13184,7 +12607,7 @@ func (ec *executionContext) _SetStatusOperation(ctx context.Context, sel ast.Sel
var setStatusTimelineItemImplementors = []string{"SetStatusTimelineItem", "TimelineItem", "Authored"}
func (ec *executionContext) _SetStatusTimelineItem(ctx context.Context, sel ast.SelectionSet, obj *bug.SetStatusTimelineItem) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, setStatusTimelineItemImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, setStatusTimelineItemImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13207,10 +12630,19 @@ func (ec *executionContext) _SetStatusTimelineItem(ctx context.Context, sel ast.
return res
})
case "author":
- out.Values[i] = ec._SetStatusTimelineItem_author(ctx, field, obj)
- if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
+ field := field
+ out.Concurrently(i, func() (res graphql.Marshaler) {
+ defer func() {
+ if r := recover(); r != nil {
+ ec.Error(ctx, ec.Recover(ctx, r))
+ }
+ }()
+ res = ec._SetStatusTimelineItem_author(ctx, field, obj)
+ if res == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
+ return res
+ })
case "date":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
@@ -13253,7 +12685,7 @@ func (ec *executionContext) _SetStatusTimelineItem(ctx context.Context, sel ast.
var setTitleOperationImplementors = []string{"SetTitleOperation", "Operation", "Authored"}
func (ec *executionContext) _SetTitleOperation(ctx context.Context, sel ast.SelectionSet, obj *bug.SetTitleOperation) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, setTitleOperationImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, setTitleOperationImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13276,10 +12708,19 @@ func (ec *executionContext) _SetTitleOperation(ctx context.Context, sel ast.Sele
return res
})
case "author":
- out.Values[i] = ec._SetTitleOperation_author(ctx, field, obj)
- if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
+ field := field
+ out.Concurrently(i, func() (res graphql.Marshaler) {
+ defer func() {
+ if r := recover(); r != nil {
+ ec.Error(ctx, ec.Recover(ctx, r))
+ }
+ }()
+ res = ec._SetTitleOperation_author(ctx, field, obj)
+ if res == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
+ return res
+ })
case "date":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
@@ -13318,7 +12759,7 @@ func (ec *executionContext) _SetTitleOperation(ctx context.Context, sel ast.Sele
var setTitlePayloadImplementors = []string{"SetTitlePayload"}
func (ec *executionContext) _SetTitlePayload(ctx context.Context, sel ast.SelectionSet, obj *models.SetTitlePayload) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, setTitlePayloadImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, setTitlePayloadImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13352,7 +12793,7 @@ func (ec *executionContext) _SetTitlePayload(ctx context.Context, sel ast.Select
var setTitleTimelineItemImplementors = []string{"SetTitleTimelineItem", "TimelineItem", "Authored"}
func (ec *executionContext) _SetTitleTimelineItem(ctx context.Context, sel ast.SelectionSet, obj *bug.SetTitleTimelineItem) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, setTitleTimelineItemImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, setTitleTimelineItemImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13375,10 +12816,19 @@ func (ec *executionContext) _SetTitleTimelineItem(ctx context.Context, sel ast.S
return res
})
case "author":
- out.Values[i] = ec._SetTitleTimelineItem_author(ctx, field, obj)
- if out.Values[i] == graphql.Null {
- atomic.AddUint32(&invalids, 1)
- }
+ field := field
+ out.Concurrently(i, func() (res graphql.Marshaler) {
+ defer func() {
+ if r := recover(); r != nil {
+ ec.Error(ctx, ec.Recover(ctx, r))
+ }
+ }()
+ res = ec._SetTitleTimelineItem_author(ctx, field, obj)
+ if res == graphql.Null {
+ atomic.AddUint32(&invalids, 1)
+ }
+ return res
+ })
case "date":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
@@ -13417,7 +12867,7 @@ func (ec *executionContext) _SetTitleTimelineItem(ctx context.Context, sel ast.S
var timelineItemConnectionImplementors = []string{"TimelineItemConnection"}
func (ec *executionContext) _TimelineItemConnection(ctx context.Context, sel ast.SelectionSet, obj *models.TimelineItemConnection) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, timelineItemConnectionImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, timelineItemConnectionImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13459,7 +12909,7 @@ func (ec *executionContext) _TimelineItemConnection(ctx context.Context, sel ast
var timelineItemEdgeImplementors = []string{"TimelineItemEdge"}
func (ec *executionContext) _TimelineItemEdge(ctx context.Context, sel ast.SelectionSet, obj *models.TimelineItemEdge) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, timelineItemEdgeImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, timelineItemEdgeImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13491,7 +12941,7 @@ func (ec *executionContext) _TimelineItemEdge(ctx context.Context, sel ast.Selec
var __DirectiveImplementors = []string{"__Directive"}
func (ec *executionContext) ___Directive(ctx context.Context, sel ast.SelectionSet, obj *introspection.Directive) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, __DirectiveImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, __DirectiveImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13530,7 +12980,7 @@ func (ec *executionContext) ___Directive(ctx context.Context, sel ast.SelectionS
var __EnumValueImplementors = []string{"__EnumValue"}
func (ec *executionContext) ___EnumValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.EnumValue) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, __EnumValueImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, __EnumValueImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13566,7 +13016,7 @@ func (ec *executionContext) ___EnumValue(ctx context.Context, sel ast.SelectionS
var __FieldImplementors = []string{"__Field"}
func (ec *executionContext) ___Field(ctx context.Context, sel ast.SelectionSet, obj *introspection.Field) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, __FieldImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, __FieldImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13612,7 +13062,7 @@ func (ec *executionContext) ___Field(ctx context.Context, sel ast.SelectionSet,
var __InputValueImplementors = []string{"__InputValue"}
func (ec *executionContext) ___InputValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.InputValue) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, __InputValueImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, __InputValueImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13648,7 +13098,7 @@ func (ec *executionContext) ___InputValue(ctx context.Context, sel ast.Selection
var __SchemaImplementors = []string{"__Schema"}
func (ec *executionContext) ___Schema(ctx context.Context, sel ast.SelectionSet, obj *introspection.Schema) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, __SchemaImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, __SchemaImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13689,7 +13139,7 @@ func (ec *executionContext) ___Schema(ctx context.Context, sel ast.SelectionSet,
var __TypeImplementors = []string{"__Type"}
func (ec *executionContext) ___Type(ctx context.Context, sel ast.SelectionSet, obj *introspection.Type) graphql.Marshaler {
- fields := graphql.CollectFields(ec.RequestContext, sel, __TypeImplementors)
+ fields := graphql.CollectFields(ec.OperationContext, sel, __TypeImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
@@ -13743,7 +13193,7 @@ func (ec *executionContext) marshalNAddCommentOperation2githubᚗcomᚋMichaelMu
func (ec *executionContext) marshalNAddCommentOperation2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐAddCommentOperation(ctx context.Context, sel ast.SelectionSet, v *bug.AddCommentOperation) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -13757,7 +13207,7 @@ func (ec *executionContext) marshalNAddCommentPayload2githubᚗcomᚋMichaelMure
func (ec *executionContext) marshalNAddCommentPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐAddCommentPayload(ctx context.Context, sel ast.SelectionSet, v *models.AddCommentPayload) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -13772,18 +13222,24 @@ func (ec *executionContext) unmarshalNBoolean2bool(ctx context.Context, v interf
func (ec *executionContext) marshalNBoolean2bool(ctx context.Context, sel ast.SelectionSet, v bool) graphql.Marshaler {
res := graphql.MarshalBoolean(v)
if res == graphql.Null {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
}
return res
}
-func (ec *executionContext) marshalNBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx context.Context, sel ast.SelectionSet, v bug.Snapshot) graphql.Marshaler {
- return ec._Bug(ctx, sel, &v)
+func (ec *executionContext) marshalNBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapper(ctx context.Context, sel ast.SelectionSet, v models.BugWrapper) graphql.Marshaler {
+ if v == nil {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
+ ec.Errorf(ctx, "must not be null")
+ }
+ return graphql.Null
+ }
+ return ec._Bug(ctx, sel, v)
}
-func (ec *executionContext) marshalNBug2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx context.Context, sel ast.SelectionSet, v []*bug.Snapshot) graphql.Marshaler {
+func (ec *executionContext) marshalNBug2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapperᚄ(ctx context.Context, sel ast.SelectionSet, v []models.BugWrapper) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -13792,11 +13248,11 @@ func (ec *executionContext) marshalNBug2ᚕᚖgithubᚗcomᚋMichaelMureᚋgit
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -13807,7 +13263,7 @@ func (ec *executionContext) marshalNBug2ᚕᚖgithubᚗcomᚋMichaelMureᚋgit
if !isLen1 {
defer wg.Done()
}
- ret[i] = ec.marshalNBug2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx, sel, v[i])
+ ret[i] = ec.marshalNBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapper(ctx, sel, v[i])
}
if isLen1 {
f(i)
@@ -13820,23 +13276,13 @@ func (ec *executionContext) marshalNBug2ᚕᚖgithubᚗcomᚋMichaelMureᚋgit
return ret
}
-func (ec *executionContext) marshalNBug2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx context.Context, sel ast.SelectionSet, v *bug.Snapshot) graphql.Marshaler {
- if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
- ec.Errorf(ctx, "must not be null")
- }
- return graphql.Null
- }
- return ec._Bug(ctx, sel, v)
-}
-
func (ec *executionContext) marshalNBugConnection2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugConnection(ctx context.Context, sel ast.SelectionSet, v models.BugConnection) graphql.Marshaler {
return ec._BugConnection(ctx, sel, &v)
}
func (ec *executionContext) marshalNBugConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugConnection(ctx context.Context, sel ast.SelectionSet, v *models.BugConnection) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -13848,7 +13294,7 @@ func (ec *executionContext) marshalNBugEdge2githubᚗcomᚋMichaelMureᚋgitᚑb
return ec._BugEdge(ctx, sel, &v)
}
-func (ec *executionContext) marshalNBugEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugEdge(ctx context.Context, sel ast.SelectionSet, v []*models.BugEdge) graphql.Marshaler {
+func (ec *executionContext) marshalNBugEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugEdgeᚄ(ctx context.Context, sel ast.SelectionSet, v []*models.BugEdge) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -13857,11 +13303,11 @@ func (ec *executionContext) marshalNBugEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋg
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -13887,7 +13333,7 @@ func (ec *executionContext) marshalNBugEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋg
func (ec *executionContext) marshalNBugEdge2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugEdge(ctx context.Context, sel ast.SelectionSet, v *models.BugEdge) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -13901,7 +13347,7 @@ func (ec *executionContext) marshalNChangeLabelPayload2githubᚗcomᚋMichaelMur
func (ec *executionContext) marshalNChangeLabelPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐChangeLabelPayload(ctx context.Context, sel ast.SelectionSet, v *models.ChangeLabelPayload) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -13919,7 +13365,7 @@ func (ec *executionContext) marshalNCloseBugPayload2githubᚗcomᚋMichaelMure
func (ec *executionContext) marshalNCloseBugPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐCloseBugPayload(ctx context.Context, sel ast.SelectionSet, v *models.CloseBugPayload) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -13933,7 +13379,7 @@ func (ec *executionContext) marshalNColor2imageᚋcolorᚐRGBA(ctx context.Conte
func (ec *executionContext) marshalNColor2ᚖimageᚋcolorᚐRGBA(ctx context.Context, sel ast.SelectionSet, v *color.RGBA) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -13945,7 +13391,7 @@ func (ec *executionContext) marshalNComment2githubᚗcomᚋMichaelMureᚋgitᚑb
return ec._Comment(ctx, sel, &v)
}
-func (ec *executionContext) marshalNComment2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐComment(ctx context.Context, sel ast.SelectionSet, v []*bug.Comment) graphql.Marshaler {
+func (ec *executionContext) marshalNComment2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐCommentᚄ(ctx context.Context, sel ast.SelectionSet, v []*bug.Comment) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -13954,11 +13400,11 @@ func (ec *executionContext) marshalNComment2ᚕᚖgithubᚗcomᚋMichaelMureᚋg
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -13984,7 +13430,7 @@ func (ec *executionContext) marshalNComment2ᚕᚖgithubᚗcomᚋMichaelMureᚋg
func (ec *executionContext) marshalNComment2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐComment(ctx context.Context, sel ast.SelectionSet, v *bug.Comment) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -13998,7 +13444,7 @@ func (ec *executionContext) marshalNCommentConnection2githubᚗcomᚋMichaelMure
func (ec *executionContext) marshalNCommentConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐCommentConnection(ctx context.Context, sel ast.SelectionSet, v *models.CommentConnection) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14010,7 +13456,7 @@ func (ec *executionContext) marshalNCommentEdge2githubᚗcomᚋMichaelMureᚋgit
return ec._CommentEdge(ctx, sel, &v)
}
-func (ec *executionContext) marshalNCommentEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐCommentEdge(ctx context.Context, sel ast.SelectionSet, v []*models.CommentEdge) graphql.Marshaler {
+func (ec *executionContext) marshalNCommentEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐCommentEdgeᚄ(ctx context.Context, sel ast.SelectionSet, v []*models.CommentEdge) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -14019,11 +13465,11 @@ func (ec *executionContext) marshalNCommentEdge2ᚕᚖgithubᚗcomᚋMichaelMure
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14049,7 +13495,7 @@ func (ec *executionContext) marshalNCommentEdge2ᚕᚖgithubᚗcomᚋMichaelMure
func (ec *executionContext) marshalNCommentEdge2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐCommentEdge(ctx context.Context, sel ast.SelectionSet, v *models.CommentEdge) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14061,7 +13507,7 @@ func (ec *executionContext) marshalNCommentHistoryStep2githubᚗcomᚋMichaelMur
return ec._CommentHistoryStep(ctx, sel, &v)
}
-func (ec *executionContext) marshalNCommentHistoryStep2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐCommentHistoryStep(ctx context.Context, sel ast.SelectionSet, v []bug.CommentHistoryStep) graphql.Marshaler {
+func (ec *executionContext) marshalNCommentHistoryStep2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐCommentHistoryStepᚄ(ctx context.Context, sel ast.SelectionSet, v []bug.CommentHistoryStep) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -14070,11 +13516,11 @@ func (ec *executionContext) marshalNCommentHistoryStep2ᚕgithubᚗcomᚋMichael
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14108,7 +13554,7 @@ func (ec *executionContext) marshalNCommitAsNeededPayload2githubᚗcomᚋMichael
func (ec *executionContext) marshalNCommitAsNeededPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐCommitAsNeededPayload(ctx context.Context, sel ast.SelectionSet, v *models.CommitAsNeededPayload) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14126,7 +13572,7 @@ func (ec *executionContext) marshalNCommitPayload2githubᚗcomᚋMichaelMureᚋg
func (ec *executionContext) marshalNCommitPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐCommitPayload(ctx context.Context, sel ast.SelectionSet, v *models.CommitPayload) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14140,7 +13586,7 @@ func (ec *executionContext) marshalNCreateOperation2githubᚗcomᚋMichaelMure
func (ec *executionContext) marshalNCreateOperation2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐCreateOperation(ctx context.Context, sel ast.SelectionSet, v *bug.CreateOperation) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14157,7 +13603,7 @@ func (ec *executionContext) marshalNHash2githubᚗcomᚋMichaelMureᚋgitᚑbug
return v
}
-func (ec *executionContext) unmarshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHash(ctx context.Context, v interface{}) ([]git.Hash, error) {
+func (ec *executionContext) unmarshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHashᚄ(ctx context.Context, v interface{}) ([]git.Hash, error) {
var vSlice []interface{}
if v != nil {
if tmp1, ok := v.([]interface{}); ok {
@@ -14177,7 +13623,7 @@ func (ec *executionContext) unmarshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgit
return res, nil
}
-func (ec *executionContext) marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHash(ctx context.Context, sel ast.SelectionSet, v []git.Hash) graphql.Marshaler {
+func (ec *executionContext) marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHashᚄ(ctx context.Context, sel ast.SelectionSet, v []git.Hash) graphql.Marshaler {
ret := make(graphql.Array, len(v))
for i := range v {
ret[i] = ec.marshalNHash2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHash(ctx, sel, v[i])
@@ -14186,11 +13632,17 @@ func (ec *executionContext) marshalNHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑb
return ret
}
-func (ec *executionContext) marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx context.Context, sel ast.SelectionSet, v identity.Interface) graphql.Marshaler {
- return ec._Identity(ctx, sel, &v)
+func (ec *executionContext) marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx context.Context, sel ast.SelectionSet, v models.IdentityWrapper) graphql.Marshaler {
+ if v == nil {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
+ ec.Errorf(ctx, "must not be null")
+ }
+ return graphql.Null
+ }
+ return ec._Identity(ctx, sel, v)
}
-func (ec *executionContext) marshalNIdentity2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx context.Context, sel ast.SelectionSet, v []identity.Interface) graphql.Marshaler {
+func (ec *executionContext) marshalNIdentity2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapperᚄ(ctx context.Context, sel ast.SelectionSet, v []models.IdentityWrapper) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -14199,11 +13651,11 @@ func (ec *executionContext) marshalNIdentity2ᚕgithubᚗcomᚋMichaelMureᚋgit
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14214,7 +13666,7 @@ func (ec *executionContext) marshalNIdentity2ᚕgithubᚗcomᚋMichaelMureᚋgit
if !isLen1 {
defer wg.Done()
}
- ret[i] = ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx, sel, v[i])
+ ret[i] = ec.marshalNIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx, sel, v[i])
}
if isLen1 {
f(i)
@@ -14233,7 +13685,7 @@ func (ec *executionContext) marshalNIdentityConnection2githubᚗcomᚋMichaelMur
func (ec *executionContext) marshalNIdentityConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityConnection(ctx context.Context, sel ast.SelectionSet, v *models.IdentityConnection) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14245,7 +13697,7 @@ func (ec *executionContext) marshalNIdentityEdge2githubᚗcomᚋMichaelMureᚋgi
return ec._IdentityEdge(ctx, sel, &v)
}
-func (ec *executionContext) marshalNIdentityEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityEdge(ctx context.Context, sel ast.SelectionSet, v []*models.IdentityEdge) graphql.Marshaler {
+func (ec *executionContext) marshalNIdentityEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityEdgeᚄ(ctx context.Context, sel ast.SelectionSet, v []*models.IdentityEdge) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -14254,11 +13706,11 @@ func (ec *executionContext) marshalNIdentityEdge2ᚕᚖgithubᚗcomᚋMichaelMur
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14284,7 +13736,7 @@ func (ec *executionContext) marshalNIdentityEdge2ᚕᚖgithubᚗcomᚋMichaelMur
func (ec *executionContext) marshalNIdentityEdge2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityEdge(ctx context.Context, sel ast.SelectionSet, v *models.IdentityEdge) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14299,7 +13751,7 @@ func (ec *executionContext) unmarshalNInt2int(ctx context.Context, v interface{}
func (ec *executionContext) marshalNInt2int(ctx context.Context, sel ast.SelectionSet, v int) graphql.Marshaler {
res := graphql.MarshalInt(v)
if res == graphql.Null {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
}
@@ -14310,7 +13762,7 @@ func (ec *executionContext) marshalNLabel2githubᚗcomᚋMichaelMureᚋgitᚑbug
return ec._Label(ctx, sel, &v)
}
-func (ec *executionContext) marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabel(ctx context.Context, sel ast.SelectionSet, v []bug.Label) graphql.Marshaler {
+func (ec *executionContext) marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabelᚄ(ctx context.Context, sel ast.SelectionSet, v []bug.Label) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -14319,11 +13771,11 @@ func (ec *executionContext) marshalNLabel2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑ
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14353,7 +13805,7 @@ func (ec *executionContext) marshalNLabelChangeOperation2githubᚗcomᚋMichaelM
func (ec *executionContext) marshalNLabelChangeOperation2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐLabelChangeOperation(ctx context.Context, sel ast.SelectionSet, v *bug.LabelChangeOperation) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14370,11 +13822,11 @@ func (ec *executionContext) marshalNLabelChangeResult2ᚕᚖgithubᚗcomᚋMicha
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14413,7 +13865,7 @@ func (ec *executionContext) marshalNLabelConnection2githubᚗcomᚋMichaelMure
func (ec *executionContext) marshalNLabelConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐLabelConnection(ctx context.Context, sel ast.SelectionSet, v *models.LabelConnection) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14425,7 +13877,7 @@ func (ec *executionContext) marshalNLabelEdge2githubᚗcomᚋMichaelMureᚋgit
return ec._LabelEdge(ctx, sel, &v)
}
-func (ec *executionContext) marshalNLabelEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐLabelEdge(ctx context.Context, sel ast.SelectionSet, v []*models.LabelEdge) graphql.Marshaler {
+func (ec *executionContext) marshalNLabelEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐLabelEdgeᚄ(ctx context.Context, sel ast.SelectionSet, v []*models.LabelEdge) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -14434,11 +13886,11 @@ func (ec *executionContext) marshalNLabelEdge2ᚕᚖgithubᚗcomᚋMichaelMure
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14464,7 +13916,7 @@ func (ec *executionContext) marshalNLabelEdge2ᚕᚖgithubᚗcomᚋMichaelMure
func (ec *executionContext) marshalNLabelEdge2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐLabelEdge(ctx context.Context, sel ast.SelectionSet, v *models.LabelEdge) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14482,7 +13934,7 @@ func (ec *executionContext) marshalNNewBugPayload2githubᚗcomᚋMichaelMureᚋg
func (ec *executionContext) marshalNNewBugPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐNewBugPayload(ctx context.Context, sel ast.SelectionSet, v *models.NewBugPayload) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14500,7 +13952,7 @@ func (ec *executionContext) marshalNOpenBugPayload2githubᚗcomᚋMichaelMureᚋ
func (ec *executionContext) marshalNOpenBugPayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐOpenBugPayload(ctx context.Context, sel ast.SelectionSet, v *models.OpenBugPayload) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14509,10 +13961,16 @@ func (ec *executionContext) marshalNOpenBugPayload2ᚖgithubᚗcomᚋMichaelMure
}
func (ec *executionContext) marshalNOperation2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐOperation(ctx context.Context, sel ast.SelectionSet, v bug.Operation) graphql.Marshaler {
- return ec._Operation(ctx, sel, &v)
+ if v == nil {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
+ ec.Errorf(ctx, "must not be null")
+ }
+ return graphql.Null
+ }
+ return ec._Operation(ctx, sel, v)
}
-func (ec *executionContext) marshalNOperation2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐOperation(ctx context.Context, sel ast.SelectionSet, v []bug.Operation) graphql.Marshaler {
+func (ec *executionContext) marshalNOperation2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐOperationᚄ(ctx context.Context, sel ast.SelectionSet, v []bug.Operation) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -14521,11 +13979,11 @@ func (ec *executionContext) marshalNOperation2ᚕgithubᚗcomᚋMichaelMureᚋgi
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14555,7 +14013,7 @@ func (ec *executionContext) marshalNOperationConnection2githubᚗcomᚋMichaelMu
func (ec *executionContext) marshalNOperationConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐOperationConnection(ctx context.Context, sel ast.SelectionSet, v *models.OperationConnection) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14567,7 +14025,7 @@ func (ec *executionContext) marshalNOperationEdge2githubᚗcomᚋMichaelMureᚋg
return ec._OperationEdge(ctx, sel, &v)
}
-func (ec *executionContext) marshalNOperationEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐOperationEdge(ctx context.Context, sel ast.SelectionSet, v []*models.OperationEdge) graphql.Marshaler {
+func (ec *executionContext) marshalNOperationEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐOperationEdgeᚄ(ctx context.Context, sel ast.SelectionSet, v []*models.OperationEdge) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -14576,11 +14034,11 @@ func (ec *executionContext) marshalNOperationEdge2ᚕᚖgithubᚗcomᚋMichaelMu
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14606,7 +14064,7 @@ func (ec *executionContext) marshalNOperationEdge2ᚕᚖgithubᚗcomᚋMichaelMu
func (ec *executionContext) marshalNOperationEdge2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐOperationEdge(ctx context.Context, sel ast.SelectionSet, v *models.OperationEdge) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14620,7 +14078,7 @@ func (ec *executionContext) marshalNPageInfo2githubᚗcomᚋMichaelMureᚋgitᚑ
func (ec *executionContext) marshalNPageInfo2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐPageInfo(ctx context.Context, sel ast.SelectionSet, v *models.PageInfo) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14634,7 +14092,7 @@ func (ec *executionContext) marshalNSetStatusOperation2githubᚗcomᚋMichaelMur
func (ec *executionContext) marshalNSetStatusOperation2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSetStatusOperation(ctx context.Context, sel ast.SelectionSet, v *bug.SetStatusOperation) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14652,7 +14110,7 @@ func (ec *executionContext) marshalNSetTitleOperation2githubᚗcomᚋMichaelMure
func (ec *executionContext) marshalNSetTitleOperation2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSetTitleOperation(ctx context.Context, sel ast.SelectionSet, v *bug.SetTitleOperation) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14666,7 +14124,7 @@ func (ec *executionContext) marshalNSetTitlePayload2githubᚗcomᚋMichaelMure
func (ec *executionContext) marshalNSetTitlePayload2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐSetTitlePayload(ctx context.Context, sel ast.SelectionSet, v *models.SetTitlePayload) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14690,7 +14148,7 @@ func (ec *executionContext) unmarshalNString2string(ctx context.Context, v inter
func (ec *executionContext) marshalNString2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler {
res := graphql.MarshalString(v)
if res == graphql.Null {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
}
@@ -14704,7 +14162,7 @@ func (ec *executionContext) unmarshalNTime2timeᚐTime(ctx context.Context, v in
func (ec *executionContext) marshalNTime2timeᚐTime(ctx context.Context, sel ast.SelectionSet, v time.Time) graphql.Marshaler {
res := graphql.MarshalTime(v)
if res == graphql.Null {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
}
@@ -14721,7 +14179,7 @@ func (ec *executionContext) unmarshalNTime2ᚖtimeᚐTime(ctx context.Context, v
func (ec *executionContext) marshalNTime2ᚖtimeᚐTime(ctx context.Context, sel ast.SelectionSet, v *time.Time) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14730,10 +14188,16 @@ func (ec *executionContext) marshalNTime2ᚖtimeᚐTime(ctx context.Context, sel
}
func (ec *executionContext) marshalNTimelineItem2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐTimelineItem(ctx context.Context, sel ast.SelectionSet, v bug.TimelineItem) graphql.Marshaler {
- return ec._TimelineItem(ctx, sel, &v)
+ if v == nil {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
+ ec.Errorf(ctx, "must not be null")
+ }
+ return graphql.Null
+ }
+ return ec._TimelineItem(ctx, sel, v)
}
-func (ec *executionContext) marshalNTimelineItem2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐTimelineItem(ctx context.Context, sel ast.SelectionSet, v []bug.TimelineItem) graphql.Marshaler {
+func (ec *executionContext) marshalNTimelineItem2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐTimelineItemᚄ(ctx context.Context, sel ast.SelectionSet, v []bug.TimelineItem) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -14742,11 +14206,11 @@ func (ec *executionContext) marshalNTimelineItem2ᚕgithubᚗcomᚋMichaelMure
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14776,7 +14240,7 @@ func (ec *executionContext) marshalNTimelineItemConnection2githubᚗcomᚋMichae
func (ec *executionContext) marshalNTimelineItemConnection2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐTimelineItemConnection(ctx context.Context, sel ast.SelectionSet, v *models.TimelineItemConnection) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14788,7 +14252,7 @@ func (ec *executionContext) marshalNTimelineItemEdge2githubᚗcomᚋMichaelMure
return ec._TimelineItemEdge(ctx, sel, &v)
}
-func (ec *executionContext) marshalNTimelineItemEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐTimelineItemEdge(ctx context.Context, sel ast.SelectionSet, v []*models.TimelineItemEdge) graphql.Marshaler {
+func (ec *executionContext) marshalNTimelineItemEdge2ᚕᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐTimelineItemEdgeᚄ(ctx context.Context, sel ast.SelectionSet, v []*models.TimelineItemEdge) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -14797,11 +14261,11 @@ func (ec *executionContext) marshalNTimelineItemEdge2ᚕᚖgithubᚗcomᚋMichae
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14827,7 +14291,7 @@ func (ec *executionContext) marshalNTimelineItemEdge2ᚕᚖgithubᚗcomᚋMichae
func (ec *executionContext) marshalNTimelineItemEdge2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐTimelineItemEdge(ctx context.Context, sel ast.SelectionSet, v *models.TimelineItemEdge) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -14835,11 +14299,11 @@ func (ec *executionContext) marshalNTimelineItemEdge2ᚖgithubᚗcomᚋMichaelMu
return ec._TimelineItemEdge(ctx, sel, v)
}
-func (ec *executionContext) marshalN__Directive2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx context.Context, sel ast.SelectionSet, v introspection.Directive) graphql.Marshaler {
+func (ec *executionContext) marshalN__Directive2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx context.Context, sel ast.SelectionSet, v introspection.Directive) graphql.Marshaler {
return ec.___Directive(ctx, sel, &v)
}
-func (ec *executionContext) marshalN__Directive2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx context.Context, sel ast.SelectionSet, v []introspection.Directive) graphql.Marshaler {
+func (ec *executionContext) marshalN__Directive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirectiveᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Directive) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -14848,11 +14312,11 @@ func (ec *executionContext) marshalN__Directive2ᚕgithubᚗcomᚋMichaelMureᚋ
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14863,7 +14327,7 @@ func (ec *executionContext) marshalN__Directive2ᚕgithubᚗcomᚋMichaelMureᚋ
if !isLen1 {
defer wg.Done()
}
- ret[i] = ec.marshalN__Directive2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx, sel, v[i])
+ ret[i] = ec.marshalN__Directive2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx, sel, v[i])
}
if isLen1 {
f(i)
@@ -14883,14 +14347,14 @@ func (ec *executionContext) unmarshalN__DirectiveLocation2string(ctx context.Con
func (ec *executionContext) marshalN__DirectiveLocation2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler {
res := graphql.MarshalString(v)
if res == graphql.Null {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
}
return res
}
-func (ec *executionContext) unmarshalN__DirectiveLocation2ᚕstring(ctx context.Context, v interface{}) ([]string, error) {
+func (ec *executionContext) unmarshalN__DirectiveLocation2ᚕstringᚄ(ctx context.Context, v interface{}) ([]string, error) {
var vSlice []interface{}
if v != nil {
if tmp1, ok := v.([]interface{}); ok {
@@ -14910,7 +14374,7 @@ func (ec *executionContext) unmarshalN__DirectiveLocation2ᚕstring(ctx context.
return res, nil
}
-func (ec *executionContext) marshalN__DirectiveLocation2ᚕstring(ctx context.Context, sel ast.SelectionSet, v []string) graphql.Marshaler {
+func (ec *executionContext) marshalN__DirectiveLocation2ᚕstringᚄ(ctx context.Context, sel ast.SelectionSet, v []string) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -14919,11 +14383,11 @@ func (ec *executionContext) marshalN__DirectiveLocation2ᚕstring(ctx context.Co
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14947,19 +14411,19 @@ func (ec *executionContext) marshalN__DirectiveLocation2ᚕstring(ctx context.Co
return ret
}
-func (ec *executionContext) marshalN__EnumValue2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx context.Context, sel ast.SelectionSet, v introspection.EnumValue) graphql.Marshaler {
+func (ec *executionContext) marshalN__EnumValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx context.Context, sel ast.SelectionSet, v introspection.EnumValue) graphql.Marshaler {
return ec.___EnumValue(ctx, sel, &v)
}
-func (ec *executionContext) marshalN__Field2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx context.Context, sel ast.SelectionSet, v introspection.Field) graphql.Marshaler {
+func (ec *executionContext) marshalN__Field2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx context.Context, sel ast.SelectionSet, v introspection.Field) graphql.Marshaler {
return ec.___Field(ctx, sel, &v)
}
-func (ec *executionContext) marshalN__InputValue2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx context.Context, sel ast.SelectionSet, v introspection.InputValue) graphql.Marshaler {
+func (ec *executionContext) marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx context.Context, sel ast.SelectionSet, v introspection.InputValue) graphql.Marshaler {
return ec.___InputValue(ctx, sel, &v)
}
-func (ec *executionContext) marshalN__InputValue2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler {
+func (ec *executionContext) marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -14968,11 +14432,11 @@ func (ec *executionContext) marshalN__InputValue2ᚕgithubᚗcomᚋMichaelMure
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -14983,7 +14447,7 @@ func (ec *executionContext) marshalN__InputValue2ᚕgithubᚗcomᚋMichaelMure
if !isLen1 {
defer wg.Done()
}
- ret[i] = ec.marshalN__InputValue2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i])
+ ret[i] = ec.marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i])
}
if isLen1 {
f(i)
@@ -14996,11 +14460,11 @@ func (ec *executionContext) marshalN__InputValue2ᚕgithubᚗcomᚋMichaelMure
return ret
}
-func (ec *executionContext) marshalN__Type2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v introspection.Type) graphql.Marshaler {
+func (ec *executionContext) marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v introspection.Type) graphql.Marshaler {
return ec.___Type(ctx, sel, &v)
}
-func (ec *executionContext) marshalN__Type2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler {
+func (ec *executionContext) marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
@@ -15009,11 +14473,11 @@ func (ec *executionContext) marshalN__Type2ᚕgithubᚗcomᚋMichaelMureᚋgit
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -15024,7 +14488,7 @@ func (ec *executionContext) marshalN__Type2ᚕgithubᚗcomᚋMichaelMureᚋgit
if !isLen1 {
defer wg.Done()
}
- ret[i] = ec.marshalN__Type2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i])
+ ret[i] = ec.marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i])
}
if isLen1 {
f(i)
@@ -15037,9 +14501,9 @@ func (ec *executionContext) marshalN__Type2ᚕgithubᚗcomᚋMichaelMureᚋgit
return ret
}
-func (ec *executionContext) marshalN__Type2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
+func (ec *executionContext) marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
if v == nil {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
@@ -15054,7 +14518,7 @@ func (ec *executionContext) unmarshalN__TypeKind2string(ctx context.Context, v i
func (ec *executionContext) marshalN__TypeKind2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler {
res := graphql.MarshalString(v)
if res == graphql.Null {
- if !ec.HasError(graphql.GetResolverContext(ctx)) {
+ if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
}
@@ -15084,11 +14548,7 @@ func (ec *executionContext) marshalOBoolean2ᚖbool(ctx context.Context, sel ast
return ec.marshalOBoolean2bool(ctx, sel, *v)
}
-func (ec *executionContext) marshalOBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx context.Context, sel ast.SelectionSet, v bug.Snapshot) graphql.Marshaler {
- return ec._Bug(ctx, sel, &v)
-}
-
-func (ec *executionContext) marshalOBug2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋbugᚐSnapshot(ctx context.Context, sel ast.SelectionSet, v *bug.Snapshot) graphql.Marshaler {
+func (ec *executionContext) marshalOBug2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐBugWrapper(ctx context.Context, sel ast.SelectionSet, v models.BugWrapper) graphql.Marshaler {
if v == nil {
return graphql.Null
}
@@ -15107,7 +14567,7 @@ func (ec *executionContext) unmarshalOChangeLabelInput2ᚖgithubᚗcomᚋMichael
return &res, err
}
-func (ec *executionContext) unmarshalOHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHash(ctx context.Context, v interface{}) ([]git.Hash, error) {
+func (ec *executionContext) unmarshalOHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHashᚄ(ctx context.Context, v interface{}) ([]git.Hash, error) {
var vSlice []interface{}
if v != nil {
if tmp1, ok := v.([]interface{}); ok {
@@ -15127,7 +14587,7 @@ func (ec *executionContext) unmarshalOHash2ᚕgithubᚗcomᚋMichaelMureᚋgit
return res, nil
}
-func (ec *executionContext) marshalOHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHash(ctx context.Context, sel ast.SelectionSet, v []git.Hash) graphql.Marshaler {
+func (ec *executionContext) marshalOHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋutilᚋgitᚐHashᚄ(ctx context.Context, sel ast.SelectionSet, v []git.Hash) graphql.Marshaler {
if v == nil {
return graphql.Null
}
@@ -15139,8 +14599,11 @@ func (ec *executionContext) marshalOHash2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑb
return ret
}
-func (ec *executionContext) marshalOIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋidentityᚐInterface(ctx context.Context, sel ast.SelectionSet, v identity.Interface) graphql.Marshaler {
- return ec._Identity(ctx, sel, &v)
+func (ec *executionContext) marshalOIdentity2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋgraphqlᚋmodelsᚐIdentityWrapper(ctx context.Context, sel ast.SelectionSet, v models.IdentityWrapper) graphql.Marshaler {
+ if v == nil {
+ return graphql.Null
+ }
+ return ec._Identity(ctx, sel, v)
}
func (ec *executionContext) unmarshalOInt2int(ctx context.Context, v interface{}) (int, error) {
@@ -15196,7 +14659,7 @@ func (ec *executionContext) marshalOString2string(ctx context.Context, sel ast.S
return graphql.MarshalString(v)
}
-func (ec *executionContext) unmarshalOString2ᚕstring(ctx context.Context, v interface{}) ([]string, error) {
+func (ec *executionContext) unmarshalOString2ᚕstringᚄ(ctx context.Context, v interface{}) ([]string, error) {
var vSlice []interface{}
if v != nil {
if tmp1, ok := v.([]interface{}); ok {
@@ -15216,7 +14679,7 @@ func (ec *executionContext) unmarshalOString2ᚕstring(ctx context.Context, v in
return res, nil
}
-func (ec *executionContext) marshalOString2ᚕstring(ctx context.Context, sel ast.SelectionSet, v []string) graphql.Marshaler {
+func (ec *executionContext) marshalOString2ᚕstringᚄ(ctx context.Context, sel ast.SelectionSet, v []string) graphql.Marshaler {
if v == nil {
return graphql.Null
}
@@ -15243,7 +14706,7 @@ func (ec *executionContext) marshalOString2ᚖstring(ctx context.Context, sel as
return ec.marshalOString2string(ctx, sel, *v)
}
-func (ec *executionContext) marshalO__EnumValue2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx context.Context, sel ast.SelectionSet, v []introspection.EnumValue) graphql.Marshaler {
+func (ec *executionContext) marshalO__EnumValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.EnumValue) graphql.Marshaler {
if v == nil {
return graphql.Null
}
@@ -15255,11 +14718,11 @@ func (ec *executionContext) marshalO__EnumValue2ᚕgithubᚗcomᚋMichaelMureᚋ
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -15270,7 +14733,7 @@ func (ec *executionContext) marshalO__EnumValue2ᚕgithubᚗcomᚋMichaelMureᚋ
if !isLen1 {
defer wg.Done()
}
- ret[i] = ec.marshalN__EnumValue2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx, sel, v[i])
+ ret[i] = ec.marshalN__EnumValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx, sel, v[i])
}
if isLen1 {
f(i)
@@ -15283,7 +14746,7 @@ func (ec *executionContext) marshalO__EnumValue2ᚕgithubᚗcomᚋMichaelMureᚋ
return ret
}
-func (ec *executionContext) marshalO__Field2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx context.Context, sel ast.SelectionSet, v []introspection.Field) graphql.Marshaler {
+func (ec *executionContext) marshalO__Field2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐFieldᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Field) graphql.Marshaler {
if v == nil {
return graphql.Null
}
@@ -15295,11 +14758,11 @@ func (ec *executionContext) marshalO__Field2ᚕgithubᚗcomᚋMichaelMureᚋgit
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -15310,7 +14773,7 @@ func (ec *executionContext) marshalO__Field2ᚕgithubᚗcomᚋMichaelMureᚋgit
if !isLen1 {
defer wg.Done()
}
- ret[i] = ec.marshalN__Field2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx, sel, v[i])
+ ret[i] = ec.marshalN__Field2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx, sel, v[i])
}
if isLen1 {
f(i)
@@ -15323,7 +14786,7 @@ func (ec *executionContext) marshalO__Field2ᚕgithubᚗcomᚋMichaelMureᚋgit
return ret
}
-func (ec *executionContext) marshalO__InputValue2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler {
+func (ec *executionContext) marshalO__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler {
if v == nil {
return graphql.Null
}
@@ -15335,11 +14798,11 @@ func (ec *executionContext) marshalO__InputValue2ᚕgithubᚗcomᚋMichaelMure
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -15350,7 +14813,7 @@ func (ec *executionContext) marshalO__InputValue2ᚕgithubᚗcomᚋMichaelMure
if !isLen1 {
defer wg.Done()
}
- ret[i] = ec.marshalN__InputValue2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i])
+ ret[i] = ec.marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i])
}
if isLen1 {
f(i)
@@ -15363,22 +14826,22 @@ func (ec *executionContext) marshalO__InputValue2ᚕgithubᚗcomᚋMichaelMure
return ret
}
-func (ec *executionContext) marshalO__Schema2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx context.Context, sel ast.SelectionSet, v introspection.Schema) graphql.Marshaler {
+func (ec *executionContext) marshalO__Schema2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx context.Context, sel ast.SelectionSet, v introspection.Schema) graphql.Marshaler {
return ec.___Schema(ctx, sel, &v)
}
-func (ec *executionContext) marshalO__Schema2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx context.Context, sel ast.SelectionSet, v *introspection.Schema) graphql.Marshaler {
+func (ec *executionContext) marshalO__Schema2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx context.Context, sel ast.SelectionSet, v *introspection.Schema) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return ec.___Schema(ctx, sel, v)
}
-func (ec *executionContext) marshalO__Type2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v introspection.Type) graphql.Marshaler {
+func (ec *executionContext) marshalO__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v introspection.Type) graphql.Marshaler {
return ec.___Type(ctx, sel, &v)
}
-func (ec *executionContext) marshalO__Type2ᚕgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler {
+func (ec *executionContext) marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler {
if v == nil {
return graphql.Null
}
@@ -15390,11 +14853,11 @@ func (ec *executionContext) marshalO__Type2ᚕgithubᚗcomᚋMichaelMureᚋgit
}
for i := range v {
i := i
- rctx := &graphql.ResolverContext{
+ fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
- ctx := graphql.WithResolverContext(ctx, rctx)
+ ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
@@ -15405,7 +14868,7 @@ func (ec *executionContext) marshalO__Type2ᚕgithubᚗcomᚋMichaelMureᚋgit
if !isLen1 {
defer wg.Done()
}
- ret[i] = ec.marshalN__Type2githubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i])
+ ret[i] = ec.marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i])
}
if isLen1 {
f(i)
@@ -15418,7 +14881,7 @@ func (ec *executionContext) marshalO__Type2ᚕgithubᚗcomᚋMichaelMureᚋgit
return ret
}
-func (ec *executionContext) marshalO__Type2ᚖgithubᚗcomᚋMichaelMureᚋgitᚑbugᚋvendorᚋgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
+func (ec *executionContext) marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
if v == nil {
return graphql.Null
}
diff --git a/graphql/graphql_test.go b/graphql/graphql_test.go
index 6784df96..4bab7f58 100644
--- a/graphql/graphql_test.go
+++ b/graphql/graphql_test.go
@@ -1,10 +1,9 @@
package graphql
import (
- "net/http/httptest"
"testing"
- "github.com/vektah/gqlgen/client"
+ "github.com/99designs/gqlgen/client"
"github.com/MichaelMure/git-bug/graphql/models"
"github.com/MichaelMure/git-bug/misc/random_bugs"
@@ -22,8 +21,7 @@ func TestQueries(t *testing.T) {
t.Fatal(err)
}
- srv := httptest.NewServer(handler)
- c := client.New(srv.URL)
+ c := client.New(handler)
query := `
query {
diff --git a/graphql/handler.go b/graphql/handler.go
index aadcf4cb..55ef6fc4 100644
--- a/graphql/handler.go
+++ b/graphql/handler.go
@@ -6,7 +6,8 @@ package graphql
import (
"net/http"
- "github.com/99designs/gqlgen/handler"
+ "github.com/99designs/gqlgen/graphql/handler"
+
"github.com/MichaelMure/git-bug/graphql/graph"
"github.com/MichaelMure/git-bug/graphql/resolvers"
"github.com/MichaelMure/git-bug/repository"
@@ -14,7 +15,7 @@ import (
// Handler is the root GraphQL http handler
type Handler struct {
- http.HandlerFunc
+ http.Handler
*resolvers.RootResolver
}
@@ -32,7 +33,7 @@ func NewHandler(repo repository.ClockedRepo) (Handler, error) {
Resolvers: h.RootResolver,
}
- h.HandlerFunc = handler.GraphQL(graph.NewExecutableSchema(config))
+ h.Handler = handler.NewDefaultServer(graph.NewExecutableSchema(config))
return h, nil
}
diff --git a/graphql/models/gen_models.go b/graphql/models/gen_models.go
index 5498960b..b3e14655 100644
--- a/graphql/models/gen_models.go
+++ b/graphql/models/gen_models.go
@@ -8,7 +8,6 @@ import (
"strconv"
"github.com/MichaelMure/git-bug/bug"
- "github.com/MichaelMure/git-bug/identity"
"github.com/MichaelMure/git-bug/util/git"
)
@@ -34,7 +33,7 @@ type AddCommentPayload struct {
// A unique identifier for the client performing the mutation.
ClientMutationID *string `json:"clientMutationId"`
// The affected bug.
- Bug *bug.Snapshot `json:"bug"`
+ Bug BugWrapper `json:"bug"`
// The resulting operation.
Operation *bug.AddCommentOperation `json:"operation"`
}
@@ -42,8 +41,8 @@ type AddCommentPayload struct {
// The connection type for Bug.
type BugConnection struct {
// A list of edges.
- Edges []*BugEdge `json:"edges"`
- Nodes []*bug.Snapshot `json:"nodes"`
+ Edges []*BugEdge `json:"edges"`
+ Nodes []BugWrapper `json:"nodes"`
// Information to aid in pagination.
PageInfo *PageInfo `json:"pageInfo"`
// Identifies the total count of items in the connection.
@@ -55,7 +54,7 @@ type BugEdge struct {
// A cursor for use in pagination.
Cursor string `json:"cursor"`
// The item at the end of the edge.
- Node *bug.Snapshot `json:"node"`
+ Node BugWrapper `json:"node"`
}
type ChangeLabelInput struct {
@@ -75,7 +74,7 @@ type ChangeLabelPayload struct {
// A unique identifier for the client performing the mutation.
ClientMutationID *string `json:"clientMutationId"`
// The affected bug.
- Bug *bug.Snapshot `json:"bug"`
+ Bug BugWrapper `json:"bug"`
// The resulting operation.
Operation *bug.LabelChangeOperation `json:"operation"`
// The effect each source label had.
@@ -95,7 +94,7 @@ type CloseBugPayload struct {
// A unique identifier for the client performing the mutation.
ClientMutationID *string `json:"clientMutationId"`
// The affected bug.
- Bug *bug.Snapshot `json:"bug"`
+ Bug BugWrapper `json:"bug"`
// The resulting operation.
Operation *bug.SetStatusOperation `json:"operation"`
}
@@ -125,7 +124,7 @@ type CommitAsNeededPayload struct {
// A unique identifier for the client performing the mutation.
ClientMutationID *string `json:"clientMutationId"`
// The affected bug.
- Bug *bug.Snapshot `json:"bug"`
+ Bug BugWrapper `json:"bug"`
}
type CommitInput struct {
@@ -141,19 +140,19 @@ type CommitPayload struct {
// A unique identifier for the client performing the mutation.
ClientMutationID *string `json:"clientMutationId"`
// The affected bug.
- Bug *bug.Snapshot `json:"bug"`
+ Bug BugWrapper `json:"bug"`
}
type IdentityConnection struct {
- Edges []*IdentityEdge `json:"edges"`
- Nodes []identity.Interface `json:"nodes"`
- PageInfo *PageInfo `json:"pageInfo"`
- TotalCount int `json:"totalCount"`
+ Edges []*IdentityEdge `json:"edges"`
+ Nodes []IdentityWrapper `json:"nodes"`
+ PageInfo *PageInfo `json:"pageInfo"`
+ TotalCount int `json:"totalCount"`
}
type IdentityEdge struct {
- Cursor string `json:"cursor"`
- Node identity.Interface `json:"node"`
+ Cursor string `json:"cursor"`
+ Node IdentityWrapper `json:"node"`
}
type LabelConnection struct {
@@ -185,7 +184,7 @@ type NewBugPayload struct {
// A unique identifier for the client performing the mutation.
ClientMutationID *string `json:"clientMutationId"`
// The created bug.
- Bug *bug.Snapshot `json:"bug"`
+ Bug BugWrapper `json:"bug"`
// The resulting operation.
Operation *bug.CreateOperation `json:"operation"`
}
@@ -203,7 +202,7 @@ type OpenBugPayload struct {
// A unique identifier for the client performing the mutation.
ClientMutationID *string `json:"clientMutationId"`
// The affected bug.
- Bug *bug.Snapshot `json:"bug"`
+ Bug BugWrapper `json:"bug"`
// The resulting operation.
Operation *bug.SetStatusOperation `json:"operation"`
}
@@ -249,7 +248,7 @@ type SetTitlePayload struct {
// A unique identifier for the client performing the mutation.
ClientMutationID *string `json:"clientMutationId"`
// The affected bug.
- Bug *bug.Snapshot `json:"bug"`
+ Bug BugWrapper `json:"bug"`
// The resulting operation
Operation *bug.SetTitleOperation `json:"operation"`
}
diff --git a/graphql/models/lazy_bug.go b/graphql/models/lazy_bug.go
new file mode 100644
index 00000000..6034e80d
--- /dev/null
+++ b/graphql/models/lazy_bug.go
@@ -0,0 +1,215 @@
+package models
+
+import (
+ "sync"
+ "time"
+
+ "github.com/MichaelMure/git-bug/bug"
+ "github.com/MichaelMure/git-bug/cache"
+ "github.com/MichaelMure/git-bug/entity"
+)
+
+// BugWrapper is an interface used by the GraphQL resolvers to handle a bug.
+// Depending on the situation, a Bug can already be fully loaded in memory or not.
+// This interface is used to wrap either a lazyBug or a loadedBug depending on the situation.
+type BugWrapper interface {
+ Id() entity.Id
+ LastEdit() time.Time
+ Status() bug.Status
+ Title() string
+ Comments() ([]bug.Comment, error)
+ Labels() []bug.Label
+ Author() (IdentityWrapper, error)
+ Actors() ([]IdentityWrapper, error)
+ Participants() ([]IdentityWrapper, error)
+ CreatedAt() time.Time
+ Timeline() ([]bug.TimelineItem, error)
+ Operations() ([]bug.Operation, error)
+
+ IsAuthored()
+}
+
+var _ BugWrapper = &lazyBug{}
+
+// lazyBug is a lazy-loading wrapper that fetch data from the cache (BugExcerpt) in priority,
+// and load the complete bug and snapshot only when necessary.
+type lazyBug struct {
+ cache *cache.RepoCache
+ excerpt *cache.BugExcerpt
+
+ mu sync.Mutex
+ snap *bug.Snapshot
+}
+
+func NewLazyBug(cache *cache.RepoCache, excerpt *cache.BugExcerpt) *lazyBug {
+ return &lazyBug{
+ cache: cache,
+ excerpt: excerpt,
+ }
+}
+
+func (lb *lazyBug) load() error {
+ if lb.snap != nil {
+ return nil
+ }
+
+ lb.mu.Lock()
+ defer lb.mu.Unlock()
+
+ b, err := lb.cache.ResolveBug(lb.excerpt.Id)
+ if err != nil {
+ return err
+ }
+
+ lb.snap = b.Snapshot()
+ return nil
+}
+
+func (lb *lazyBug) identity(id entity.Id) (IdentityWrapper, error) {
+ i, err := lb.cache.ResolveIdentityExcerpt(id)
+ if err != nil {
+ return nil, err
+ }
+ return &lazyIdentity{cache: lb.cache, excerpt: i}, nil
+}
+
+// Sign post method for gqlgen
+func (lb *lazyBug) IsAuthored() {}
+
+func (lb *lazyBug) Id() entity.Id {
+ return lb.excerpt.Id
+}
+
+func (lb *lazyBug) LastEdit() time.Time {
+ return time.Unix(lb.excerpt.EditUnixTime, 0)
+}
+
+func (lb *lazyBug) Status() bug.Status {
+ return lb.excerpt.Status
+}
+
+func (lb *lazyBug) Title() string {
+ return lb.excerpt.Title
+}
+
+func (lb *lazyBug) Comments() ([]bug.Comment, error) {
+ err := lb.load()
+ if err != nil {
+ return nil, err
+ }
+ return lb.snap.Comments, nil
+}
+
+func (lb *lazyBug) Labels() []bug.Label {
+ return lb.excerpt.Labels
+}
+
+func (lb *lazyBug) Author() (IdentityWrapper, error) {
+ return lb.identity(lb.excerpt.AuthorId)
+}
+
+func (lb *lazyBug) Actors() ([]IdentityWrapper, error) {
+ result := make([]IdentityWrapper, len(lb.excerpt.Actors))
+ for i, actorId := range lb.excerpt.Actors {
+ actor, err := lb.identity(actorId)
+ if err != nil {
+ return nil, err
+ }
+ result[i] = actor
+ }
+ return result, nil
+}
+
+func (lb *lazyBug) Participants() ([]IdentityWrapper, error) {
+ result := make([]IdentityWrapper, len(lb.excerpt.Participants))
+ for i, participantId := range lb.excerpt.Participants {
+ participant, err := lb.identity(participantId)
+ if err != nil {
+ return nil, err
+ }
+ result[i] = participant
+ }
+ return result, nil
+}
+
+func (lb *lazyBug) CreatedAt() time.Time {
+ return time.Unix(lb.excerpt.CreateUnixTime, 0)
+}
+
+func (lb *lazyBug) Timeline() ([]bug.TimelineItem, error) {
+ err := lb.load()
+ if err != nil {
+ return nil, err
+ }
+ return lb.snap.Timeline, nil
+}
+
+func (lb *lazyBug) Operations() ([]bug.Operation, error) {
+ err := lb.load()
+ if err != nil {
+ return nil, err
+ }
+ return lb.snap.Operations, nil
+}
+
+var _ BugWrapper = &loadedBug{}
+
+type loadedBug struct {
+ *bug.Snapshot
+}
+
+func NewLoadedBug(snap *bug.Snapshot) *loadedBug {
+ return &loadedBug{Snapshot: snap}
+}
+
+func (l *loadedBug) LastEdit() time.Time {
+ return l.Snapshot.LastEditTime()
+}
+
+func (l *loadedBug) Status() bug.Status {
+ return l.Snapshot.Status
+}
+
+func (l *loadedBug) Title() string {
+ return l.Snapshot.Title
+}
+
+func (l *loadedBug) Comments() ([]bug.Comment, error) {
+ return l.Snapshot.Comments, nil
+}
+
+func (l *loadedBug) Labels() []bug.Label {
+ return l.Snapshot.Labels
+}
+
+func (l *loadedBug) Author() (IdentityWrapper, error) {
+ return NewLoadedIdentity(l.Snapshot.Author), nil
+}
+
+func (l *loadedBug) Actors() ([]IdentityWrapper, error) {
+ res := make([]IdentityWrapper, len(l.Snapshot.Actors))
+ for i, actor := range l.Snapshot.Actors {
+ res[i] = NewLoadedIdentity(actor)
+ }
+ return res, nil
+}
+
+func (l *loadedBug) Participants() ([]IdentityWrapper, error) {
+ res := make([]IdentityWrapper, len(l.Snapshot.Participants))
+ for i, participant := range l.Snapshot.Participants {
+ res[i] = NewLoadedIdentity(participant)
+ }
+ return res, nil
+}
+
+func (l *loadedBug) CreatedAt() time.Time {
+ return l.Snapshot.CreatedAt
+}
+
+func (l *loadedBug) Timeline() ([]bug.TimelineItem, error) {
+ return l.Snapshot.Timeline, nil
+}
+
+func (l *loadedBug) Operations() ([]bug.Operation, error) {
+ return l.Snapshot.Operations, nil
+}
diff --git a/graphql/models/lazy_identity.go b/graphql/models/lazy_identity.go
new file mode 100644
index 00000000..bbd36be3
--- /dev/null
+++ b/graphql/models/lazy_identity.go
@@ -0,0 +1,167 @@
+package models
+
+import (
+ "fmt"
+ "sync"
+
+ "github.com/MichaelMure/git-bug/cache"
+ "github.com/MichaelMure/git-bug/entity"
+ "github.com/MichaelMure/git-bug/identity"
+ "github.com/MichaelMure/git-bug/util/lamport"
+ "github.com/MichaelMure/git-bug/util/timestamp"
+)
+
+// IdentityWrapper is an interface used by the GraphQL resolvers to handle an identity.
+// Depending on the situation, an Identity can already be fully loaded in memory or not.
+// This interface is used to wrap either a lazyIdentity or a loadedIdentity depending on the situation.
+type IdentityWrapper interface {
+ Id() entity.Id
+ Name() string
+ Email() (string, error)
+ AvatarUrl() (string, error)
+ Keys() ([]*identity.Key, error)
+ ValidKeysAtTime(time lamport.Time) ([]*identity.Key, error)
+ DisplayName() string
+ IsProtected() (bool, error)
+ LastModificationLamport() (lamport.Time, error)
+ LastModification() (timestamp.Timestamp, error)
+}
+
+var _ IdentityWrapper = &lazyIdentity{}
+
+type lazyIdentity struct {
+ cache *cache.RepoCache
+ excerpt *cache.IdentityExcerpt
+
+ mu sync.Mutex
+ id *cache.IdentityCache
+}
+
+func NewLazyIdentity(cache *cache.RepoCache, excerpt *cache.IdentityExcerpt) *lazyIdentity {
+ return &lazyIdentity{
+ cache: cache,
+ excerpt: excerpt,
+ }
+}
+
+func (li *lazyIdentity) load() (*cache.IdentityCache, error) {
+ if li.id != nil {
+ return li.id, nil
+ }
+
+ li.mu.Lock()
+ defer li.mu.Unlock()
+
+ id, err := li.cache.ResolveIdentity(li.excerpt.Id)
+ if err != nil {
+ return nil, fmt.Errorf("cache: missing identity %v", li.excerpt.Id)
+ }
+ li.id = id
+ return id, nil
+}
+
+func (li *lazyIdentity) Id() entity.Id {
+ return li.excerpt.Id
+}
+
+func (li *lazyIdentity) Name() string {
+ return li.excerpt.Name
+}
+
+func (li *lazyIdentity) Email() (string, error) {
+ id, err := li.load()
+ if err != nil {
+ return "", err
+ }
+ return id.Email(), nil
+}
+
+func (li *lazyIdentity) AvatarUrl() (string, error) {
+ id, err := li.load()
+ if err != nil {
+ return "", err
+ }
+ return id.AvatarUrl(), nil
+}
+
+func (li *lazyIdentity) Keys() ([]*identity.Key, error) {
+ id, err := li.load()
+ if err != nil {
+ return nil, err
+ }
+ return id.Keys(), nil
+}
+
+func (li *lazyIdentity) ValidKeysAtTime(time lamport.Time) ([]*identity.Key, error) {
+ id, err := li.load()
+ if err != nil {
+ return nil, err
+ }
+ return id.ValidKeysAtTime(time), nil
+}
+
+func (li *lazyIdentity) DisplayName() string {
+ return li.excerpt.DisplayName()
+}
+
+func (li *lazyIdentity) IsProtected() (bool, error) {
+ id, err := li.load()
+ if err != nil {
+ return false, err
+ }
+ return id.IsProtected(), nil
+}
+
+func (li *lazyIdentity) LastModificationLamport() (lamport.Time, error) {
+ id, err := li.load()
+ if err != nil {
+ return 0, err
+ }
+ return id.LastModificationLamport(), nil
+}
+
+func (li *lazyIdentity) LastModification() (timestamp.Timestamp, error) {
+ id, err := li.load()
+ if err != nil {
+ return 0, err
+ }
+ return id.LastModification(), nil
+}
+
+var _ IdentityWrapper = &loadedIdentity{}
+
+type loadedIdentity struct {
+ identity.Interface
+}
+
+func NewLoadedIdentity(id identity.Interface) *loadedIdentity {
+ return &loadedIdentity{Interface: id}
+}
+
+func (l loadedIdentity) Email() (string, error) {
+ return l.Interface.Email(), nil
+}
+
+func (l loadedIdentity) AvatarUrl() (string, error) {
+ return l.Interface.AvatarUrl(), nil
+}
+
+func (l loadedIdentity) Keys() ([]*identity.Key, error) {
+ return l.Interface.Keys(), nil
+}
+
+func (l loadedIdentity) ValidKeysAtTime(time lamport.Time) ([]*identity.Key, error) {
+ return l.Interface.ValidKeysAtTime(time), nil
+}
+
+func (l loadedIdentity) IsProtected() (bool, error) {
+ return l.Interface.IsProtected(), nil
+}
+
+func (l loadedIdentity) LastModificationLamport() (lamport.Time, error) {
+ return l.Interface.LastModificationLamport(), nil
+}
+
+func (l loadedIdentity) LastModification() (timestamp.Timestamp, error) {
+ return l.Interface.LastModification(), nil
+}
diff --git a/graphql/resolvers/bug.go b/graphql/resolvers/bug.go
index 8f994c0b..fd8f4b6e 100644
--- a/graphql/resolvers/bug.go
+++ b/graphql/resolvers/bug.go
@@ -2,32 +2,30 @@ package resolvers
import (
"context"
- "time"
"github.com/MichaelMure/git-bug/bug"
"github.com/MichaelMure/git-bug/graphql/connections"
"github.com/MichaelMure/git-bug/graphql/graph"
"github.com/MichaelMure/git-bug/graphql/models"
- "github.com/MichaelMure/git-bug/identity"
)
var _ graph.BugResolver = &bugResolver{}
type bugResolver struct{}
-func (bugResolver) ID(ctx context.Context, obj *bug.Snapshot) (string, error) {
+func (bugResolver) ID(_ context.Context, obj models.BugWrapper) (string, error) {
return obj.Id().String(), nil
}
-func (bugResolver) HumanID(ctx context.Context, obj *bug.Snapshot) (string, error) {
+func (bugResolver) HumanID(_ context.Context, obj models.BugWrapper) (string, error) {
return obj.Id().Human(), nil
}
-func (bugResolver) Status(ctx context.Context, obj *bug.Snapshot) (models.Status, error) {
- return convertStatus(obj.Status)
+func (bugResolver) Status(_ context.Context, obj models.BugWrapper) (models.Status, error) {
+ return convertStatus(obj.Status())
}
-func (bugResolver) Comments(ctx context.Context, obj *bug.Snapshot, after *string, before *string, first *int, last *int) (*models.CommentConnection, error) {
+func (bugResolver) Comments(_ context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.CommentConnection, error) {
input := models.ConnectionInput{
Before: before,
After: after,
@@ -55,10 +53,15 @@ func (bugResolver) Comments(ctx context.Context, obj *bug.Snapshot, after *strin
}, nil
}
- return connections.CommentCon(obj.Comments, edger, conMaker, input)
+ comments, err := obj.Comments()
+ if err != nil {
+ return nil, err
+ }
+
+ return connections.CommentCon(comments, edger, conMaker, input)
}
-func (bugResolver) Operations(ctx context.Context, obj *bug.Snapshot, after *string, before *string, first *int, last *int) (*models.OperationConnection, error) {
+func (bugResolver) Operations(_ context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.OperationConnection, error) {
input := models.ConnectionInput{
Before: before,
After: after,
@@ -82,10 +85,15 @@ func (bugResolver) Operations(ctx context.Context, obj *bug.Snapshot, after *str
}, nil
}
- return connections.OperationCon(obj.Operations, edger, conMaker, input)
+ ops, err := obj.Operations()
+ if err != nil {
+ return nil, err
+ }
+
+ return connections.OperationCon(ops, edger, conMaker, input)
}
-func (bugResolver) Timeline(ctx context.Context, obj *bug.Snapshot, after *string, before *string, first *int, last *int) (*models.TimelineItemConnection, error) {
+func (bugResolver) Timeline(_ context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.TimelineItemConnection, error) {
input := models.ConnectionInput{
Before: before,
After: after,
@@ -109,15 +117,15 @@ func (bugResolver) Timeline(ctx context.Context, obj *bug.Snapshot, after *strin
}, nil
}
- return connections.TimelineItemCon(obj.Timeline, edger, conMaker, input)
-}
+ timeline, err := obj.Timeline()
+ if err != nil {
+ return nil, err
+ }
-func (bugResolver) LastEdit(ctx context.Context, obj *bug.Snapshot) (*time.Time, error) {
- t := obj.LastEditTime()
- return &t, nil
+ return connections.TimelineItemCon(timeline, edger, conMaker, input)
}
-func (bugResolver) Actors(ctx context.Context, obj *bug.Snapshot, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error) {
+func (bugResolver) Actors(_ context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error) {
input := models.ConnectionInput{
Before: before,
After: after,
@@ -125,14 +133,14 @@ func (bugResolver) Actors(ctx context.Context, obj *bug.Snapshot, after *string,
Last: last,
}
- edger := func(actor identity.Interface, offset int) connections.Edge {
+ edger := func(actor models.IdentityWrapper, offset int) connections.Edge {
return models.IdentityEdge{
Node: actor,
Cursor: connections.OffsetToCursor(offset),
}
}
- conMaker := func(edges []*models.IdentityEdge, nodes []identity.Interface, info *models.PageInfo, totalCount int) (*models.IdentityConnection, error) {
+ conMaker := func(edges []*models.IdentityEdge, nodes []models.IdentityWrapper, info *models.PageInfo, totalCount int) (*models.IdentityConnection, error) {
return &models.IdentityConnection{
Edges: edges,
Nodes: nodes,
@@ -141,10 +149,15 @@ func (bugResolver) Actors(ctx context.Context, obj *bug.Snapshot, after *string,
}, nil
}
- return connections.IdentityCon(obj.Actors, edger, conMaker, input)
+ actors, err := obj.Actors()
+ if err != nil {
+ return nil, err
+ }
+
+ return connections.IdentityCon(actors, edger, conMaker, input)
}
-func (bugResolver) Participants(ctx context.Context, obj *bug.Snapshot, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error) {
+func (bugResolver) Participants(_ context.Context, obj models.BugWrapper, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error) {
input := models.ConnectionInput{
Before: before,
After: after,
@@ -152,14 +165,14 @@ func (bugResolver) Participants(ctx context.Context, obj *bug.Snapshot, after *s
Last: last,
}
- edger := func(participant identity.Interface, offset int) connections.Edge {
+ edger := func(participant models.IdentityWrapper, offset int) connections.Edge {
return models.IdentityEdge{
Node: participant,
Cursor: connections.OffsetToCursor(offset),
}
}
- conMaker := func(edges []*models.IdentityEdge, nodes []identity.Interface, info *models.PageInfo, totalCount int) (*models.IdentityConnection, error) {
+ conMaker := func(edges []*models.IdentityEdge, nodes []models.IdentityWrapper, info *models.PageInfo, totalCount int) (*models.IdentityConnection, error) {
return &models.IdentityConnection{
Edges: edges,
Nodes: nodes,
@@ -168,5 +181,10 @@ func (bugResolver) Participants(ctx context.Context, obj *bug.Snapshot, after *s
}, nil
}
- return connections.IdentityCon(obj.Participants, edger, conMaker, input)
+ participants, err := obj.Participants()
+ if err != nil {
+ return nil, err
+ }
+
+ return connections.IdentityCon(participants, edger, conMaker, input)
}
diff --git a/graphql/resolvers/color.go b/graphql/resolvers/color.go
index dc6f1b9c..8dc13095 100644
--- a/graphql/resolvers/color.go
+++ b/graphql/resolvers/color.go
@@ -11,14 +11,14 @@ var _ graph.ColorResolver = &colorResolver{}
type colorResolver struct{}
-func (colorResolver) R(ctx context.Context, obj *color.RGBA) (int, error) {
+func (colorResolver) R(_ context.Context, obj *color.RGBA) (int, error) {
return int(obj.R), nil
}
-func (colorResolver) G(ctx context.Context, obj *color.RGBA) (int, error) {
+func (colorResolver) G(_ context.Context, obj *color.RGBA) (int, error) {
return int(obj.G), nil
}
-func (colorResolver) B(ctx context.Context, obj *color.RGBA) (int, error) {
+func (colorResolver) B(_ context.Context, obj *color.RGBA) (int, error) {
return int(obj.B), nil
}
diff --git a/graphql/resolvers/comment.go b/graphql/resolvers/comment.go
new file mode 100644
index 00000000..b142712a
--- /dev/null
+++ b/graphql/resolvers/comment.go
@@ -0,0 +1,17 @@
+package resolvers
+
+import (
+ "context"
+
+ "github.com/MichaelMure/git-bug/bug"
+ "github.com/MichaelMure/git-bug/graphql/graph"
+ "github.com/MichaelMure/git-bug/graphql/models"
+)
+
+var _ graph.CommentResolver = &commentResolver{}
+
+type commentResolver struct{}
+
+func (c commentResolver) Author(_ context.Context, obj *bug.Comment) (models.IdentityWrapper, error) {
+ return models.NewLoadedIdentity(obj.Author), nil
+}
diff --git a/graphql/resolvers/identity.go b/graphql/resolvers/identity.go
index ee40d4d8..b8aa72a7 100644
--- a/graphql/resolvers/identity.go
+++ b/graphql/resolvers/identity.go
@@ -4,48 +4,18 @@ import (
"context"
"github.com/MichaelMure/git-bug/graphql/graph"
- "github.com/MichaelMure/git-bug/identity"
+ "github.com/MichaelMure/git-bug/graphql/models"
)
var _ graph.IdentityResolver = &identityResolver{}
type identityResolver struct{}
-func (identityResolver) ID(ctx context.Context, obj *identity.Interface) (string, error) {
- return (*obj).Id().String(), nil
+func (identityResolver) ID(ctx context.Context, obj models.IdentityWrapper) (string, error) {
+ return obj.Id().String(), nil
}
-func (identityResolver) HumanID(ctx context.Context, obj *identity.Interface) (string, error) {
- return (*obj).Id().Human(), nil
-}
-
-func (identityResolver) Name(ctx context.Context, obj *identity.Interface) (*string, error) {
- return nilIfEmpty((*obj).Name())
-}
-
-func (identityResolver) Email(ctx context.Context, obj *identity.Interface) (*string, error) {
- return nilIfEmpty((*obj).Email())
-}
-
-func (identityResolver) Login(ctx context.Context, obj *identity.Interface) (*string, error) {
- return nilIfEmpty((*obj).Login())
-}
-
-func (identityResolver) DisplayName(ctx context.Context, obj *identity.Interface) (string, error) {
- return (*obj).DisplayName(), nil
-}
-
-func (identityResolver) AvatarURL(ctx context.Context, obj *identity.Interface) (*string, error) {
- return nilIfEmpty((*obj).AvatarUrl())
-}
-
-func (identityResolver) IsProtected(ctx context.Context, obj *identity.Interface) (bool, error) {
- return (*obj).IsProtected(), nil
-}
+func (r identityResolver) HumanID(ctx context.Context, obj models.IdentityWrapper) (string, error) {
+ return obj.Id().Human(), nil
-func nilIfEmpty(s string) (*string, error) {
- if s == "" {
- return nil, nil
- }
- return &s, nil
}
diff --git a/graphql/resolvers/mutation.go b/graphql/resolvers/mutation.go
index b4f8845a..889edbc8 100644
--- a/graphql/resolvers/mutation.go
+++ b/graphql/resolvers/mutation.go
@@ -23,7 +23,7 @@ func (r mutationResolver) getRepo(ref *string) (*cache.RepoCache, error) {
return r.cache.DefaultRepo()
}
-func (r mutationResolver) NewBug(ctx context.Context, input models.NewBugInput) (*models.NewBugPayload, error) {
+func (r mutationResolver) NewBug(_ context.Context, input models.NewBugInput) (*models.NewBugPayload, error) {
repo, err := r.getRepo(input.RepoRef)
if err != nil {
return nil, err
@@ -36,12 +36,12 @@ func (r mutationResolver) NewBug(ctx context.Context, input models.NewBugInput)
return &models.NewBugPayload{
ClientMutationID: input.ClientMutationID,
- Bug: b.Snapshot(),
+ Bug: models.NewLoadedBug(b.Snapshot()),
Operation: op,
}, nil
}
-func (r mutationResolver) AddComment(ctx context.Context, input models.AddCommentInput) (*models.AddCommentPayload, error) {
+func (r mutationResolver) AddComment(_ context.Context, input models.AddCommentInput) (*models.AddCommentPayload, error) {
repo, err := r.getRepo(input.RepoRef)
if err != nil {
return nil, err
@@ -59,12 +59,12 @@ func (r mutationResolver) AddComment(ctx context.Context, input models.AddCommen
return &models.AddCommentPayload{
ClientMutationID: input.ClientMutationID,
- Bug: b.Snapshot(),
+ Bug: models.NewLoadedBug(b.Snapshot()),
Operation: op,
}, nil
}
-func (r mutationResolver) ChangeLabels(ctx context.Context, input *models.ChangeLabelInput) (*models.ChangeLabelPayload, error) {
+func (r mutationResolver) ChangeLabels(_ context.Context, input *models.ChangeLabelInput) (*models.ChangeLabelPayload, error) {
repo, err := r.getRepo(input.RepoRef)
if err != nil {
return nil, err
@@ -87,13 +87,13 @@ func (r mutationResolver) ChangeLabels(ctx context.Context, input *models.Change
return &models.ChangeLabelPayload{
ClientMutationID: input.ClientMutationID,
- Bug: b.Snapshot(),
+ Bug: models.NewLoadedBug(b.Snapshot()),
Operation: op,
Results: resultsPtr,
}, nil
}
-func (r mutationResolver) OpenBug(ctx context.Context, input models.OpenBugInput) (*models.OpenBugPayload, error) {
+func (r mutationResolver) OpenBug(_ context.Context, input models.OpenBugInput) (*models.OpenBugPayload, error) {
repo, err := r.getRepo(input.RepoRef)
if err != nil {
return nil, err
@@ -111,12 +111,12 @@ func (r mutationResolver) OpenBug(ctx context.Context, input models.OpenBugInput
return &models.OpenBugPayload{
ClientMutationID: input.ClientMutationID,
- Bug: b.Snapshot(),
+ Bug: models.NewLoadedBug(b.Snapshot()),
Operation: op,
}, nil
}
-func (r mutationResolver) CloseBug(ctx context.Context, input models.CloseBugInput) (*models.CloseBugPayload, error) {
+func (r mutationResolver) CloseBug(_ context.Context, input models.CloseBugInput) (*models.CloseBugPayload, error) {
repo, err := r.getRepo(input.RepoRef)
if err != nil {
return nil, err
@@ -134,12 +134,12 @@ func (r mutationResolver) CloseBug(ctx context.Context, input models.CloseBugInp
return &models.CloseBugPayload{
ClientMutationID: input.ClientMutationID,
- Bug: b.Snapshot(),
+ Bug: models.NewLoadedBug(b.Snapshot()),
Operation: op,
}, nil
}
-func (r mutationResolver) SetTitle(ctx context.Context, input models.SetTitleInput) (*models.SetTitlePayload, error) {
+func (r mutationResolver) SetTitle(_ context.Context, input models.SetTitleInput) (*models.SetTitlePayload, error) {
repo, err := r.getRepo(input.RepoRef)
if err != nil {
return nil, err
@@ -157,12 +157,12 @@ func (r mutationResolver) SetTitle(ctx context.Context, input models.SetTitleInp
return &models.SetTitlePayload{
ClientMutationID: input.ClientMutationID,
- Bug: b.Snapshot(),
+ Bug: models.NewLoadedBug(b.Snapshot()),
Operation: op,
}, nil
}
-func (r mutationResolver) Commit(ctx context.Context, input models.CommitInput) (*models.CommitPayload, error) {
+func (r mutationResolver) Commit(_ context.Context, input models.CommitInput) (*models.CommitPayload, error) {
repo, err := r.getRepo(input.RepoRef)
if err != nil {
return nil, err
@@ -180,11 +180,11 @@ func (r mutationResolver) Commit(ctx context.Context, input models.CommitInput)
return &models.CommitPayload{
ClientMutationID: input.ClientMutationID,
- Bug: b.Snapshot(),
+ Bug: models.NewLoadedBug(b.Snapshot()),
}, nil
}
-func (r mutationResolver) CommitAsNeeded(ctx context.Context, input models.CommitAsNeededInput) (*models.CommitAsNeededPayload, error) {
+func (r mutationResolver) CommitAsNeeded(_ context.Context, input models.CommitAsNeededInput) (*models.CommitAsNeededPayload, error) {
repo, err := r.getRepo(input.RepoRef)
if err != nil {
return nil, err
@@ -202,6 +202,6 @@ func (r mutationResolver) CommitAsNeeded(ctx context.Context, input models.Commi
return &models.CommitAsNeededPayload{
ClientMutationID: input.ClientMutationID,
- Bug: b.Snapshot(),
+ Bug: models.NewLoadedBug(b.Snapshot()),
}, nil
}
diff --git a/graphql/resolvers/operations.go b/graphql/resolvers/operations.go
index ec803c1f..29110cf3 100644
--- a/graphql/resolvers/operations.go
+++ b/graphql/resolvers/operations.go
@@ -14,11 +14,15 @@ var _ graph.CreateOperationResolver = createOperationResolver{}
type createOperationResolver struct{}
-func (createOperationResolver) ID(ctx context.Context, obj *bug.CreateOperation) (string, error) {
+func (createOperationResolver) ID(_ context.Context, obj *bug.CreateOperation) (string, error) {
return obj.Id().String(), nil
}
-func (createOperationResolver) Date(ctx context.Context, obj *bug.CreateOperation) (*time.Time, error) {
+func (createOperationResolver) Author(_ context.Context, obj *bug.CreateOperation) (models.IdentityWrapper, error) {
+ return models.NewLoadedIdentity(obj.Author), nil
+}
+
+func (createOperationResolver) Date(_ context.Context, obj *bug.CreateOperation) (*time.Time, error) {
t := obj.Time()
return &t, nil
}
@@ -27,11 +31,15 @@ var _ graph.AddCommentOperationResolver = addCommentOperationResolver{}
type addCommentOperationResolver struct{}
-func (addCommentOperationResolver) ID(ctx context.Context, obj *bug.AddCommentOperation) (string, error) {
+func (addCommentOperationResolver) ID(_ context.Context, obj *bug.AddCommentOperation) (string, error) {
return obj.Id().String(), nil
}
-func (addCommentOperationResolver) Date(ctx context.Context, obj *bug.AddCommentOperation) (*time.Time, error) {
+func (addCommentOperationResolver) Author(_ context.Context, obj *bug.AddCommentOperation) (models.IdentityWrapper, error) {
+ return models.NewLoadedIdentity(obj.Author), nil
+}
+
+func (addCommentOperationResolver) Date(_ context.Context, obj *bug.AddCommentOperation) (*time.Time, error) {
t := obj.Time()
return &t, nil
}
@@ -40,15 +48,19 @@ var _ graph.EditCommentOperationResolver = editCommentOperationResolver{}
type editCommentOperationResolver struct{}
-func (editCommentOperationResolver) ID(ctx context.Context, obj *bug.EditCommentOperation) (string, error) {
+func (editCommentOperationResolver) ID(_ context.Context, obj *bug.EditCommentOperation) (string, error) {
return obj.Id().String(), nil
}
-func (editCommentOperationResolver) Target(ctx context.Context, obj *bug.EditCommentOperation) (string, error) {
+func (editCommentOperationResolver) Target(_ context.Context, obj *bug.EditCommentOperation) (string, error) {
return obj.Target.String(), nil
}
-func (editCommentOperationResolver) Date(ctx context.Context, obj *bug.EditCommentOperation) (*time.Time, error) {
+func (editCommentOperationResolver) Author(_ context.Context, obj *bug.EditCommentOperation) (models.IdentityWrapper, error) {
+ return models.NewLoadedIdentity(obj.Author), nil
+}
+
+func (editCommentOperationResolver) Date(_ context.Context, obj *bug.EditCommentOperation) (*time.Time, error) {
t := obj.Time()
return &t, nil
}
@@ -57,11 +69,15 @@ var _ graph.LabelChangeOperationResolver = labelChangeOperationResolver{}
type labelChangeOperationResolver struct{}
-func (labelChangeOperationResolver) ID(ctx context.Context, obj *bug.LabelChangeOperation) (string, error) {
+func (labelChangeOperationResolver) ID(_ context.Context, obj *bug.LabelChangeOperation) (string, error) {
return obj.Id().String(), nil
}
-func (labelChangeOperationResolver) Date(ctx context.Context, obj *bug.LabelChangeOperation) (*time.Time, error) {
+func (labelChangeOperationResolver) Author(_ context.Context, obj *bug.LabelChangeOperation) (models.IdentityWrapper, error) {
+ return models.NewLoadedIdentity(obj.Author), nil
+}
+
+func (labelChangeOperationResolver) Date(_ context.Context, obj *bug.LabelChangeOperation) (*time.Time, error) {
t := obj.Time()
return &t, nil
}
@@ -70,16 +86,20 @@ var _ graph.SetStatusOperationResolver = setStatusOperationResolver{}
type setStatusOperationResolver struct{}
-func (setStatusOperationResolver) ID(ctx context.Context, obj *bug.SetStatusOperation) (string, error) {
+func (setStatusOperationResolver) ID(_ context.Context, obj *bug.SetStatusOperation) (string, error) {
return obj.Id().String(), nil
}
-func (setStatusOperationResolver) Date(ctx context.Context, obj *bug.SetStatusOperation) (*time.Time, error) {
+func (setStatusOperationResolver) Author(_ context.Context, obj *bug.SetStatusOperation) (models.IdentityWrapper, error) {
+ return models.NewLoadedIdentity(obj.Author), nil
+}
+
+func (setStatusOperationResolver) Date(_ context.Context, obj *bug.SetStatusOperation) (*time.Time, error) {
t := obj.Time()
return &t, nil
}
-func (setStatusOperationResolver) Status(ctx context.Context, obj *bug.SetStatusOperation) (models.Status, error) {
+func (setStatusOperationResolver) Status(_ context.Context, obj *bug.SetStatusOperation) (models.Status, error) {
return convertStatus(obj.Status)
}
@@ -87,11 +107,15 @@ var _ graph.SetTitleOperationResolver = setTitleOperationResolver{}
type setTitleOperationResolver struct{}
-func (setTitleOperationResolver) ID(ctx context.Context, obj *bug.SetTitleOperation) (string, error) {
+func (setTitleOperationResolver) ID(_ context.Context, obj *bug.SetTitleOperation) (string, error) {
return obj.Id().String(), nil
}
-func (setTitleOperationResolver) Date(ctx context.Context, obj *bug.SetTitleOperation) (*time.Time, error) {
+func (setTitleOperationResolver) Author(_ context.Context, obj *bug.SetTitleOperation) (models.IdentityWrapper, error) {
+ return models.NewLoadedIdentity(obj.Author), nil
+}
+
+func (setTitleOperationResolver) Date(_ context.Context, obj *bug.SetTitleOperation) (*time.Time, error) {
t := obj.Time()
return &t, nil
}
diff --git a/graphql/resolvers/query.go b/graphql/resolvers/query.go
index aa4e1d85..9503ccf4 100644
--- a/graphql/resolvers/query.go
+++ b/graphql/resolvers/query.go
@@ -14,7 +14,7 @@ type rootQueryResolver struct {
cache *cache.MultiRepoCache
}
-func (r rootQueryResolver) DefaultRepository(ctx context.Context) (*models.Repository, error) {
+func (r rootQueryResolver) DefaultRepository(_ context.Context) (*models.Repository, error) {
repo, err := r.cache.DefaultRepo()
if err != nil {
@@ -27,7 +27,7 @@ func (r rootQueryResolver) DefaultRepository(ctx context.Context) (*models.Repos
}, nil
}
-func (r rootQueryResolver) Repository(ctx context.Context, ref string) (*models.Repository, error) {
+func (r rootQueryResolver) Repository(_ context.Context, ref string) (*models.Repository, error) {
repo, err := r.cache.ResolveRepo(ref)
if err != nil {
diff --git a/graphql/resolvers/repo.go b/graphql/resolvers/repo.go
index 5a37ae18..3b0aa9a1 100644
--- a/graphql/resolvers/repo.go
+++ b/graphql/resolvers/repo.go
@@ -9,14 +9,13 @@ import (
"github.com/MichaelMure/git-bug/graphql/connections"
"github.com/MichaelMure/git-bug/graphql/graph"
"github.com/MichaelMure/git-bug/graphql/models"
- "github.com/MichaelMure/git-bug/identity"
)
var _ graph.RepositoryResolver = &repoResolver{}
type repoResolver struct{}
-func (repoResolver) AllBugs(ctx context.Context, obj *models.Repository, after *string, before *string, first *int, last *int, queryStr *string) (*models.BugConnection, error) {
+func (repoResolver) AllBugs(_ context.Context, obj *models.Repository, after *string, before *string, first *int, last *int, queryStr *string) (*models.BugConnection, error) {
input := models.ConnectionInput{
Before: before,
After: after,
@@ -49,22 +48,21 @@ func (repoResolver) AllBugs(ctx context.Context, obj *models.Repository, after *
// The conMaker will finally load and compile bugs from git to replace the selected edges
conMaker := func(lazyBugEdges []*connections.LazyBugEdge, lazyNode []entity.Id, info *models.PageInfo, totalCount int) (*models.BugConnection, error) {
edges := make([]*models.BugEdge, len(lazyBugEdges))
- nodes := make([]*bug.Snapshot, len(lazyBugEdges))
+ nodes := make([]models.BugWrapper, len(lazyBugEdges))
for i, lazyBugEdge := range lazyBugEdges {
- b, err := obj.Repo.ResolveBug(lazyBugEdge.Id)
-
+ excerpt, err := obj.Repo.ResolveBugExcerpt(lazyBugEdge.Id)
if err != nil {
return nil, err
}
- snap := b.Snapshot()
+ b := models.NewLazyBug(obj.Repo, excerpt)
edges[i] = &models.BugEdge{
Cursor: lazyBugEdge.Cursor,
- Node: snap,
+ Node: b,
}
- nodes[i] = snap
+ nodes[i] = b
}
return &models.BugConnection{
@@ -78,17 +76,16 @@ func (repoResolver) AllBugs(ctx context.Context, obj *models.Repository, after *
return connections.LazyBugCon(source, edger, conMaker, input)
}
-func (repoResolver) Bug(ctx context.Context, obj *models.Repository, prefix string) (*bug.Snapshot, error) {
- b, err := obj.Repo.ResolveBugPrefix(prefix)
-
+func (repoResolver) Bug(_ context.Context, obj *models.Repository, prefix string) (models.BugWrapper, error) {
+ excerpt, err := obj.Repo.ResolveBugExcerptPrefix(prefix)
if err != nil {
return nil, err
}
- return b.Snapshot(), nil
+ return models.NewLazyBug(obj.Repo, excerpt), nil
}
-func (repoResolver) AllIdentities(ctx context.Context, obj *models.Repository, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error) {
+func (repoResolver) AllIdentities(_ context.Context, obj *models.Repository, after *string, before *string, first *int, last *int) (*models.IdentityConnection, error) {
input := models.ConnectionInput{
Before: before,
After: after,
@@ -110,22 +107,21 @@ func (repoResolver) AllIdentities(ctx context.Context, obj *models.Repository, a
// The conMaker will finally load and compile identities from git to replace the selected edges
conMaker := func(lazyIdentityEdges []*connections.LazyIdentityEdge, lazyNode []entity.Id, info *models.PageInfo, totalCount int) (*models.IdentityConnection, error) {
edges := make([]*models.IdentityEdge, len(lazyIdentityEdges))
- nodes := make([]identity.Interface, len(lazyIdentityEdges))
+ nodes := make([]models.IdentityWrapper, len(lazyIdentityEdges))
for k, lazyIdentityEdge := range lazyIdentityEdges {
- i, err := obj.Repo.ResolveIdentity(lazyIdentityEdge.Id)
-
+ excerpt, err := obj.Repo.ResolveIdentityExcerpt(lazyIdentityEdge.Id)
if err != nil {
return nil, err
}
- ii := identity.Interface(i.Identity)
+ i := models.NewLazyIdentity(obj.Repo, excerpt)
edges[k] = &models.IdentityEdge{
Cursor: lazyIdentityEdge.Cursor,
- Node: i.Identity,
+ Node: i,
}
- nodes[k] = ii
+ nodes[k] = i
}
return &models.IdentityConnection{
@@ -139,27 +135,25 @@ func (repoResolver) AllIdentities(ctx context.Context, obj *models.Repository, a
return connections.LazyIdentityCon(source, edger, conMaker, input)
}
-func (repoResolver) Identity(ctx context.Context, obj *models.Repository, prefix string) (identity.Interface, error) {
- i, err := obj.Repo.ResolveIdentityPrefix(prefix)
-
+func (repoResolver) Identity(_ context.Context, obj *models.Repository, prefix string) (models.IdentityWrapper, error) {
+ excerpt, err := obj.Repo.ResolveIdentityExcerptPrefix(prefix)
if err != nil {
return nil, err
}
- return i.Identity, nil
+ return models.NewLazyIdentity(obj.Repo, excerpt), nil
}
-func (repoResolver) UserIdentity(ctx context.Context, obj *models.Repository) (identity.Interface, error) {
- i, err := obj.Repo.GetUserIdentity()
-
+func (repoResolver) UserIdentity(_ context.Context, obj *models.Repository) (models.IdentityWrapper, error) {
+ excerpt, err := obj.Repo.GetUserIdentityExcerpt()
if err != nil {
return nil, err
}
- return i.Identity, nil
+ return models.NewLazyIdentity(obj.Repo, excerpt), nil
}
-func (resolver repoResolver) ValidLabels(ctx context.Context, obj *models.Repository, after *string, before *string, first *int, last *int) (*models.LabelConnection, error) {
+func (resolver repoResolver) ValidLabels(_ context.Context, obj *models.Repository, after *string, before *string, first *int, last *int) (*models.LabelConnection, error) {
input := models.ConnectionInput{
Before: before,
After: after,
diff --git a/graphql/resolvers/root.go b/graphql/resolvers/root.go
index 3b129f3b..9973ff59 100644
--- a/graphql/resolvers/root.go
+++ b/graphql/resolvers/root.go
@@ -42,6 +42,10 @@ func (RootResolver) Color() graph.ColorResolver {
return &colorResolver{}
}
+func (r RootResolver) Comment() graph.CommentResolver {
+ return &commentResolver{}
+}
+
func (RootResolver) Label() graph.LabelResolver {
return &labelResolver{}
}
diff --git a/graphql/resolvers/timeline.go b/graphql/resolvers/timeline.go
index b206f898..acf236f8 100644
--- a/graphql/resolvers/timeline.go
+++ b/graphql/resolvers/timeline.go
@@ -13,7 +13,7 @@ var _ graph.CommentHistoryStepResolver = commentHistoryStepResolver{}
type commentHistoryStepResolver struct{}
-func (commentHistoryStepResolver) Date(ctx context.Context, obj *bug.CommentHistoryStep) (*time.Time, error) {
+func (commentHistoryStepResolver) Date(_ context.Context, obj *bug.CommentHistoryStep) (*time.Time, error) {
t := obj.UnixTime.Time()
return &t, nil
}
@@ -22,16 +22,20 @@ var _ graph.AddCommentTimelineItemResolver = addCommentTimelineItemResolver{}
type addCommentTimelineItemResolver struct{}
-func (addCommentTimelineItemResolver) ID(ctx context.Context, obj *bug.AddCommentTimelineItem) (string, error) {
+func (addCommentTimelineItemResolver) ID(_ context.Context, obj *bug.AddCommentTimelineItem) (string, error) {
return obj.Id().String(), nil
}
-func (addCommentTimelineItemResolver) CreatedAt(ctx context.Context, obj *bug.AddCommentTimelineItem) (*time.Time, error) {
+func (addCommentTimelineItemResolver) Author(_ context.Context, obj *bug.AddCommentTimelineItem) (models.IdentityWrapper, error) {
+ return models.NewLoadedIdentity(obj.Author), nil
+}
+
+func (addCommentTimelineItemResolver) CreatedAt(_ context.Context, obj *bug.AddCommentTimelineItem) (*time.Time, error) {
t := obj.CreatedAt.Time()
return &t, nil
}
-func (addCommentTimelineItemResolver) LastEdit(ctx context.Context, obj *bug.AddCommentTimelineItem) (*time.Time, error) {
+func (addCommentTimelineItemResolver) LastEdit(_ context.Context, obj *bug.AddCommentTimelineItem) (*time.Time, error) {
t := obj.LastEdit.Time()
return &t, nil
}
@@ -40,16 +44,20 @@ var _ graph.CreateTimelineItemResolver = createTimelineItemResolver{}
type createTimelineItemResolver struct{}
-func (createTimelineItemResolver) ID(ctx context.Context, obj *bug.CreateTimelineItem) (string, error) {
+func (createTimelineItemResolver) ID(_ context.Context, obj *bug.CreateTimelineItem) (string, error) {
return obj.Id().String(), nil
}
-func (createTimelineItemResolver) CreatedAt(ctx context.Context, obj *bug.CreateTimelineItem) (*time.Time, error) {
+func (r createTimelineItemResolver) Author(_ context.Context, obj *bug.CreateTimelineItem) (models.IdentityWrapper, error) {
+ return models.NewLoadedIdentity(obj.Author), nil
+}
+
+func (createTimelineItemResolver) CreatedAt(_ context.Context, obj *bug.CreateTimelineItem) (*time.Time, error) {
t := obj.CreatedAt.Time()
return &t, nil
}
-func (createTimelineItemResolver) LastEdit(ctx context.Context, obj *bug.CreateTimelineItem) (*time.Time, error) {
+func (createTimelineItemResolver) LastEdit(_ context.Context, obj *bug.CreateTimelineItem) (*time.Time, error) {
t := obj.LastEdit.Time()
return &t, nil
}
@@ -58,11 +66,15 @@ var _ graph.LabelChangeTimelineItemResolver = labelChangeTimelineItem{}
type labelChangeTimelineItem struct{}
-func (labelChangeTimelineItem) ID(ctx context.Context, obj *bug.LabelChangeTimelineItem) (string, error) {
+func (labelChangeTimelineItem) ID(_ context.Context, obj *bug.LabelChangeTimelineItem) (string, error) {
return obj.Id().String(), nil
}
-func (labelChangeTimelineItem) Date(ctx context.Context, obj *bug.LabelChangeTimelineItem) (*time.Time, error) {
+func (i labelChangeTimelineItem) Author(_ context.Context, obj *bug.LabelChangeTimelineItem) (models.IdentityWrapper, error) {
+ return models.NewLoadedIdentity(obj.Author), nil
+}
+
+func (labelChangeTimelineItem) Date(_ context.Context, obj *bug.LabelChangeTimelineItem) (*time.Time, error) {
t := obj.UnixTime.Time()
return &t, nil
}
@@ -71,16 +83,20 @@ var _ graph.SetStatusTimelineItemResolver = setStatusTimelineItem{}
type setStatusTimelineItem struct{}
-func (setStatusTimelineItem) ID(ctx context.Context, obj *bug.SetStatusTimelineItem) (string, error) {
+func (setStatusTimelineItem) ID(_ context.Context, obj *bug.SetStatusTimelineItem) (string, error) {
return obj.Id().String(), nil
}
-func (setStatusTimelineItem) Date(ctx context.Context, obj *bug.SetStatusTimelineItem) (*time.Time, error) {
+func (i setStatusTimelineItem) Author(_ context.Context, obj *bug.SetStatusTimelineItem) (models.IdentityWrapper, error) {
+ return models.NewLoadedIdentity(obj.Author), nil
+}
+
+func (setStatusTimelineItem) Date(_ context.Context, obj *bug.SetStatusTimelineItem) (*time.Time, error) {
t := obj.UnixTime.Time()
return &t, nil
}
-func (setStatusTimelineItem) Status(ctx context.Context, obj *bug.SetStatusTimelineItem) (models.Status, error) {
+func (setStatusTimelineItem) Status(_ context.Context, obj *bug.SetStatusTimelineItem) (models.Status, error) {
return convertStatus(obj.Status)
}
@@ -88,11 +104,15 @@ var _ graph.SetTitleTimelineItemResolver = setTitleTimelineItem{}
type setTitleTimelineItem struct{}
-func (setTitleTimelineItem) ID(ctx context.Context, obj *bug.SetTitleTimelineItem) (string, error) {
+func (setTitleTimelineItem) ID(_ context.Context, obj *bug.SetTitleTimelineItem) (string, error) {
return obj.Id().String(), nil
}
-func (setTitleTimelineItem) Date(ctx context.Context, obj *bug.SetTitleTimelineItem) (*time.Time, error) {
+func (i setTitleTimelineItem) Author(_ context.Context, obj *bug.SetTitleTimelineItem) (models.IdentityWrapper, error) {
+ return models.NewLoadedIdentity(obj.Author), nil
+}
+
+func (setTitleTimelineItem) Date(_ context.Context, obj *bug.SetTitleTimelineItem) (*time.Time, error) {
t := obj.UnixTime.Time()
return &t, nil
}
diff --git a/graphql/schema/identity.graphql b/graphql/schema/identity.graphql
index 6872ecb9..6490d538 100644
--- a/graphql/schema/identity.graphql
+++ b/graphql/schema/identity.graphql
@@ -8,9 +8,7 @@ type Identity {
name: String
"""The email of the person, if known."""
email: String
- """The login of the person, if known."""
- login: String
- """A string containing the either the name of the person, its login or both"""
+ """A non-empty string to display, representing the identity, based on the non-empty values."""
displayName: String!
"""An url to an avatar"""
avatarUrl: String
diff --git a/graphql/schema/root.graphql b/graphql/schema/root.graphql
index f66272ca..2a12cc37 100644
--- a/graphql/schema/root.graphql
+++ b/graphql/schema/root.graphql
@@ -3,6 +3,8 @@ type Query {
defaultRepository: Repository
"""Access a repository by reference/name."""
repository(ref: String!): Repository
+
+ #TODO: connection for all repositories
}
type Mutation {