-
Notifications
You must be signed in to change notification settings - Fork 257
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
misleading composition hints when using @inaccessible
#2398
Comments
I don't care too much if we want to change this, but I also don't think the current behaviour is particularly wrong in the first place (so fwiw, I'd vote for keeping it, but mostly just on the argument of avoiding a change). I suspect the underlying issue here, and what is truly misleading, is our UX around hints. And part of it is probably my fault for dropping the ball on apollographql/federation-rs#200, so I'll try to get that finished. But it seems here that getting this is interpreted as misleading because nothing done is wrong, but this hint is always generated when nothing is wrong. Many do not highlight at problem, and that's the case of that one, they are just some information, that may or may not be useful to any particular user (we added levels to hints to try to convey this better, and the problem I linked to above is exactly the fact that those levels are not surfaced by rover at the moment). The hint here, To be clear, one could question how useful that hint is, and I would agree with that line of questions. This hint and a few others were added before fed 2 was released out of fear that some user would be surprised, and maybe dislike, some of the added flexibility of fed2, and it was an attempt at helping that. I have my own doubts on their particular usefulness, but that's probably a larger topic. To the specific point here,
Again, I don't personally care about which of those 2 arguments we want to use, I mostly think it's an unimportant choice and we should stick to the status quo. But I don't get the feeling this ticket was created to debate those 2 arguments, I suspect it was rather created on the misunderstanding that getting this hint is not in any way an indication that there is something wrong or invalid in the subgraphs. |
Ticket was created as those hints are just noise and could be misleading users that there is something wrong with the graph. Since AFAIK there are two major use cases for usage of
In this case, my intent is to never have those fields exposed in the supergraph and the "hint" is just a noise.
If I'm slowly evolving my schema by adding |
Given a simple schema definition
We are getting misleading composition hints when other subgraphs do not include
unit
field:Inaccessible fields may to be present in other subgraphs as they could be used for private keys, etc.
Repro available in apollographql/apollo-federation-subgraph-compatibility repo (
apollo-server
andfederation-jvm
implementations were updated to v2.3 tests).To run tests, execute following make target from root dir:
The text was updated successfully, but these errors were encountered: