Skip to content

[do not merge] Introduce extra requests on the initial path of the app #17213

[do not merge] Introduce extra requests on the initial path of the app

[do not merge] Introduce extra requests on the initial path of the app #17213

Workflow file for this run

name: Typecheck
on: [pull_request, workflow_dispatch]
jobs:
typecheck:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
# Get the yarn cache path.
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "{dir}={$(yarn config get cacheFolder)}" >> $GITHUB_OUTPUT
- name: Restore yarn cache
uses: actions/cache@v3
id: yarn-cache
with:
path: |
${{ steps.yarn-cache-dir-path.outputs.dir }}
**/node_modules
key: yarn-cache-folder-${{ hashFiles('**/yarn.lock', '.yarnrc.yml') }}
restore-keys: "yarn-cache-folder-"
# Actually install packages with Yarn
- name: Install packages
run: yarn install
env:
YARN_CHECKSUM_BEHAVIOR: "update"
- name: Run tsc
run: yarn typecheck
gql:
# Intentionally disabled for now to avoid repeated CI failures
# TODO Fix this at some point?
if: ${{ false }}
#if: github.event_name == 'workflow_dispatch' || startsWith(github.event.pull_request.head.repo.full_name, 'replayio/')
name: GraphQL schema types
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
# Get the yarn cache path.
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "{dir}={$(yarn config get cacheFolder)}" >> $GITHUB_OUTPUT
- name: Restore yarn cache
uses: actions/cache@v3
id: yarn-cache
with:
path: |
${{ steps.yarn-cache-dir-path.outputs.dir }}
**/node_modules
key: yarn-cache-folder-${{ hashFiles('**/yarn.lock', '.yarnrc.yml') }}
restore-keys: "yarn-cache-folder-"
# Actually install packages with Yarn
- name: Install packages
run: yarn install
env:
YARN_CHECKSUM_BEHAVIOR: "update"
- name: Fetch GraphQL schema
run: yarn gql:schema
env:
HASURA_KEY: ${{ secrets.HASURA_ADMIN_SECRET }}
- name: Apollo codegen
run: rm -rf packages/shared/graphql/generated/*.ts && yarn gql:gen
- name: Checks if types match
run: git diff --quiet HEAD -- packages/shared/graphql/generated