Skip to content

Commit 86233e7

Browse files
authored
[9.5] [CI] remove yarn.lock, adjust configs (#291037) (#291077)
# Backport This will backport the following commits from `main` to `9.5`: - [[CI] remove yarn.lock, adjust configs (#291037)](#291037) <!--- Backport version: 12.0.4 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Alex Szabo","email":"alex.szabo@elastic.co"},"sourceCommit":{"committedDate":"2026-09-15T09:29:04Z","message":"[CI] remove yarn.lock, adjust configs (#291037)\n\n## Summary\nRemoves yarn.lock, cleans up some references to it, ignore what's left,\nadjusts configs.","sha":"e089b00e7df0908b7af0215f66e2dbce69ec9fe1","branchLabelMapping":{"^v9.6.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","backport:all-open","v9.6.0"],"title":"[CI] remove yarn.lock, adjust configs","number":291037,"url":"https://github.com/elastic/kibana/pull/291037","mergeCommit":{"message":"[CI] remove yarn.lock, adjust configs (#291037)\n\n## Summary\nRemoves yarn.lock, cleans up some references to it, ignore what's left,\nadjusts configs.","sha":"e089b00e7df0908b7af0215f66e2dbce69ec9fe1"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v9.6.0","branchLabelMappingKey":"^v9.6.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/291037","number":291037,"mergeCommit":{"message":"[CI] remove yarn.lock, adjust configs (#291037)\n\n## Summary\nRemoves yarn.lock, cleans up some references to it, ignore what's left,\nadjusts configs.","sha":"e089b00e7df0908b7af0215f66e2dbce69ec9fe1"}}]}] BACKPORT-->
1 parent 93b02f3 commit 86233e7

10 files changed

Lines changed: 15 additions & 35441 deletions

File tree

.buildkite/scripts/pipelines/pull_request/pipeline.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -258,8 +258,8 @@ describe('pull_request pipeline generation', () => {
258258
expect(mockAreChangesSkippable).not.toHaveBeenCalled();
259259
});
260260

261-
it('emits storybooks when yarn.lock changes', async () => {
262-
const changes = [{ filename: 'yarn.lock' }];
261+
it('emits storybooks when pnpm-lock.yaml changes', async () => {
262+
const changes = [{ filename: 'pnpm-lock.yaml' }];
263263
mockGetPrChangesCached.mockResolvedValue(changes);
264264
mockDoAnyChangesMatch.mockImplementation((paths, scopedChanges) =>
265265
realDoAnyChangesMatch(paths, scopedChanges ?? changes)

.buildkite/scripts/pipelines/pull_request/pipeline.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ const SKIPPABLE_PR_MATCHERS = prConfig.skip_ci_on_only_changed!.map((r) => new R
5252

5353
// this covers external dependency changes, which the package graph below cannot see.
5454
const STORYBOOK_BUILD_CRITICAL_PATHS = [
55-
/^yarn\.lock$/,
55+
/^pnpm-lock\.yaml$/,
5656
/^pnpm-workspace\.yaml$/,
5757
/^\.buildkite\/scripts\/steps\/storybooks\//,
5858
];

.buildkite/scripts/steps/esql_generate_function_metadata.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ main () {
4242

4343
# Check for differences
4444
set +e
45-
git diff --exit-code --quiet $GIT_SCOPE
45+
git diff --exit-code --quiet $GIT_SCOPE
4646
if [ $? -eq 0 ]; then
4747
echo "No differences found. Our work is done here."
4848
exit
@@ -74,14 +74,17 @@ main () {
7474
git checkout -b "$BRANCH_NAME"
7575

7676
git add $GIT_SCOPE
77+
if [ "$VERSION_BUMPED" == "true" ]; then
78+
git add package.json pnpm-lock.yaml
79+
fi
7780
git commit -m "Update function metadata"
7881

7982
report_main_step "Changes committed. Creating pull request."
8083

8184
git push origin "$BRANCH_NAME"
8285

8386
# Create a PR
84-
gh pr create --title "$PR_TITLE" --body "$PR_BODY" --base main --head "${BRANCH_NAME}" --label 'release_note:skip' --label 'Team:ESQL'
87+
gh pr create --title "$PR_TITLE" --body "$PR_BODY" --base main --head "${BRANCH_NAME}" --label 'release_note:skip' --label 'Team:ESQL'
8588
}
8689

8790
main

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ selenium
105105
*.out
106106
package-lock.json
107107
!/.buildkite/package-lock.json
108+
yarn.lock
108109
.yo-rc.json
109110
.vscode
110111
*.sublime-*

docs/extend/contributing/workflow/how-we-use-github.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ Pull requests are made into the main branch and only backported when it is safe
3030
- Bug fixes can be backported to a `<major>.<minor>` branch if the changes are safe and appropriate. Safety is a judgment call you make based on factors like the bug’s severity, test coverage, confidence in the changes, etc. Your reasoning should be included in the pull request description.
3131
- Documentation changes can be backported to any branch at any time.
3232

33-
### Managing updates to `yarn.lock` across branches
33+
### Managing dependency updates across branches
3434

3535
We want to keep updates to dependencies (both transitive dependencies and direct dependencies) in sync across both `main` and `<previous major>.<last minor>` (ex: `7.17`) as much as possible.
3636
A good rule of thumb is that most package upgrades should be backported to the `<previous major>.<last minor>` branch, though as always, exceptions may apply – if an upgrade requires significant code changes, then it might make sense to skip a backport for it.

packages/kbn-eslint-config/.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,4 +33,5 @@ node_modules
3333
.node_repl_history
3434
.eslintrc.json
3535

36-
yarn.lock
36+
yarn.lock
37+
pnpm-lock.yaml

packages/kbn-yarn-lock-validator/README.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,10 @@ slug: /kibana-dev-docs/ops/kbn-yarn-lock-validator
44
title: "@kbn/yarn-lock-validator"
55
description: 'A tool for validating specific conditions for our dependency chain'
66
date: 2022-07-14
7-
tags: ['kibana', 'dev', 'contributor', 'operations', 'packages', 'scripts', 'yarn']
7+
tags: ['kibana', 'dev', 'contributor', 'operations', 'packages', 'scripts', 'pnpm']
88
---
99

10-
`@kbn/yarn-lock-validator` provides yarn.lock validation logic for the Kibana project. It is loaded up by <DocLink id="kibDevDocsOpsKbnPm" /> after bootstrap and validates that we haven't accidentally re-introduced specific dependencies or version-combination scenarios detailed below:
10+
`@kbn/yarn-lock-validator` provides pnpm lockfile validation logic for the Kibana project. It is loaded up by <DocLink id="kibDevDocsOpsKbnPm" /> after bootstrap and validates that we haven't accidentally re-introduced specific dependencies or version-combination scenarios detailed below:
1111

1212
## validation scenarios
1313

src/platform/plugins/shared/console/packaging/yarn.lock

Lines changed: 0 additions & 4 deletions
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
yarn.lock
2+
pnpm-lock.yaml

0 commit comments

Comments
 (0)