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

fix(repo): cache nightly node_modules per run to avoid stale graph #16216

Merged
merged 2 commits into from
Apr 11, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions .github/workflows/e2e-matrix.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
with:
lookup-only: true
path: '**/node_modules'
key: ${{ runner.os }}-modules-${{ matrix.node_version }}-${{ hashFiles('**/yarn.lock') }}
key: ${{ runner.os }}-modules-${{ matrix.node_version }}-${{ github.run_id }}

- name: Install packages
if: steps.cache-modules.outputs.cache-hit != 'true'
Expand Down Expand Up @@ -350,7 +350,7 @@ jobs:
uses: actions/cache@v3
with:
path: '**/node_modules'
key: ${{ runner.os }}-modules-${{ matrix.node_version }}-${{ hashFiles('**/yarn.lock') }}
key: ${{ runner.os }}-modules-${{ matrix.node_version }}-${{ github.run_id }}

- name: Install packages
if: steps.cache-modules.outputs.cache-hit != 'true'
Expand Down Expand Up @@ -412,9 +412,7 @@ jobs:

- name: Run e2e tests
id: e2e-run
run: |
yarn nx run-many --target=e2e --projects="${{ join(matrix.project) }}" --parallel=1
yarn nx run-many --target=e2e-macos --projects="${{ join(matrix.project) }}" --parallel=1
run: yarn nx run-many -t e2e,e2e-macos -p ${{ matrix.project }}
timeout-minutes: ${{ matrix.os_timeout }}
env:
GIT_AUTHOR_EMAIL: [email protected]
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/e2e-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ jobs:
uses: actions/cache@v3
with:
path: '**/node_modules'
key: windows-modules-${{ matrix.node_version }}-${{ hashFiles('**/yarn.lock') }}
key: ${{ runner.os }}-modules-${{ matrix.node_version }}-${{ github.run_id }}

- name: Install packages
if: steps.cache-modules.outputs.cache-hit != 'true'
Expand Down Expand Up @@ -268,7 +268,7 @@ jobs:
uses: actions/cache@v3
with:
path: '**/node_modules'
key: ${{ runner.os }}-modules-${{ matrix.node_version }}-${{ hashFiles('**/yarn.lock') }}
key: ${{ runner.os }}-modules-${{ matrix.node_version }}-${{ github.run_id }}

- name: Install packages
if: steps.cache-modules.outputs.cache-hit != 'true'
Expand All @@ -280,7 +280,7 @@ jobs:
with:
path: '${{ github.workspace }}/.cypress'
key: ${{ runner.os }}-cypress

- name: Install Cypress
if: steps.cache-cypress.outputs.cache-hit != 'true'
run: npx cypress install
Expand All @@ -292,7 +292,7 @@ jobs:

- name: Run e2e tests
id: e2e-run
run: yarn nx run-many --target=e2e --projects="${{ join(matrix.project) }}" --parallel=1
run: yarn nx run ${{ matrix.project }}:e2e
timeout-minutes: 120
env:
GIT_AUTHOR_EMAIL: [email protected]
Expand Down