Moved from GitHub dgraph/2510
Posted by mbudge:
Hi,
I’m wrote a query which legitimately reuses fragments, but we get the cycle detected error, which means we have to copy and rename the fragment.
Would it be possible to add an option to override the cycle detection?
{
domain(func: has(domain)) @filter(eq(name, example.co.uk)) {
...UpdateFragment
}
}
The query is quite large so I’m not going to copy the whole thing. But doing this to get round the cycle detection means we have more code to maintain, which could be buggy if we miss something.
fragment PortFrag {
uid
...UpdateFragmentCopy
}
fragment AFragment {
uid
name
}
fragment AFragmentCopy {
uid
name
}```