Skip to content

Commit 2bbd090

Browse files
committed
Update dependencies
Versions not updated: -------------------- * Apollo client V3 → V4: A major upgrade * Headless UI + Tailwind: Major upgrades, separate ticket * Rollup commonjs/ts plugins: need config changes * React: Sticking to V8 * Cypress: Major upgrade, needs coordination with node version * next: Possibly straight upgrade, held for now * zod: Major upgrade Other version notes: -------------------- * react-hook-form: Bound to version 7.66.1, 7.67 has a typing bug, which is fixed in main, but has not been published to NPM yet. * uuid: Bound to version 11.1.0, 12+ versions have problems with CJS/MJS import styles, and just don't work properly with our setup. Eventually should be replaced with `crypto.randonUUID()` calls, but we need HTTPS support in the CI test runs before we can do that. On Zod: ------- The react-hooks eslint plugin version has dependency on Zod V4, while we are still using V3. Normally this would not be a problem, and under no-packaging-bugs scenario yarn would install the multiple versions of the package in correct sub-directories and TypeScript and code bundlers would be able to load the correct version when needed. But sadly there is a packaging bug in @hookform/resolvers package (at leas on the old non-updated version we are using), that being a missing peer-deps declaration to the required zod version. I.e. the resolver imports zod, but does not declare that it specifically needs the V3, thus it is possible that under certain scenarios, the V4 of zod gets installed to the root node_modules, resulting that version being loaded into the resolves code. Specifically this happens when trying to build the Docker image. Fix: Added a dependency to zip v3 to the root package.json of our repo, this is not a true shared dependency, but this ensures that V3 gets installed as the deduplicated primary version, and v4 gets nested under the eslint plugin's internal node_modules directory.
1 parent 22f7e09 commit 2bbd090

File tree

22 files changed

+6248
-5870
lines changed

22 files changed

+6248
-5870
lines changed

codegen/package.json

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,18 +9,18 @@
99
"ts:check": "yarn tsc --noEmit"
1010
},
1111
"dependencies": {
12-
"@babel/core": "^7.28.3",
13-
"@graphql-codegen/add": "^5.0.3",
14-
"@graphql-codegen/cli": "^5.0.7",
15-
"@graphql-codegen/introspection": "^4.0.3",
16-
"@graphql-codegen/typescript": "^4.1.6",
17-
"@graphql-codegen/typescript-operations": "^4.6.1",
12+
"@babel/core": "^7.28.5",
13+
"@graphql-codegen/add": "^6.0.0",
14+
"@graphql-codegen/cli": "^6.1.0",
15+
"@graphql-codegen/introspection": "^5.0.0",
16+
"@graphql-codegen/typescript": "^5.0.6",
17+
"@graphql-codegen/typescript-operations": "^5.0.6",
1818
"@graphql-codegen/typescript-react-apollo": "^4.3.3",
19-
"@graphql-tools/load": "^8.1.2",
20-
"@graphql-tools/merge": "^9.1.1",
21-
"@graphql-tools/schema": "^10.0.25",
19+
"@graphql-tools/load": "^8.1.7",
20+
"@graphql-tools/merge": "^9.1.6",
21+
"@graphql-tools/schema": "^10.0.30",
2222
"@parcel/watcher": "^2.5.0",
23-
"graphql": "^16.11.0",
23+
"graphql": "^16.12.0",
2424
"graphql-tag": "^2.12.6"
2525
}
2626
}

cypress/cypress.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
22
// @ts-ignore
3-
import cypressGrepPlugin from '@cypress/grep/src/plugin';
3+
import { plugin as cypressGrepPlugin } from '@cypress/grep/plugin';
44
import { defineConfig } from 'cypress';
55
import { GenerateCtrfReport } from 'cypress-ctrf-json-reporter';
66
import cypressSplit from 'cypress-split';

cypress/package.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,21 @@
1313
"cy:run:video": "CYPRESS_BASE_URL=${CYPRESS_BASE_URL:-http://localhost:3300} cypress run --browser chrome --config-file ./cypress.config.video.ts"
1414
},
1515
"dependencies": {
16-
"@4tw/cypress-drag-drop": "^2.2.5",
17-
"@cypress/grep": "^4.1.1",
16+
"@4tw/cypress-drag-drop": "^2.3.1",
17+
"@cypress/grep": "^5.0.0",
1818
"@hsl/jore4-test-db-manager": "1.0.0",
1919
"@hsl/timetables-data-inserter": "1.0.0",
20-
"cypress": "^14.5.4",
21-
"cypress-ctrf-json-reporter": "^0.0.12",
22-
"cypress-split": "^1.24.21",
20+
"cypress": "^15.7.1",
21+
"cypress-ctrf-json-reporter": "^0.0.13",
22+
"cypress-split": "^1.24.25",
2323
"lodash": "^4.17.21",
24-
"luxon": "^3.7.1",
24+
"luxon": "^3.7.2",
2525
"qs": "^6.14.0"
2626
},
2727
"devDependencies": {
28-
"@types/lodash": "^4.17.20",
28+
"@types/lodash": "^4.17.21",
2929
"@types/luxon": "^3.7.1",
3030
"@types/qs": "^6.14.0",
31-
"find-test-names": "^1.29.18"
31+
"find-test-names": "^1.29.19"
3232
}
3333
}

cypress/pageObjects/RoutePropertiesForm.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,7 @@ import { TerminusNameInputs, TerminusValues } from './TerminusNameInputs';
1010
import { ValidityPeriodFormInfo } from './ValidityPeriodForm';
1111

1212
export interface RouteFormInfo
13-
extends ValidityPeriodFormInfo,
14-
PriorityFormInfo {
13+
extends ValidityPeriodFormInfo, PriorityFormInfo {
1514
finnishName?: string;
1615
label?: string;
1716
variant?: string;

cypress/pageObjects/StopForm.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@ import { PriorityForm, PriorityFormInfo } from './PriorityForm';
55
import { ValidityPeriodFormInfo } from './ValidityPeriodForm';
66

77
export interface BaseStopFormInfo
8-
extends ValidityPeriodFormInfo,
9-
PriorityFormInfo {
8+
extends ValidityPeriodFormInfo, PriorityFormInfo {
109
locationFin?: string;
1110
locationSwe?: string;
1211
longitude?: string;

cypress/support/e2e.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import './commands';
1818

1919
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
2020
// @ts-ignore
21-
import registerCypressGrep from '@cypress/grep';
21+
import { register as registerCypressGrep } from '@cypress/grep';
2222
import { Settings } from 'luxon';
2323

2424
registerCypressGrep();

eslint.config.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ function getExtends({
8282
? [
8383
react.configs.flat['recommended'],
8484
react.configs.flat['jsx-runtime'],
85-
reactHooks.configs['recommended-latest'],
85+
reactHooks.configs.flat['recommended-latest'],
8686
jsxA11y.flatConfigs['recommended'],
8787
]
8888
: []),

eslint/rules/react-hooks.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,14 @@ module.exports = {
33
// Verify the list of the dependencies for Hooks like useEffect and similar
44
// https://github.com/facebook/react/blob/main/packages/eslint-plugin-react-hooks/src/rules/ExhaustiveDeps.ts
55
'react-hooks/exhaustive-deps': 'error',
6+
7+
// Allow refs to be accessed in render bodies
8+
'react-hooks/refs': 0,
9+
10+
// Allow calling setState in useEffect
11+
'react-hooks/set-state-in-effect': 0,
12+
13+
// We are not using React Compiler, don't warn about react-hook-form
14+
'react-hooks/incompatible-library': 0,
615
},
716
};

package.json

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -31,34 +31,35 @@
3131
},
3232
"dependencies": {},
3333
"devDependencies": {
34-
"@eslint/js": "^9.34.0",
34+
"@eslint/js": "^9.39.1",
3535
"@eslint-community/eslint-plugin-eslint-comments": "^4.5.0",
36-
"@stylistic/eslint-plugin": "^5.2.3",
36+
"@stylistic/eslint-plugin": "^5.6.1",
3737
"@types/jest": "^30.0.0",
38-
"@types/node": "^24.3.0",
38+
"@types/node": "^24.10.1",
3939
"concurrently": "^9.2.1",
4040
"confusing-browser-globals": "^1.0.11",
41-
"eslint": "^9.34.0",
41+
"eslint": "^9.39.1",
4242
"eslint-config-prettier": "^10.1.8",
4343
"eslint-import-resolver-typescript": "^4.4.4",
44-
"eslint-plugin-cypress": "^5.1.1",
44+
"eslint-plugin-cypress": "^5.2.0",
4545
"eslint-plugin-i18n-json": "4.0.1",
4646
"eslint-plugin-import": "^2.32.0",
47-
"eslint-plugin-jest": "^29.0.1",
47+
"eslint-plugin-jest": "^29.2.1",
4848
"eslint-plugin-jsx-a11y": "^6.10.2",
4949
"eslint-plugin-lodash": "^8.0.0",
50-
"eslint-plugin-n": "^17.21.3",
50+
"eslint-plugin-n": "^17.23.1",
5151
"eslint-plugin-react": "^7.37.5",
52-
"eslint-plugin-react-hooks": "^5.2.0",
53-
"globals": "^16",
54-
"jest": "^30.1.0",
55-
"jest-environment-jsdom": "^30.1.0",
56-
"prettier": "^3.6.2",
57-
"prettier-plugin-tailwindcss": "^0.6.14",
58-
"ts-jest": "^29.4.1",
52+
"eslint-plugin-react-hooks": "^7.0.1",
53+
"globals": "^16.5.0",
54+
"jest": "^30.2.0",
55+
"jest-environment-jsdom": "^30.2.0",
56+
"prettier": "^3.7.4",
57+
"prettier-plugin-tailwindcss": "^0.7.2",
58+
"ts-jest": "^29.4.6",
5959
"ts-node": "^10.9.2",
60-
"typescript": "^5.9.2",
61-
"typescript-eslint": "^8.41.0"
60+
"typescript": "^5.9.3",
61+
"typescript-eslint": "^8.48.1",
62+
"zod": "^3.25.76"
6263
},
6364
"workspaces": [
6465
"codegen",

0 commit comments

Comments
 (0)