Skip to content
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

include scalars types returning by computed fields in generated schema (fix #3650) #3651

Merged

Conversation

rakeshkky
Copy link
Member

Description

Scalar types returning by scalar computed fields are not included in generated GraphQL schema. And hence the introspection query and GraphQL queries fail. This PR fixes the same.

Affected components

  • Server
  • Console
  • CLI
  • Docs
  • Community Content
  • Build System
  • Tests
  • Other (list it)

Related Issues

Fix #3650

Solution and Design

Include the PGScalarType of scalar computed fields in additionalScalars while generating GraphQL context.

Steps to test and verify

Add a scalar computed field which returns uncommon scalar type and perform the graphql query.

Limitations, known bugs & workarounds

Server checklist

Catalog upgrade

Does this PR change Hasura Catalog version?

  • No
  • Yes

Metadata

Does this PR add a new Metadata feature?

  • No
  • Yes

GraphQL

  • No new GraphQL schema is generated
  • New GraphQL schema is being generated:
    Fixes the GraphQL schema generation for scalar computed fields.

Breaking changes

  • No Breaking changes
  • There are breaking changes

@rakeshkky rakeshkky added the c/server Related to server label Jan 7, 2020
@rakeshkky rakeshkky self-assigned this Jan 7, 2020
@netlify
Copy link

netlify bot commented Jan 7, 2020

Deploy preview for hasura-docs ready!

Built with commit 2391d86

https://deploy-preview-3651--hasura-docs.netlify.com

Copy link
Contributor

@lexi-lambda lexi-lambda left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hm, actually, I initially approved this PR, but it looks like the tests are failing in CI. @rakeshkky, could you figure out what’s going wrong?

lexi-lambda
lexi-lambda previously approved these changes Jan 8, 2020
@hasura-bot
Copy link
Contributor

Review app for commit 51d289b deployed to Heroku: https://hge-ci-pull-3651.herokuapp.com
Docker image for server: hasura/graphql-engine:pull3651-51d289b1

@hasura-bot
Copy link
Contributor

Review app for commit 44d06a1 deployed to Heroku: https://hge-ci-pull-3651.herokuapp.com
Docker image for server: hasura/graphql-engine:pull3651-44d06a1e

@hasura-bot
Copy link
Contributor

Review app for commit 1d65dcb deployed to Heroku: https://hge-ci-pull-3651.herokuapp.com
Docker image for server: hasura/graphql-engine:pull3651-1d65dcba

@hasura-bot
Copy link
Contributor

Review app for commit 2391d86 deployed to Heroku: https://hge-ci-pull-3651.herokuapp.com
Docker image for server: hasura/graphql-engine:pull3651-2391d869

@lexi-lambda lexi-lambda merged commit 319606b into hasura:master Jan 11, 2020
@hasura-bot
Copy link
Contributor

Review app https://hge-ci-pull-3651.herokuapp.com is deleted

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c/server Related to server
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error querying computed double precision.
3 participants