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

Issue with running iansu/apollo-schema-check-action@v2 in GitHub Actions workflow #34

Open
alexmf91 opened this issue Jul 28, 2023 · 1 comment

Comments

@alexmf91
Copy link

Description:

I am currently facing an issue while trying to run the iansu/apollo-schema-check-action@v2 in my GitHub Actions workflow. The action is intended to check my GraphQL schema against the specified Apollo graph, but it is encountering an error during execution.

Workflow Configuration:

Here is the relevant portion of the GitHub Actions workflow file where I've implemented the iansu/apollo-schema-check-action@v2:

name: Schema Check

on:
  pull_request:
    types: [opened, reopened, edited, synchronize]
    branches: [master, develop, staging, 'release/*']

jobs:
  check_schema:
    name: Check Schema
    runs-on: ubuntu-latest

    steps:
      - uses: actions/checkout@v2

      - name: Customer API check
        uses: iansu/apollo-schema-check-action@v2

        with:
          title: GRAPH_TITLE
          graph: GRAPH_ID
          variant: GRAPH_VARIANT
          localSchemaFile: ./backend/backend/src/backend-api/generated/backend-schema.graphql
          alwaysComment: true
          failOnError: true
          validationPeriod: P2W
          key: ${{ secrets.APOLLO_KEY }}

        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Error Message:

The specific error message I am encountering when the action runs is as follows:

Error: {}

Expected Behavior:

I expected the iansu/apollo-schema-check-action@v2 to successfully check the GraphQL schema against the specified Apollo graph and provide relevant feedback via comments on pull requests or commits. Additionally, if any schema validation errors are found, the action should fail the workflow due to failOnError: true and show an error message that helps to fix it.

Troubleshooting Attempted:

  1. I verified that the GraphQL schema file backend-schema.graphql is present in the correct location relative to the workflow file.

  2. I made sure that the GitHub Secrets (APOLLO_KEY and GITHUB_TOKEN) are set up correctly and contain the appropriate values.

Request for Assistance:

I kindly request assistance in resolving the issue with the iansu/apollo-schema-check-action@v2 so that I can successfully validate my GraphQL schema against the specified Apollo graph in my GitHub Actions workflow.

Thank you for your help.

@alexmf91 alexmf91 changed the title Subject: Issue with running iansu/apollo-schema-check-action@v2 in GitHub Actions workflow Issue with running iansu/apollo-schema-check-action@v2 in GitHub Actions workflow Jul 28, 2023
@akhilgargjosh
Copy link

akhilgargjosh commented Jan 19, 2024

I am having the same issue @iansu

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

No branches or pull requests

2 participants