Skip to content

refactor: address pr 716 feedback#718

Merged
pavelnikolov merged 2 commits intomainfrom
address-pr-feedback
Mar 31, 2026
Merged

refactor: address pr 716 feedback#718
pavelnikolov merged 2 commits intomainfrom
address-pr-feedback

Conversation

@pavelnikolov
Copy link
Copy Markdown
Member

No description provided.

Copilot AI review requested due to automatic review settings March 31, 2026 21:20
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR refines numeric input coercion to ensure GraphQL Float arguments and nullable float inputs correctly accept int64 values (commonly produced by large integer literals/variables), and expands regression coverage around that behavior.

Changes:

  • Allow NullFloat.UnmarshalGraphQL to coerce int64 inputs to float64.
  • Extend the internal input packer to coerce int64 into float64 when the target type is float64.
  • Expand issue/regression tests to cover int32/int64 behavior for a custom Int64 scalar and for Float arguments (including large positive/negative values).

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
nullable_types.go Adds int64 handling to NullFloat GraphQL unmarshalling.
nullable_types_test.go Adds a test case ensuring NullFloat accepts int64 input.
issue_305_test.go Broadens regression coverage for integer-literal/variable coercion, including large values and Float args.
internal/exec/packer/packer.go Adds int64 -> float64 coercion in UnmarshalInput for reflect.Float64.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@pavelnikolov pavelnikolov merged commit fe1e952 into main Mar 31, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants