Skip to content

Commit 75005a8

Browse files
authored
Chore: Update to yarn 4 (grafana#77156)
* update to yarn 4 * update project to yarn 4 * update tetherdrop archive * update sdks * change puppeteer image to official node 20 one * revert previous, use grafana/docker-puppeteer:pre-node-20 instead * okay, try original docker image, but use npx instead of yarn for wait-on * remove wait-on from deps as we use it via npx now * yarn dedupe * remove logs from drone * empty commit testing yarn cache :) * comment explaining why no -y
1 parent 661e1e2 commit 75005a8

16 files changed

+9751
-10365
lines changed

.drone.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -685,7 +685,7 @@ steps:
685685
include:
686686
- packages/grafana-ui/**
687687
- commands:
688-
- yarn wait-on http://$HOST:$PORT
688+
- npx wait-on@7.0.1 http://$HOST:$PORT
689689
- pa11y-ci --config .pa11yci-pr.conf.js
690690
depends_on:
691691
- grafana-server
@@ -1936,7 +1936,7 @@ steps:
19361936
include:
19371937
- packages/grafana-ui/**
19381938
- commands:
1939-
- yarn wait-on http://$HOST:$PORT
1939+
- npx wait-on@7.0.1 http://$HOST:$PORT
19401940
- pa11y-ci --config .pa11yci.conf.js --json > pa11y-ci-results.json
19411941
depends_on:
19421942
- grafana-server
@@ -4670,6 +4670,6 @@ kind: secret
46704670
name: gcr_credentials
46714671
---
46724672
kind: signature
4673-
hmac: 64de498d74f13b64f233fe5d37751903a0efb03b3cab28e046797dc80d390965
4673+
hmac: 920b57d70a96a29872ce77dc83ca26e2d141ba37627eee58c9d3beebf9ec4055
46744674

46754675
...
Binary file not shown.
Binary file not shown.

.yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs

-546
This file was deleted.

.yarn/plugins/@yarnpkg/plugin-typescript.cjs

-9
This file was deleted.

.yarn/releases/yarn-3.6.4.cjs

-874
This file was deleted.

.yarn/releases/yarn-4.0.0.cjs

+893
Large diffs are not rendered by default.

.yarn/sdks/eslint/package.json

+9-1
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,13 @@
22
"name": "eslint",
33
"version": "8.52.0-sdk",
44
"main": "./lib/api.js",
5-
"type": "commonjs"
5+
"type": "commonjs",
6+
"bin": {
7+
"eslint": "./bin/eslint.js"
8+
},
9+
"exports": {
10+
"./package.json": "./package.json",
11+
".": "./lib/api.js",
12+
"./use-at-your-own-risk": "./lib/unsupported-api.js"
13+
}
614
}

.yarn/sdks/prettier/index.js

-20
This file was deleted.

.yarn/sdks/prettier/package.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
{
22
"name": "prettier",
33
"version": "3.0.0-sdk",
4-
"main": "./index.js",
5-
"type": "commonjs"
4+
"main": "./index.cjs",
5+
"type": "commonjs",
6+
"bin": "./bin/prettier.cjs"
67
}

.yarn/sdks/typescript/lib/typescript.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ const absRequire = createRequire(absPnpApiPath);
1111

1212
if (existsSync(absPnpApiPath)) {
1313
if (!process.versions.pnp) {
14-
// Setup the environment to be able to require typescript/lib/typescript.js
14+
// Setup the environment to be able to require typescript
1515
require(absPnpApiPath).setup();
1616
}
1717
}
1818

19-
// Defer to the real typescript/lib/typescript.js your application uses
20-
module.exports = absRequire(`typescript/lib/typescript.js`);
19+
// Defer to the real typescript your application uses
20+
module.exports = absRequire(`typescript`);

.yarn/sdks/typescript/package.json

+5-1
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,9 @@
22
"name": "typescript",
33
"version": "4.8.4-sdk",
44
"main": "./lib/typescript.js",
5-
"type": "commonjs"
5+
"type": "commonjs",
6+
"bin": {
7+
"tsc": "./bin/tsc",
8+
"tsserver": "./bin/tsserver"
9+
}
610
}

.yarnrc.yml

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
compressionLevel: mixed
2+
3+
enableGlobalCache: false
4+
15
enableTelemetry: false
26

37
nodeLinker: pnp
@@ -28,14 +32,10 @@ packageExtensions:
2832
react-dom: 17.0.1
2933

3034
plugins:
31-
- path: .yarn/plugins/@yarnpkg/plugin-typescript.cjs
32-
spec: '@yarnpkg/plugin-typescript'
33-
- path: .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs
34-
spec: '@yarnpkg/plugin-interactive-tools'
3535
- path: .yarn/plugins/@yarnpkg/plugin-outdated.cjs
3636
spec: 'https://mskelton.dev/yarn-outdated/v2'
3737

38-
yarnPath: .yarn/releases/yarn-3.6.4.cjs
38+
yarnPath: .yarn/releases/yarn-4.0.0.cjs
3939
# Uncomment the following lines if you want to use Verdaccio local npm registry. Read more at packages/README.md
4040
# npmScopes:
4141
# grafana:

package.json

+1-2
Original file line numberDiff line numberDiff line change
@@ -228,7 +228,6 @@
228228
"ts-jest": "29.1.1",
229229
"ts-node": "10.9.1",
230230
"typescript": "4.8.4",
231-
"wait-on": "7.0.1",
232231
"webpack": "5.89.0",
233232
"webpack-bundle-analyzer": "4.9.0",
234233
"webpack-cli": "5.1.4",
@@ -444,7 +443,7 @@
444443
"engines": {
445444
"node": ">= 20"
446445
},
447-
"packageManager": "yarn@3.6.4",
446+
"packageManager": "yarn@4.0.0",
448447
"dependenciesMeta": {
449448
450449
"unplugged": true

scripts/drone/steps/lib.star

+2-1
Original file line numberDiff line numberDiff line change
@@ -614,7 +614,8 @@ def test_a11y_frontend_step(ver_mode, port = 3001):
614614
Drone step.
615615
"""
616616
commands = [
617-
"yarn wait-on http://$HOST:$PORT",
617+
# Note - this runs in a container running node 14, which does not support the -y option to npx
618+
"npx [email protected] http://$HOST:$PORT",
618619
]
619620
failure = "ignore"
620621
if ver_mode == "pr":

0 commit comments

Comments
 (0)