-
Notifications
You must be signed in to change notification settings - Fork 575
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Repository overall cleanup - dependency updates, migration of configs…
… etc (#3532) * chore(deps): update dependency eslint to v9 * Fix ESLint * Update eslint config * No need for a huge matrix for fed compat * Cleanup * Update dependencies * Go * Bump more * Go * chore(dependencies): updated changesets for modified dependencies * Go * Hmm' * chore(dependencies): updated changesets for modified dependencies * Bump envelop-auth * Fix website build * chore(dependencies): updated changesets for modified dependencies * Prettier * Ignore husky * Prettier * Remove leaks * Fix * Fix * Patch Jest leak detector for Node 20 * ESLint needs more memory * Hmm * More details in the changeset --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
- Loading branch information
1 parent
bcf7040
commit 57e7701
Showing
137 changed files
with
11,095 additions
and
6,073 deletions.
There are no files selected for viewing
6 changes: 6 additions & 0 deletions
6
.changeset/@graphql-yoga_apollo-managed-federation-3532-dependencies.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"@graphql-yoga/apollo-managed-federation": patch | ||
--- | ||
dependencies updates: | ||
- Updated dependency [`@graphql-tools/federation@^3.0.0` ↗︎](https://www.npmjs.com/package/@graphql-tools/federation/v/3.0.0) (from `2.1.0`, in `dependencies`) | ||
- Added dependency [`@whatwg-node/disposablestack@^0.0.5` ↗︎](https://www.npmjs.com/package/@whatwg-node/disposablestack/v/0.0.5) (to `dependencies`) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
"@graphql-yoga/plugin-jwt": patch | ||
--- | ||
dependencies updates: | ||
- Updated dependency [`graphql@^15.2.0 || ^16.0.0` ↗︎](https://www.npmjs.com/package/graphql/v/15.2.0) (from `^16.5.0`, in `peerDependencies`) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
'@graphql-yoga/typed-event-target': patch | ||
--- | ||
|
||
Improve typings for `TypedEventTarget<TEvent>`, so `addEventListener` and `removeEventListener` methods now expect `type` to be the `type` property of `TEvent`, and `dispatchEvent` expects to get `TEvent`. | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
--- | ||
'@graphql-yoga/apollo-managed-federation': minor | ||
--- | ||
|
||
`supergraphManager` option is not available anymore, you can pass `SupergraphManager` directly to | ||
the plugin instead; | ||
|
||
```diff | ||
- useManagedFederation({ supergraphManager }) | ||
+ useManagedFederation(supergraphManager) | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,7 +14,7 @@ concurrency: | |
cancel-in-progress: true | ||
|
||
jobs: | ||
typecheck: | ||
check: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repository | ||
|
@@ -45,14 +45,23 @@ jobs: | |
with: | ||
path: | | ||
${{ steps.pnpm-store.outputs.PATH }} | ||
**/node_modules | ||
key: ${{ runner.os }}-pnpm-store-graphql-v16-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: | | ||
${{ runner.os }}-pnpm-store-graphql-v16- | ||
- name: Install Dependencies | ||
run: pnpm i --no-frozen-lockfile # no frozen-lockfile because we change the resolutions | ||
|
||
- name: Prettier | ||
run: pnpm prettier:check | ||
|
||
- name: Lint | ||
run: pnpm lint | ||
env: | ||
DEBUG: 'eslint:*' | ||
NODE_OPTIONS: '--max-old-space-size=8192' | ||
NODE_NO_WARNINGS: true | ||
|
||
- name: Build Packages | ||
run: pnpm build | ||
|
||
|
@@ -62,19 +71,16 @@ jobs: | |
- name: Test ESM & CJS exports integrity | ||
run: pnpm bob check | ||
|
||
- name: Prettier | ||
run: pnpm prettier:check | ||
|
||
- name: eslint | ||
run: pnpm lint | ||
- name: ESM Integration test | ||
run: pnpm --filter example-node-esm run test | ||
|
||
unit: | ||
name: unit / nodejs v${{ matrix.node-version }} / graphql v${{ matrix.graphql-version }} | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [18, 20, 22] | ||
graphql-version: ['15.8.0', '16.6.0'] | ||
graphql-version: ['15.8.0', '16.9.0'] | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 | ||
|
@@ -96,7 +102,6 @@ jobs: | |
with: | ||
path: | | ||
${{ steps.pnpm-store.outputs.PATH }} | ||
**/node_modules | ||
key: | ||
${{ runner.os }}-pnpm-store-graphql-v${{ matrix.graphql-version }}-${{ | ||
hashFiles('**/pnpm-lock.yaml') }} | ||
|
@@ -119,6 +124,20 @@ jobs: | |
max_attempts: 3 | ||
command: pnpm run test --ci | ||
|
||
- name: Run Unit Tests | ||
uses: nick-fields/retry@v3 | ||
with: | ||
timeout_minutes: 10 | ||
max_attempts: 3 | ||
command: pnpm run test --ci | ||
|
||
- name: Run Leak Tests | ||
uses: nick-fields/retry@v3 | ||
with: | ||
timeout_minutes: 10 | ||
max_attempts: 3 | ||
command: pnpm run test:unit:leaks --ci | ||
|
||
integration: | ||
name: integration / nodejs v${{ matrix.node-version }} / graphql v${{ matrix.graphql-version }} | ||
runs-on: ubuntu-latest | ||
|
@@ -147,7 +166,6 @@ jobs: | |
with: | ||
path: | | ||
${{ steps.pnpm-store.outputs.PATH }} | ||
**/node_modules | ||
key: | ||
${{ runner.os }}-pnpm-store-graphql-v${{ matrix.graphql-version }}-${{ | ||
hashFiles('**/pnpm-lock.yaml') }} | ||
|
@@ -163,130 +181,42 @@ jobs: | |
- name: Build Packages | ||
run: pnpm build | ||
|
||
- name: Run Tests | ||
- name: Run Integration Tests | ||
uses: nick-fields/retry@v3 | ||
with: | ||
timeout_minutes: 10 | ||
max_attempts: 3 | ||
command: pnpm test:integration --ci | ||
|
||
leaks: | ||
name: leaks / nodejs v${{ matrix.node-version }} / graphql v${{ matrix.graphql-version }} | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [18, 22] | ||
graphql-version: ['15.8.0', '16.6.0'] | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 | ||
|
||
- name: Install Node | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
|
||
- name: Install pnpm | ||
uses: pnpm/[email protected] | ||
|
||
- name: Get pnpm store path | ||
id: pnpm-store | ||
run: echo "PATH=$(pnpm store path)" >> $GITHUB_OUTPUT | ||
|
||
- name: Cache pnpm | ||
uses: actions/cache@v4 | ||
with: | ||
path: | | ||
${{ steps.pnpm-store.outputs.PATH }} | ||
**/node_modules | ||
key: | ||
${{ runner.os }}-pnpm-store-graphql-v${{ matrix.graphql-version }}-${{ | ||
hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: | | ||
${{ runner.os }}-pnpm-store-graphql-v${{ matrix.graphql-version }}- | ||
- name: Set GraphQL Version | ||
run: node scripts/override-graphql-version.js ${{ matrix.graphql-version }} | ||
|
||
- name: Install Dependencies | ||
run: pnpm i --no-frozen-lockfile # no frozen-lockfile because we change the resolutions | ||
|
||
- name: Build Packages | ||
run: pnpm build | ||
|
||
- name: Run Tests | ||
- name: Run Leak Tests | ||
uses: nick-fields/retry@v3 | ||
with: | ||
timeout_minutes: 10 | ||
max_attempts: 3 | ||
command: pnpm test:leaks --ci | ||
command: pnpm test:integration:leaks --ci | ||
|
||
esm: | ||
apollo-federation-compatibility: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 | ||
|
||
- name: Install Node | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version-file: '.node-version' | ||
|
||
- name: Install pnpm | ||
uses: pnpm/[email protected] | ||
|
||
- name: Get pnpm store path | ||
id: pnpm-store | ||
run: echo "PATH=$(pnpm store path)" >> $GITHUB_OUTPUT | ||
|
||
- name: Cache pnpm | ||
uses: actions/cache@v4 | ||
with: | ||
path: | | ||
${{ steps.pnpm-store.outputs.PATH }} | ||
**/node_modules | ||
key: ${{ runner.os }}-pnpm-store-graphql-v16-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: | | ||
${{ runner.os }}-pnpm-store-graphql-v16- | ||
- name: Install Dependencies | ||
run: pnpm i --no-frozen-lockfile # no frozen-lockfile because we change the resolutions | ||
|
||
- name: Build Packages | ||
run: pnpm build | ||
|
||
- name: Run Tests | ||
run: pnpm --filter example-node-esm run test | ||
|
||
apollo-federation-compatibility: | ||
strategy: | ||
matrix: | ||
node-version: [18, 20, 22] | ||
graphql-version: ['15.8.0', '16.6.0'] | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout Repository | ||
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 | ||
- name: Install Node | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
- name: Install pnpm | ||
uses: pnpm/[email protected] | ||
- name: Get pnpm store path | ||
id: pnpm-store | ||
run: echo "PATH=$(pnpm store path)" >> $GITHUB_OUTPUT | ||
- name: Cache pnpm | ||
uses: actions/cache@v4 | ||
with: | ||
path: | | ||
${{ steps.pnpm-store.outputs.PATH }} | ||
**/node_modules | ||
key: | ||
${{ runner.os }}-pnpm-store-graphql-v${{ matrix.graphql-version }}-${{ | ||
hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: | | ||
${{ runner.os }}-pnpm-store-graphql-v${{ matrix.graphql-version }}- | ||
- name: Install Dependencies | ||
run: pnpm i --no-frozen-lockfile | ||
- name: Build Packages | ||
|
@@ -309,54 +239,6 @@ jobs: | |
failOnRequired: true | ||
debug: true | ||
|
||
# TODO: have the example and packages use singleton nestjs dependencies | ||
# but without using .pnpmfile.cjs because it causes issues with renovate: https://github.com/dotansimha/graphql-yoga/pull/2622 | ||
# nestjs-apollo-federation-compatibility: | ||
# runs-on: ubuntu-latest | ||
# steps: | ||
# - name: Checkout Repository | ||
# uses: actions/checkout@v3 | ||
# - name: Install Node | ||
# uses: actions/setup-node@v3 | ||
# with: | ||
# node-version: ${{ matrix.node-version }} | ||
# - name: Install pnpm | ||
# uses: pnpm/[email protected] | ||
# - name: Get pnpm store path | ||
# id: pnpm-store | ||
# run: echo "PATH=$(pnpm store path)" >> $GITHUB_OUTPUT | ||
# - name: Cache pnpm | ||
# uses: actions/cache@v3 | ||
# with: | ||
# path: | | ||
# ${{ steps.pnpm-store.outputs.PATH }} | ||
# **/node_modules | ||
# key: ${{ runner.os }}-pnpm-store-graphql-v${{ matrix.graphql-version }}-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
# restore-keys: | | ||
# ${{ runner.os }}-pnpm-store-graphql-v${{ matrix.graphql-version }}- | ||
# - name: Install Dependencies | ||
# run: pnpm i | ||
# - name: Build Packages | ||
# run: pnpm build | ||
# - name: Bundle NestJS Apollo Federation Subgraph Example | ||
# run: pnpm --filter=example-nestjs-apollo-federation-compatibility build | ||
# - name: Install Rover | ||
# run: curl -sSL https://rover.apollo.dev/nix/v0.11.1 | sh | ||
# - name: Add Rover to PATH | ||
# run: echo "$HOME/.rover/bin" >> $GITHUB_PATH | ||
# - name: Apollo Federation Subgraph Compatibility | ||
# uses: apollographql/federation-subgraph-compatibility@v1 | ||
# with: | ||
# workingDirectory: examples/nestjs-apollo-federation-compatibility | ||
# compose: docker-compose.yaml | ||
# schema: schema.graphql | ||
# path: /graphql | ||
# # no token = no comment | ||
# # token: ${{ secrets.GITHUB_TOKEN }} | ||
# failOnWarning: true | ||
# failOnRequired: true | ||
# debug: true | ||
|
||
e2e: | ||
strategy: | ||
fail-fast: false | ||
|
@@ -393,7 +275,6 @@ jobs: | |
with: | ||
path: | | ||
${{ steps.pnpm-store.outputs.PATH }} | ||
**/node_modules | ||
key: ${{ runner.os }}-pnpm-store-graphql-v16-${{ hashFiles('**/pnpm-lock.yaml') }} | ||
restore-keys: | | ||
${{ runner.os }}-pnpm-store-graphql-v16- | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,5 +8,5 @@ | |
"moduleResolution": "node16" | ||
}, | ||
"include": ["./start-server.ts"], | ||
"exclude": [] | ||
"exclude": ["**/node_modules"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.