diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index c91dfb865d..2099adb73c 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -4,11 +4,17 @@ on: branches: - main +permissions: + contents: read + id-token: write + pull-requests: write + jobs: - # dependencies: - # uses: the-guild-org/shared-config/.github/workflows/changesets-dependencies.yaml@main - # secrets: - # githubToken: ${{ secrets.GUILD_BOT_TOKEN }} + dependencies: + uses: the-guild-org/shared-config/.github/workflows/changesets-dependencies.yml@v1 + if: ${{ github.event.pull_request.title != 'Upcoming Release Changes' }} + secrets: + githubToken: ${{ secrets.GITHUB_TOKEN }} release: uses: the-guild-org/shared-config/.github/workflows/release-snapshot.yml@main diff --git a/packages/plugins/typescript/graphql-request/package.json b/packages/plugins/typescript/graphql-request/package.json index 1d379034c1..d84e85b4bc 100644 --- a/packages/plugins/typescript/graphql-request/package.json +++ b/packages/plugins/typescript/graphql-request/package.json @@ -50,8 +50,8 @@ "devDependencies": { "@graphql-codegen/testing": "1.18.3", "@graphql-tools/schema": "10.0.27", - "graphql-request": "7.2.0", - "node-fetch": "2.7.0" + "@whatwg-node/fetch": "0.10.12", + "graphql-request": "7.2.0" }, "publishConfig": { "directory": "dist", diff --git a/packages/plugins/typescript/graphql-request/tests/test-files/run-example-query.ts b/packages/plugins/typescript/graphql-request/tests/test-files/run-example-query.ts index 94ce975ba8..36faee1f2a 100644 --- a/packages/plugins/typescript/graphql-request/tests/test-files/run-example-query.ts +++ b/packages/plugins/typescript/graphql-request/tests/test-files/run-example-query.ts @@ -1,5 +1,5 @@ import { GraphQLClient } from 'graphql-request'; -import fetch from 'node-fetch'; // FIXME: using `node-fetch` temporarily because `graphql-request@7` uses native fetch, which `nock@13.4` from `@graphql-codegen/testing` does not support +import { fetch } from '@whatwg-node/fetch'; // FIXME: using `node-fetch` temporarily because `graphql-request@7` uses native fetch, which `nock@13.4` from `@graphql-codegen/testing` does not support import { getSdk } from './graphql-request-sdk.js'; export function runExampleQuery(x: number, y: number) { diff --git a/yarn.lock b/yarn.lock index 3855f4ea37..2ec36e6fcb 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1338,6 +1338,11 @@ "@eslint/core" "^0.17.0" levn "^0.4.1" +"@fastify/busboy@^3.1.1": + version "3.2.0" + resolved "https://registry.yarnpkg.com/@fastify/busboy/-/busboy-3.2.0.tgz#13ed8212f3b9ba697611529d15347f8528058cea" + integrity sha512-m9FVDXU3GT2ITSe0UaMA5rU3QkfC/UXtCU8y0gSN/GugTqtVldOBWIB5V6V3sbmenVZUIpU6f+mPEO2+m5iTaA== + "@fastify/merge-json-schemas@^0.1.0": version "0.1.1" resolved "https://registry.yarnpkg.com/@fastify/merge-json-schemas/-/merge-json-schemas-0.1.1.tgz#3551857b8a17a24e8c799e9f51795edb07baa0bc" @@ -2692,6 +2697,14 @@ resolved "https://registry.yarnpkg.com/@urql/introspection/-/introspection-1.2.1.tgz#4d864c681ef540d13322d31b67b45394f2f32d83" integrity sha512-U9FTSISz69EEK3bHWDsqux9JqOeiLzr3eDFBQ5DmHuTLaBsd5mjPdtLRzzzmb9nW1Ygd6IR8YcuM7zeNqQ5lCQ== +"@whatwg-node/disposablestack@^0.0.6": + version "0.0.6" + resolved "https://registry.yarnpkg.com/@whatwg-node/disposablestack/-/disposablestack-0.0.6.tgz#2064a1425ea66194def6df0c7a1851b6939c82bb" + integrity sha512-LOtTn+JgJvX8WfBVJtF08TGrdjuFzGJc4mkP8EdDI8ADbvO7kiexYep1o8dwnt0okb0jYclCDXF13xU7Ge4zSw== + dependencies: + "@whatwg-node/promise-helpers" "^1.0.0" + tslib "^2.6.3" + "@whatwg-node/events@^0.0.2": version "0.0.2" resolved "https://registry.yarnpkg.com/@whatwg-node/events/-/events-0.0.2.tgz#7b7107268d2982fc7b7aff5ee6803c64018f84dd" @@ -2702,6 +2715,14 @@ resolved "https://registry.yarnpkg.com/@whatwg-node/events/-/events-0.0.3.tgz#13a65dd4f5893f55280f766e29ae48074927acad" integrity sha512-IqnKIDWfXBJkvy/k6tzskWTc2NK3LcqHlb+KHGCrjOCH4jfQckRX0NAiIcC/vIqQkzLYw2r2CTSwAxcrtcD6lA== +"@whatwg-node/fetch@0.10.12": + version "0.10.12" + resolved "https://registry.yarnpkg.com/@whatwg-node/fetch/-/fetch-0.10.12.tgz#e821000cd9fc0941c7cebdf3fe13e3a36a610b71" + integrity sha512-XmsCdDgQxbM8ha7xvIbDQyO/iES2ga0wQcM5sb+mugll1F+IzSshOMPK6n1TuqDDgjTwoU01mMa6oRhHWnpDcw== + dependencies: + "@whatwg-node/node-fetch" "^0.8.2" + urlpattern-polyfill "^10.0.0" + "@whatwg-node/fetch@^0.6.0": version "0.6.9" resolved "https://registry.yarnpkg.com/@whatwg-node/fetch/-/fetch-0.6.9.tgz#6cc694cc0378e27b8dfed427c5bf633eda6972b9" @@ -2744,7 +2765,17 @@ fast-url-parser "^1.1.3" tslib "^2.3.1" -"@whatwg-node/promise-helpers@^1.0.0": +"@whatwg-node/node-fetch@^0.8.2": + version "0.8.2" + resolved "https://registry.yarnpkg.com/@whatwg-node/node-fetch/-/node-fetch-0.8.2.tgz#94baa23a12b2204803b627d934146c1cd3a398dc" + integrity sha512-1PihEl0a8hm/AZD/LVRs1lEWCZCo2Q65Xm1goaHeqR314e+/Z7NI7YE10Yser8+2iZFGtv542IYr685o3aaZ/g== + dependencies: + "@fastify/busboy" "^3.1.1" + "@whatwg-node/disposablestack" "^0.0.6" + "@whatwg-node/promise-helpers" "^1.3.2" + tslib "^2.6.3" + +"@whatwg-node/promise-helpers@^1.0.0", "@whatwg-node/promise-helpers@^1.3.2": version "1.3.2" resolved "https://registry.yarnpkg.com/@whatwg-node/promise-helpers/-/promise-helpers-1.3.2.tgz#3b54987ad6517ef6db5920c66a6f0dada606587d" integrity sha512-Nst5JdK47VIl9UcGwtv2Rcgyn5lWtZ0/mhRQ4G8NN2isxpq2TO30iqHzmwoJycjWuyUfg3GFXqP/gFHXeV57IA== @@ -6091,7 +6122,7 @@ nock@13.3.0: lodash "^4.17.21" propagate "^2.0.0" -node-fetch@2.7.0, node-fetch@^2.5.0, node-fetch@^2.6.1, node-fetch@^2.7.0: +node-fetch@^2.5.0, node-fetch@^2.6.1, node-fetch@^2.7.0: version "2.7.0" resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.7.0.tgz#d0f0fa6e3e2dc1d27efcd8ad99d550bda94d187d" integrity sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A== @@ -7644,6 +7675,11 @@ uri-js@^4.2.2: dependencies: punycode "^2.1.0" +urlpattern-polyfill@^10.0.0: + version "10.1.0" + resolved "https://registry.yarnpkg.com/urlpattern-polyfill/-/urlpattern-polyfill-10.1.0.tgz#1b2517e614136c73ba32948d5e7a3a063cba8e74" + integrity sha512-IGjKp/o0NL3Bso1PymYURCJxMPNAf/ILOpendP9f5B6e1rTJgdgiOvgfoT8VxCAdY+Wisb9uhGaJJf3yZ2V9nw== + urlpattern-polyfill@^6.0.2: version "6.0.2" resolved "https://registry.yarnpkg.com/urlpattern-polyfill/-/urlpattern-polyfill-6.0.2.tgz#a193fe773459865a2a5c93b246bb794b13d07256"