Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix fragment spread cycles #479

Merged
merged 7 commits into from
Jan 2, 2024
Merged

Fix fragment spread cycles #479

merged 7 commits into from
Jan 2, 2024

Conversation

imor
Copy link
Contributor

@imor imor commented Dec 27, 2023

What kind of change does this PR introduce?

Bug fix

What is the current behavior?

It is possible to create infinite recursion if fragments form cycles when referring to each other.

What is the new behavior?

Cycles are detected in fragment definitions and an error returned.

Additional context

N/A

...barkVolumeFragment
}

fragment barkVolumeFragment on Dog {
Copy link
Contributor

Choose a reason for hiding this comment

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

lol, nice abstraction

@olirice olirice merged commit 8389e13 into master Jan 2, 2024
4 checks passed
@olirice olirice deleted the fix_fragment_spread_cycles branch January 2, 2024 20:31
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