Skip to content

Remove machine-global pnpm config causing .pnpm-store dir to be created in places - #76498

Merged
ashb merged 1 commit into
mainfrom
remove-yet-more-pnpm-global-hooks
Nov 4, 2026
Merged

ashb merged 1 commit into
mainfrom
remove-yet-more-pnpm-global-hooks

Conversation

@ashb

@ashb ashb commented Nov 4, 2026

Copy link
Copy Markdown
Member

This was removed everywhere in #73538, but one extra case crept back in
one day later via #73436 (I haven't checked, but likely the PR was
opened/branched from before 73538 was opened, so one more instance came
back).

This had side-effects that were noticed multiple times before
(#42119, #47342) but without thinking about what this is.

pnpm's store dir is its global system wide cache, akin to the uv cache
dir. By having this setting, each worktree or checkout that builds
assets locally or runs e2e tests gets at least one (and sometimes
multiple) cache dirs, usually taking 800MB-1GB.

This stops it setting the global config setting, but doesn't clear it.
To do that run this:

# Older Airflow prek hooks wrote this to your global pnpm config,
# giving every checkout its own package store.
pnpm config get store-dir   # if this prints ".pnpm-store":
pnpm config delete store-dir
pnpm store path             # should now point at the global store

Was generative AI tooling used to co-author this PR?
  • Yes (please specify the tool below)

  • Read the Pull Request Guidelines for more information. Note: commit author/co-author name and email in commits become permanently public when merged.
  • For fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
  • When adding dependency, check compliance with the ASF 3rd Party License Policy.
  • For significant user-facing changes create newsfragment: {pr_number}.significant.rst, in airflow-core/newsfragments. You can add this file in a follow-up commit after the PR is created so you know the PR number.

…ed in places

This was removed everywhere in #73538, but one extra case crept back in
one day later via #73436 (I haven't checked, but likely the PR was
opened/branched from before 73538 was opened, so one more instance came
back).

This had side-effects that were noticed multiple times before
(#42119, #47342) but without thinking about what this is.

pnpm's store dir is its global system wide cache, akin to the uv cache
dir. By having this setting, each worktree or checkout that builds
assets locally or runs e2e tests gets at least one (and sometimes
multiple) cache dirs, usually taking 800MB-1GB.

This stops it setting the global config setting, but doesn't clear it.
To do that run this:

```
# Older Airflow prek hooks wrote this to your global pnpm config,
# giving every checkout its own package store.
pnpm config get store-dir   # if this prints ".pnpm-store":
pnpm config delete store-dir
pnpm store path             # should now point at the global store
```
@ashb

ashb commented Nov 4, 2026

Copy link
Copy Markdown
Member Author

For example, I found about 12Gb of .pnpm-store folders across various worktrees and providers etc.

@ashb
ashb merged commit 9391e6a into main Nov 4, 2026
85 checks passed
@ashb
ashb deleted the remove-yet-more-pnpm-global-hooks branch November 4, 2026 23:51
@github-actions

github-actions Bot commented Nov 4, 2026

Copy link
Copy Markdown
Contributor

Backport successfully created: v3-4-test

Note: As of Merging PRs targeted for Airflow 3.X
the committer who merges the PR is responsible for backporting the PRs that are bug fixes (generally speaking) to the maintenance branches.

In matter of doubt please ask in #release-management Slack channel.

Status Branch Result
✅ v3-4-test PR Link

github-actions Bot pushed a commit to aws-mwaa/upstream-to-airflow that referenced this pull request Nov 4, 2026
… to be created in places (apache#76498)

(cherry picked from commit 9391e6a)

Co-authored-by: Ash Berlin-Taylor <ash@astronomer.io>
aws-airflow-bot pushed a commit to aws-mwaa/upstream-to-airflow that referenced this pull request Nov 5, 2026
… to be created in places (apache#76498)

(cherry picked from commit 9391e6a)

Co-authored-by: Ash Berlin-Taylor <ash@astronomer.io>
ashb pushed a commit that referenced this pull request Nov 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants