You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In schema.graphql, schema @link(url: "https:\/\/specs.apollo.dev\/federation\/v2.5", import: [ "@key", "FieldSet", "@shareable" ]) { query: Query mutation: Mutation } where supposed to have @tag as well schema @link(url: "https:\/\/specs.apollo.dev\/federation\/v2.5", import: [ "@key", "FieldSet", "@shareable", "@tag" ]) { query: Query mutation: Mutation }
I can find this directive in schema "The @tag directive is used to apply arbitrary string\nmetadata to a schema location. Custom tooling can use\nthis metadata during any step of the schema delivery flow,\nincluding composition, static analysis, and documentation.\n\ninterface Book {\n id: ID! @tag(name: \"your-value\")\n title: String!\n author: String!\n}" directive @tag(name: String!) repeatable on SCALAR | OBJECT | FIELD_DEFINITION | ARGUMENT_DEFINITION | INTERFACE | UNION | ENUM | ENUM_VALUE | INPUT_OBJECT | INPUT_FIELD_DEFINITION
But we need the @tag in import for the Federation 2 tag works
What is expected?
The @tag directive should be generate in import string schema @link(url: "https:\/\/specs.apollo.dev\/federation\/v2.5", import: [ "@key", "FieldSet", "@shareable", "@tag" ]) { query: Query mutation: Mutation }
What is actually happening?
Now it is not generating in import string and not working for Federation 2 tag function.
Relevant log output
No response
Additional context
No response
The text was updated successfully, but these errors were encountered:
Product
Hot Chocolate
Version
13.9.7
Link to minimal reproduction
https://www.apollographql.com/docs/federation/federated-schemas/federated-directives/#importing-directives
Steps to reproduce
Assign tag to fields which needed to be used for contracts.
[Tag("beta")] public string Country { get; set; }
Generate schema from code.
var schema = await builder.Services .AddGraphQLServer() .UseField<FieldValidationMiddleware>() .ModifyRequestOptions(opt => opt.IncludeExceptionDetails = builder.Environment.IsDevelopment()) .AddApolloFederation() .AddQueryType<Query>() .AddMutationType<Mutation>() .AllowIntrospection(builder.Configuration.GetValue<bool>("AllowGraphQLIntrospection")) .BuildSchemaAsync();
In schema.graphql,
schema @link(url: "https:\/\/specs.apollo.dev\/federation\/v2.5", import: [ "@key", "FieldSet", "@shareable" ]) { query: Query mutation: Mutation }
where supposed to have @tag as wellschema @link(url: "https:\/\/specs.apollo.dev\/federation\/v2.5", import: [ "@key", "FieldSet", "@shareable", "@tag" ]) { query: Query mutation: Mutation }
I can find this directive in schema
"The @tag directive is used to apply arbitrary string\nmetadata to a schema location. Custom tooling can use\nthis metadata during any step of the schema delivery flow,\nincluding composition, static analysis, and documentation.\n\ninterface Book {\n id: ID! @tag(name: \"your-value\")\n title: String!\n author: String!\n}" directive @tag(name: String!) repeatable on SCALAR | OBJECT | FIELD_DEFINITION | ARGUMENT_DEFINITION | INTERFACE | UNION | ENUM | ENUM_VALUE | INPUT_OBJECT | INPUT_FIELD_DEFINITION
But we need the @tag in import for the Federation 2 tag works
What is expected?
The @tag directive should be generate in import string
schema @link(url: "https:\/\/specs.apollo.dev\/federation\/v2.5", import: [ "@key", "FieldSet", "@shareable", "@tag" ]) { query: Query mutation: Mutation }
What is actually happening?
Now it is not generating in import string and not working for Federation 2 tag function.
Relevant log output
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: