-
Notifications
You must be signed in to change notification settings - Fork 58
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
Upgrade elixir deps #118
Upgrade elixir deps #118
Conversation
EDIT: This was released upstream and this PR was updated to use the new release |
Thanks for the fix! It looks like though that |
Looks like its actually the second assertion that is failing so this one instead const basicallyTheSame = compareSchemas(productsPing.data?._service?.sdl); Test failure from github action log
Any ideas on how to narrow down how they are different? |
Indeed. Sadly the unit test is pretty crude... It checks whether the expected objects are there but doesn't tell us what is missing. Can you check what is the output of the |
Looks like its because the |
This is the rendered SDL "Represents a schema"
schema {
query: Query
}
"""
type ProductVariation {
id: ID!
}
"""
type ProductVariation {
id: ID!
}
type _Service {
sdl: String
}
"a union of all types that use the @key directive"
union _Entity = User | Product
"""
extend type Query {
product(id: ID!): Product
}
"""
type Query @extends {
"""
The _service field on the query root returns SDL
which includes all of the service's types (after any non-federation transforms),
as well as federation directive annotations on the fields and types.
The federation schema modifications (i.e. new types and directive definitions)
should not be included in this SDL.
"""
_service: _Service!
"""
Returns a non-nullable list of _Entity types
and have a single argument with an argument name of representations
and type [_Any!]! (non-nullable list of non-nullable _Any scalars).
The _entities field on the query root must allow a list of _Any scalars
which are "representations" of entities from external services.
These representations should be validated with the following rules:
- Any representation without a __typename: String field is invalid.
- Representations must contain at least the fields defined in the fieldset of a @key directive on the base type.
"""
_entities(representations: [_Any!]!): [_Entity]!
product(id: ID!): Product
}
"The _Any scalar is used to pass representations of entities from external services into the root _entities field for execution."
scalar _Any
"""
type Product @key(fields: "id") @key(fields: "sku package") @key(fields: "sku variation { id }") {
id: ID!
sku: String
package: String
variation: ProductVariation
dimensions: ProductDimension
createdBy: User @provides(fields: "totalProductsCreated")
}
"""
type Product @key(fields: "sku variation { id }") @key(fields: "sku package") @key(fields: "id") {
id: ID!
sku: String
package: String
variation: ProductVariation
dimensions: ProductDimension
createdBy: User @provides(fields: "totalProductsCreated")
_resolveReference: Product
}
"""
type ProductDimension {
size: String
weight: Float
}
"""
type ProductDimension {
size: String
weight: Float
}
"""
extend type User @key(fields: "email") {
email: ID! @external
totalProductsCreated: Int @external
}
"""
type User @extends @key(fields: "email") {
email: ID! @external
totalProductsCreated: Int @external
_resolveReference: User
} |
Fix for rendering these fields is here DivvyPayHQ/absinthe_federation#55 |
Alright this now includes that fix and here are the test results now
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome! Thanks!
This bumps some elixir dependencies and also fixes the docker build