-
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
_service { sdl } output doesn't contain custom directive arguments #1666
Comments
I'm using const { printSubgraphSchema } = require('@apollo/subgraph');
const resolvers = {
Query: {
_service: (_parent, _args, _context, info) => ({ sdl: printSubgraphSchema(info.schema) }),
}
} type _Service {
sdl: String
}
type Query {
_service: _Service
} |
bad news: we're likely removing good news: this is fixed in #1554 unsettling news: we have tests for this, so i don't know why it isn't working. but it's very unlikely to be broken in the same way: #1554 handles all subgraph schema manipulation in the AST, which is considerably less invasive and prone to this kind of thing. |
This still seems to be an issue, I'm not seen the deprecated directive in the schema. |
The As for this issue, it should be fixed now (nor have we removed |
I get that's a built-in, interesting that's not working on my end. I'll try to see if I find something. |
@pcmanus it working for individual subgraphs directly, seem that there is an issue with the gateway, because it might be getting lost when the schema is printed to sdl and consumed by the federation gateway. Opening the subgraph directly the deprecated warning is there, but not working going to the supergraph endpoint |
@harbolaez I'm the author of the issue. At the time I was using gateway/subgraph 2.0.5 and I applied my first comment fix which solved that issue. I no longer work on that project, so I don't know if it works for the most recent versions. |
When I make the
{ _service { sdl } }
query, the output doesn't contain any custom directives arguments. UsingprintSubgraphSchema
outputs the expected result.Typedef example:
Service output:
printSubgraphSchema
output:Using version:
"@apollo/subgraph": "2.0.0-preview.8"
The text was updated successfully, but these errors were encountered: