Skip to content

Commit 5dc8314

Browse files
authored
chore(deps): CVEs cleanup, updated nock, vite and vitest to latest major (#6457)
1 parent e47a2dd commit 5dc8314

File tree

12 files changed

+399
-318
lines changed

12 files changed

+399
-318
lines changed

integration-tests/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
"slonik": "30.4.4",
3737
"strip-ansi": "7.1.0",
3838
"tslib": "2.8.1",
39-
"vitest": "2.0.5",
39+
"vitest": "3.0.4",
4040
"zod": "3.24.1"
4141
}
4242
}

package.json

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,20 +97,22 @@
9797
"turbo": "2.3.3",
9898
"typescript": "5.7.3",
9999
"vite-tsconfig-paths": "5.1.4",
100-
"vitest": "2.0.5"
100+
"vitest": "3.0.4"
101101
},
102102
"pnpm": {
103103
"overrides.csstype": "To fix type check error https://github.com/JedWatson/react-select/issues/5952",
104104
"overrides.mjml": "Our patch removes html-minifier from mjml-core, we dont need this dependency and its causing false-alarm (CVE https://nvd.nist.gov/vuln/detail/cve-2022-37620)",
105105
"overrides.ip": "There is no update with fix for ip package, we use fork https://github.com/indutny/node-ip/issues/150#issuecomment-2325961380",
106+
"overrides.miniflare": "To address CVE: https://github.com/graphql-hive/console/security/dependabot/245",
106107
"overrides": {
107108
"csstype": "3.1.2",
108109
"[email protected]>html-minifier": "-",
109110
"[email protected]>html-minifier": "-",
110111
"ws@^8.0.0": "^8.18.0",
111112
"ws@*": ">=8.18.0 || >=7.5.10 || >=6.2.3 || >=5.2.4",
112113
"cookie@<0.7.0": "0.7.2",
113-
"ip": "npm:[email protected]"
114+
"ip": "npm:[email protected]",
115+
"miniflare@3>undici": "5.28.5"
114116
},
115117
"patchedDependencies": {
116118

packages/libraries/apollo/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,8 +56,8 @@
5656
"express": "4.21.2",
5757
"graphql": "16.9.0",
5858
"graphql-ws": "5.16.1",
59-
"nock": "14.0.0-beta.19",
60-
"vitest": "2.0.5",
59+
"nock": "14.0.0",
60+
"vitest": "3.0.4",
6161
"ws": "8.18.0"
6262
},
6363
"publishConfig": {

packages/libraries/core/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,9 +57,9 @@
5757
"@types/async-retry": "1.4.8",
5858
"@types/lodash.sortby": "4.7.9",
5959
"graphql": "16.9.0",
60-
"nock": "14.0.0-beta.19",
60+
"nock": "14.0.0",
6161
"tslib": "2.8.1",
62-
"vitest": "2.0.5"
62+
"vitest": "3.0.4"
6363
},
6464
"publishConfig": {
6565
"registry": "https://registry.npmjs.org",

packages/libraries/yoga/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,8 @@
5959
"@whatwg-node/fetch": "0.10.1",
6060
"graphql-ws": "5.16.1",
6161
"graphql-yoga": "5.10.8",
62-
"nock": "14.0.0-beta.19",
63-
"vitest": "2.0.5",
62+
"nock": "14.0.0",
63+
"vitest": "3.0.4",
6464
"ws": "8.18.0"
6565
},
6666
"publishConfig": {

packages/libraries/yoga/tests/yoga.spec.ts

Lines changed: 12 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import { createClient } from 'graphql-ws';
44
import { useServer as useWSServer } from 'graphql-ws/lib/use/ws';
55
import { createLogger, createSchema, createYoga } from 'graphql-yoga';
66
import nock from 'nock';
7-
import { beforeAll, describe, expect, test, vi } from 'vitest';
7+
import { afterEach, describe, expect, test, vi } from 'vitest';
88
import { WebSocket, WebSocketServer } from 'ws';
99
import { useDeferStream } from '@graphql-yoga/plugin-defer-stream';
1010
import { useDisableIntrospection } from '@graphql-yoga/plugin-disable-introspection';
@@ -14,7 +14,7 @@ import { Response } from '@whatwg-node/fetch';
1414
import { createHiveTestingLogger } from '../../core/tests/test-utils';
1515
import { createHive, useHive } from '../src/index.js';
1616

17-
beforeAll(() => {
17+
afterEach(() => {
1818
nock.cleanAll();
1919
});
2020

@@ -375,17 +375,14 @@ test('reports usage with response cache', async ({ expect }) => {
375375
const graphqlScope = nock('http://localhost')
376376
.post('/usage', body => {
377377
usageCount++;
378-
expect(body.map).toMatchInlineSnapshot(`
379-
{
380-
f25063b60ab942d0c0d14cdd9cd3172de2e7ebc4: {
381-
fields: [
382-
Query.hi,
383-
],
384-
operation: {hi},
385-
operationName: anonymous,
386-
},
387-
}
388-
`);
378+
379+
expect(body.map).toEqual({
380+
f25063b60ab942d0c0d14cdd9cd3172de2e7ebc4: {
381+
fields: ['Query.hi'],
382+
operation: '{hi}',
383+
operationName: 'anonymous',
384+
},
385+
});
389386

390387
return true;
391388
})
@@ -432,7 +429,7 @@ test('reports usage with response cache', async ({ expect }) => {
432429
await new Promise<void>((resolve, reject) => {
433430
const timeout = setTimeout(() => {
434431
resolve();
435-
}, 1000);
432+
}, 2000);
436433
let requestCount = 0;
437434

438435
graphqlScope.on('request', () => {
@@ -459,8 +456,8 @@ test('reports usage with response cache', async ({ expect }) => {
459456
}
460457
})().catch(reject);
461458
});
462-
expect(usageCount).toBe(3);
463459
graphqlScope.done();
460+
expect(usageCount).toBe(3);
464461
});
465462

466463
test('does not report usage for operation that does not pass validation', async ({ expect }) => {

packages/services/api/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@
6767
"supertokens-node": "16.7.5",
6868
"tslib": "2.8.1",
6969
"undici": "6.21.1",
70-
"vitest": "2.0.5",
70+
"vitest": "3.0.4",
7171
"zod": "3.24.1",
7272
"zod-validation-error": "3.4.0"
7373
}

packages/services/broker-worker/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
"itty-router": "4.2.2",
1616
"toucan-js": "3.4.0",
1717
"undici": "6.21.1",
18-
"vitest": "2.0.5",
18+
"vitest": "3.0.4",
1919
"workers-loki-logger": "0.1.15",
2020
"zod": "3.24.1"
2121
}

packages/services/demo/federation/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,6 @@
1111
"graphql-yoga": "5.10.8"
1212
},
1313
"devDependencies": {
14-
"wrangler": "3.100.0"
14+
"wrangler": "3.107.2"
1515
}
1616
}

packages/web/app/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@
130130
"urql": "4.1.0",
131131
"use-debounce": "10.0.4",
132132
"valtio": "1.13.2",
133-
"vite": "5.4.12",
133+
"vite": "6.0.11",
134134
"vite-tsconfig-paths": "5.1.4",
135135
"wonka": "6.3.4",
136136
"yup": "1.6.1",

0 commit comments

Comments
 (0)