• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

99designs / gqlgen / 28400725794
0%

Build:
DEFAULT BRANCH: master
Ran 29 Jun 2026 08:34PM UTC
Jobs 1
Files 0
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

29 Jun 2026 08:31PM UTC coverage: 0.0%. Remained the same
28400725794

push

github

web-flow
fix(federation): return a positioned validation error for @key referencing an undeclared field (#4249)

A @key directive that references a field path whose (possibly nested) parent
is not declared on the entity — e.g. @key(fields: "id order { id }") where
"order" is not a field of the type — caused a nil pointer dereference in
fieldset.Field.FieldDefinition during code generation.

FieldDefinition now honors its "not found" contract, returning nil when a key
path segment is missing instead of dereferencing nil. buildKeyFields,
buildResolvers, buildEntity, and buildEntities thread that up as a returned
error through InjectSourcesLate (which already returns error), so generation
fails cleanly instead of panicking. No public API change: the only exported
members in the chain (FieldDefinition, InjectSourcesLate) keep their signatures.

The @key validation errors are positioned gqlerror values that name the
directive's source location, the original fields string, the offending field
path, and the entity, e.g.:

  federation: schema.graphql:8:15: @key(fields: "id order { id }"): field "order.id" is not defined on "TestEnt"

The too-many-arguments error additionally names the allowed arguments
("fields", "resolvable"), and the in-message "federation:" prefix is dropped
since api.generate already prepends the plugin name.

Tests: a fieldset unit test (missing first/intermediate key segment returns
nil, no panic) and a federation regression test asserting the structured,
positioned error and its source location.

0 of 0 relevant lines covered (NaN%)

0.0 hits per line

Jobs
ID Job ID Ran Files Coverage
1 28400725794.1 29 Jun 2026 08:34PM UTC 0
0.0
GitHub Action Run
Source Files on build 28400725794
Detailed source file information is not available for this build.
  • Back to Repo
  • 678b9040 on github
  • Prev Build on master (#28369938331)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc