Skip to content

fix(ci): replace yarnPath with corepack, disable dependabot - #769

Merged
Decipher merged 1 commit into
developfrom
feature/corepack-yarnpath-fix
Aug 14, 2026
Merged

fix(ci): replace yarnPath with corepack, disable dependabot#769
Decipher merged 1 commit into
developfrom
feature/corepack-yarnpath-fix

Conversation

@Decipher

@Decipher Decipher commented Aug 11, 2026

Copy link
Copy Markdown
Member

Summary

Removes yarnPath from .yarnrc.yml and replaces it with corepack in CI, fixing the root cause that prevented both renovate and dependabot from regenerating yarn.lock (YN0028).

Problem

The yarnPath directive in .yarnrc.yml was the mechanism by which the GitHub runner's yarn 1.22.22 delegated to Yarn Berry 3.6.1. However, yarnPath also broke bot lockfile regeneration (dependabot-core#10632), causing every bot-created dependency PR to fail CI with YN0028: The lockfile would have been modified by this install.

Changes

CI infrastructure

  • Remove yarnPath from .yarnrc.yml — corepack handles version pinning via the packageManager field
  • Delete vendored .yarn/releases/yarn-3.6.1.cjs (3MB binary, no longer needed)
  • Remove !.yarn/releases from .gitignore
  • All 4 CI jobs (build, lint, test-unit, test-e2e):
    • Remove cache: yarn from setup-node (it invoked yarn before corepack could be enabled)
    • Add run: corepack enable after setup-node
    • Add actions/cache@v4 for .yarn/cache and docs/nuxt/.yarn/cache

Renovate config

  • Add markdownlint-cli2 to freeze list (Node 16 incompatible past ^0.13.0: newer versions pull in string-width v6+ which uses the /v regex flag requiring Node 20+)

Dependabot

  • Expanded dependabot.yml to cover all 8 subdirectories (not just root /)
  • Disabled Dependabot security updates at the repo level (they bypassed dependabot.yml)
  • Closed 19 stale Dependabot PRs

Verification

  • corepack enable + yarn --version → 3.6.1
  • yarn install --immutable passes
  • yarn build passes (all 11 packages)
  • CI passes on this PR

After merge

Renovate and dependabot (if re-enabled) can regenerate lockfiles on their own — the entire class of YN0028 failures goes away.

Closes #760

Summary by CodeRabbit

  • Chores

    • Improved CI and prebuild reliability with consistent package-manager activation and dependency caching.
    • Standardized validation workflows and caching across build, test, lint, and documentation checks.
    • Refined automated dependency-update settings to reduce unwanted update pull requests.
    • Improved build reproducibility through streamlined package-manager configuration.
  • Documentation

    • Simplified setup instructions for local development and reproducible builds.
    • Added convenient commands for setup, builds, development, documentation, testing, linting, and cleanup.
    • Documented required installation steps and fallback guidance when standard tooling is unavailable.

@changeset-bot

changeset-bot Bot commented Aug 11, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 1a6b032

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@coderabbitai

coderabbitai Bot commented Aug 11, 2026

Copy link
Copy Markdown

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 0c2f8c68-404a-4c10-93fa-d86d49698a04

📥 Commits

Reviewing files that changed from the base of the PR and between b3835d7 and 1a6b032.

📒 Files selected for processing (1)
  • .gitlab-ci.yml
🚧 Files skipped from review as they are similar to previous changes (1)
  • .gitlab-ci.yml

📝 Walkthrough

Walkthrough

The changes update dependency automation, standardize Corepack and Yarn usage, add explicit CI caching, centralize GitLab Node setup, and introduce Make targets for common repository commands.

Changes

Repository tooling and developer workflows

Layer / File(s) Summary
Dependency update controls
.github/dependabot.yml, renovate.json
Dependabot documents grouped security updates and suppresses version updates for configured directories. Renovate disables automerging and vulnerability alerts and pins markdownlint-cli2.
Corepack and Yarn workflows
.github/workflows/ci.yml, .gitpod.yml, .yarnrc.yml, docs/nuxt/.yarnrc.yml, .gitignore, .cspell-project-words.txt
CI and Gitpod explicitly enable Corepack and cache Yarn directories. Yarn uses local caches. Related ignore and spelling configuration was updated.
Developer command workflows
Makefile, AGENTS.md, CONTRIBUTING.md
The Makefile adds setup, build, development, documentation, test, lint, comprehensive lint, and clean targets. Developer instructions use the shared setup workflow and document Corepack fallback steps.
GitLab CI Node template
.gitlab-ci.yml
GitLab CI adds a shared Node template with Yarn and node_modules caches. Lint, test, preview, and documentation jobs inherit the template.

Estimated code review effort: 2 (Simple) | ~15 minutes

Merge Risk: 🔵 Low · up to 1a6b0

This PR changes CI dependency setup and caching to use Corepack and shared caches. The cache key may allow native dependencies built for one runtime environment to be reused in another, potentially causing CI failures; this bounded risk should remain visible to the owner.

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning The PR implements the Dependabot and Yarn portions of #760 but omits the audit gates, Knip gate, Renovate scoping, and codecov removal. Implement or split the remaining #760 requirements into a separate linked pull request before treating the issue as complete.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly identifies the Corepack migration and Dependabot changes, which are the main pull request changes.
Out of Scope Changes check ✅ Passed The changes support the Corepack migration, CI caching, dependency configuration, and contributor setup objectives; no unrelated change is evident.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/corepack-yarnpath-fix

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@codecov

codecov Bot commented Aug 11, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 81.49%. Comparing base (f5ca9ae) to head (1a6b032).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff            @@
##           develop     #769   +/-   ##
========================================
  Coverage    81.49%   81.49%           
========================================
  Files          112      112           
  Lines         2853     2853           
  Branches       616      616           
========================================
  Hits          2325     2325           
  Misses         436      436           
  Partials        92       92           
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.github/dependabot.yml:
- Around line 9-12: Update the repository dependency-automation configuration
associated with the Dependabot setup so automated security updates remain
enabled; remove or revise the repository-level setting that disables Dependabot
security updates, while preserving the existing version-update suppression.

In @.github/workflows/ci.yml:
- Around line 30-37: Add enableGlobalCache: false to both project-root
.yarnrc.yml files so Yarn uses the checked-in local .yarn/cache directories, and
ensure this configuration is applied consistently for all four cache steps in
the CI workflow.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 65b0d324-8bc5-4ed5-bbac-075e79182755

📥 Commits

Reviewing files that changed from the base of the PR and between f5ca9ae and e1ebf6a.

⛔ Files ignored due to path filters (1)
  • .yarn/releases/yarn-3.6.1.cjs is excluded by !**/.yarn/**
📒 Files selected for processing (5)
  • .github/dependabot.yml
  • .github/workflows/ci.yml
  • .gitignore
  • .yarnrc.yml
  • renovate.json
💤 Files with no reviewable changes (1)
  • .gitignore

Comment thread .github/dependabot.yml Outdated
Comment on lines +9 to +12
# This file suppresses Dependabot *version* updates via open-pull-requests-limit
# for every directory Dependabot has ever scanned in this repo.
# Dependabot *security* updates are also disabled at the repo level
# (Settings -> Code security -> Dependabot security updates).

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔒 Security & Privacy | 🟠 Major | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -eu
printf '%s\n' '--- .github/dependabot.yml ---'
cat -n .github/dependabot.yml
printf '%s\n' '--- Dependabot-related repository configuration ---'
rg -n -i 'dependabot|security update|open-pull-requests-limit' .github README.md 2>/dev/null || true
printf '%s\n' '--- Repository status summary ---'
git diff --stat

Repository: druxt/druxt.js

Length of output: 3775


🌐 Web query:

GitHub Dependabot security updates open-pull-requests-limit 0 does not disable security updates repository setting

💡 Result:

Setting open-pull-requests-limit to 0 in your dependabot.yml file does not disable security updates; it only disables Dependabot version updates for that specific package ecosystem [1][2][3]. Dependabot security updates and version updates operate independently. The open-pull-requests-limit configuration option specifically controls the maximum number of open pull requests allowed for version updates [1][4][3]. Security update pull requests are never subject to this limit and are not restricted by it [1][5][2]. If you wish to manage or disable Dependabot security updates, you must do so through the repository's security settings or by configuring the security update feature directly, rather than using the version update configuration file [6]. Setting open-pull-requests-limit to 0 is exclusively a method for temporarily silencing standard dependency version updates [1][3].

Citations:


🏁 Script executed:

#!/bin/bash
set -eu
printf '%s\n' '--- dependency automation files ---'
git ls-files | rg -i '(^|/)(renovate(\.json|\.json5|\.jsonc)?|dependabot\.yml|package\.json|composer\.json|package-lock\.json|yarn\.lock|pnpm-lock\.yaml|composer\.lock)$' || true
printf '%s\n' '--- Renovate configuration ---'
for f in $(git ls-files | rg -i '(^|/)renovate(\.json|\.json5|\.jsonc)?$'); do
  echo "### $f"
  cat -n "$f"
done
printf '%s\n' '--- security and dependency workflows/configuration ---'
git ls-files .github | rg -i '(workflow|action|security|audit|depend|renovate)' || true
rg -n -i 'renovate|npm audit|yarn audit|pnpm audit|composer audit| osv|osv-scanner|dependabot|dependency.review|codeql|owner|sla|vulnerab' .github package.json renovate.json renovate.json5 renovate.jsonc 2>/dev/null || true

Repository: druxt/druxt.js

Length of output: 6407


🌐 Web query:

site:github.com/druxt/druxt.js security policy dependency vulnerabilities Renovate

💡 Result:

Renovate is an automated dependency management tool that helps maintain project security by continuously monitoring and updating dependencies, including those with known vulnerabilities [1]. While specific internal policy documentation was not retrieved in the search, Renovate integrates into development workflows by generating pull requests to update outdated or vulnerable packages, ensuring projects stay aligned with current security standards [2][3][4]. Users typically manage dependency updates through Renovate's configuration, which allows for customization of update behavior, such as grouping updates or prioritizing security patches. In practice, Renovate acts as a proactive agent that identifies dependency changes—such as moving to a new major or minor version—and manages the associated versioning files (e.g., package.json, yarn.lock) to remediate technical debt and security risks [2][4][1]. Many projects use Renovate in conjunction with other security scanning tools, like Snyk, to maintain visibility into known vulnerabilities and automate the remediation process [5][6].

Citations:


🏁 Script executed:

#!/bin/bash
set -eu
printf '%s\n' '--- package scripts ---'
sed -n '1,110p' package.json
printf '%s\n' '--- CI workflow ---'
cat -n .github/workflows/ci.yml
printf '%s\n' '--- all workflow references to audit/remediation ---'
rg -n -i 'audit|vulnerab|dependabot|renovate|security|owner|sla' .github/workflows .github 2>/dev/null || true

Repository: druxt/druxt.js

Length of output: 15663


🌐 Web query:

Renovate documentation GitHub vulnerability alerts security updates packageRules disabled major updates automerge

💡 Result:

To configure Renovate regarding automerge, security updates, and major update behavior, you can use the following approaches within your renovate.json configuration file. Automerge Configuration You can control automerge behavior using the automerge option [1][2]. By default, automerge is disabled (false) [2]. To enable it, you can set "automerge": true [1][2]. It is common practice to enable automerge for non-major updates (minor, patch, pin, digest) while leaving major updates for manual review [2][3]. Example to automerge non-major updates: { "packageRules": [ { "matchUpdateTypes": ["minor", "patch", "pin", "digest"], "automerge": true } ] } Major Update Behavior To disable major updates, you can use the:disableMajorUpdates preset or configure it manually [4]: { "major": { "enabled": false } } GitHub Vulnerability Alerts Renovate can integrate with GitHub's vulnerability alerts to prioritize security fixes [5]. To enable this, ensure your repository has the Dependency graph and Dependabot alerts enabled on GitHub [6]. In your Renovate configuration, you can use the:enableVulnerabilityAlerts preset to raise pull requests when vulnerabilities are detected [7]. Combining Rules You can combine these settings using packageRules to apply specific behaviors to subsets of dependencies [2][3]. For example, if you want to disable automerge for all dependencies as a global override, you can use: { "packageRules": [ { "matchPackageNames": ["*"], "automerge": false } ] } Note that if a configuration option has a parent (like automerge within packageRules), it must be defined inside that object [2][3]. Refer to the official Renovate documentation for detailed configuration schemas and preset definitions [2][4].

Citations:


Keep automated security remediation enabled.

Dependabot security updates are disabled at the repository level. Renovate does not configure vulnerability alerts. CI only audits dependencies; it does not create remediation PRs or define an owner and SLA. Re-enable Dependabot security updates, or configure an equivalent Renovate process with documented ownership and remediation deadlines.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/dependabot.yml around lines 9 - 12, Update the repository
dependency-automation configuration associated with the Dependabot setup so
automated security updates remain enabled; remove or revise the repository-level
setting that disables Dependabot security updates, while preserving the existing
version-update suppression.

Comment thread .github/workflows/ci.yml
Comment on lines +30 to +37
- uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 # v4
with:
path: |
.yarn/cache
docs/nuxt/.yarn/cache
key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock', 'docs/nuxt/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀 Performance & Scalability | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

for dir in . docs/nuxt; do
  (
    cd "$dir"
    corepack enable
    cache_folder="$(yarn config get cacheFolder)"
    global_cache="$(yarn config get enableGlobalCache)"
    printf '%s\tcacheFolder=%s\tenableGlobalCache=%s\n' \
      "$PWD" "$cache_folder" "$global_cache"
    case "$cache_folder" in
      ./.yarn/cache|*/.yarn/cache) ;;
      *) exit 1 ;;
    esac
    test "$global_cache" = "false"
  )
done

Repository: druxt/druxt.js

Length of output: 901


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '%s\n' '--- workflow cache and setup sections ---'
sed -n '1,210p' .github/workflows/ci.yml

printf '%s\n' '--- relevant repository files ---'
git ls-files \
  '.yarnrc.yml' \
  'yarn.lock' \
  'package.json' \
  'docs/nuxt/.yarnrc.yml' \
  'docs/nuxt/yarn.lock' \
  'docs/nuxt/package.json' \
  '.github/workflows/ci.yml'

printf '%s\n' '--- root configuration and manifest ---'
for file in package.json .yarnrc.yml; do
  if test -f "$file"; then
    printf '\n[%s]\n' "$file"
    cat "$file"
  fi
done

printf '%s\n' '--- docs/nuxt configuration and manifest ---'
for file in docs/nuxt/package.json docs/nuxt/.yarnrc.yml; do
  if test -f "$file"; then
    printf '\n[%s]\n' "$file"
    cat "$file"
  fi
done

Repository: druxt/druxt.js

Length of output: 12316


🌐 Web query:

Yarn 3.6.1 configuration defaults cacheFolder enableGlobalCache official documentation

💡 Result:

In Yarn 3.6.1, the enableGlobalCache and cacheFolder settings work together as follows: enableGlobalCache This setting defines whether Yarn uses a system-wide shared cache [1][2][3]. Default: true [1][2][4] Behavior: When enabled (default), Yarn ignores the cacheFolder configuration and stores all cache files within the globalFolder (typically located in your home directory) [1][2][3][5]. cacheFolder This setting defines the directory where downloaded packages are stored when the local cache is active [1][2][3]. Default: "./.yarn/cache" [1][2][3] Behavior: This setting is only respected when enableGlobalCache is set to false [1][2][6][5]. If you wish to store your cache in a custom local directory (often used to commit dependencies to version control), you must set enableGlobalCache: false in your.yarnrc.yml file, after which Yarn will use the path specified in cacheFolder [7][6][5]. To configure these settings, you can add them to your.yarnrc.yml file: enableGlobalCache: false cacheFolder: "./.yarn/cache" Alternatively, you can set them via environment variables using snake case: YARN_ENABLE_GLOBAL_CACHE and YARN_CACHE_FOLDER [1][2]. Note that environment variables take precedence over settings defined in.yarnrc.yml files [1][2].

Citations:


🏁 Script executed:

#!/bin/bash
set -euo pipefail

printf '%s\n' '--- available Yarn and Corepack tooling ---'
command -v yarn || true
command -v yarnpkg || true
command -v corepack || true
node --version || true
corepack --version || true

printf '%s\n' '--- repository cache configuration ---'
rg -n --hidden --glob '!yarn.lock' --glob '!docs/nuxt/yarn.lock' \
  '^(cacheFolder|enableGlobalCache):|cacheFolder|enableGlobalCache|packageManager' \
  . .github/workflows/ci.yml || true

printf '%s\n' '--- Yarn cache directories tracked by the repository ---'
for dir in .yarn/cache docs/nuxt/.yarn/cache; do
  if test -d "$dir"; then
    printf '%s: directory exists\n' "$dir"
    find "$dir" -maxdepth 1 -type f | head -n 5
  else
    printf '%s: directory absent\n' "$dir"
  fi
done

Repository: druxt/druxt.js

Length of output: 1505


Set Yarn to use the local cache.

Yarn 3.6.1 enables the global cache by default. Both .yarnrc.yml files omit enableGlobalCache: false, so Yarn does not use the cached .yarn/cache paths. Set this option in both project roots. Apply the change to all four cache steps.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.github/workflows/ci.yml around lines 30 - 37, Add enableGlobalCache: false
to both project-root .yarnrc.yml files so Yarn uses the checked-in local
.yarn/cache directories, and ensure this configuration is applied consistently
for all four cache steps in the CI workflow.

Source: MCP tools

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@Makefile`:
- Around line 25-30: Update the lint-all target to invoke both documented
checks, lint:format and lint:renovate, in addition to its existing lint commands
so every documented lint check runs.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 81db4e01-fbb3-414b-8981-2508fa8fc4e9

📥 Commits

Reviewing files that changed from the base of the PR and between e1ebf6a and 03b866a.

📒 Files selected for processing (4)
  • .gitpod.yml
  • AGENTS.md
  • CONTRIBUTING.md
  • Makefile

Comment thread Makefile Outdated
Comment on lines +25 to +30
lint-all: ## Run all lint checks (eslint, markdownlint, cspell, knip, audit)
yarn lint
yarn lint:md
yarn lint:cspell
yarn lint:knip
yarn lint:audit

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Make lint-all run every documented lint check.

lint-all omits yarn lint:format and yarn lint:renovate, although AGENTS.md, Lines 47-50, documents both checks. A passing make lint-all can miss formatting and Renovate configuration failures.

Proposed fix
 lint-all: ## Run all lint checks (eslint, markdownlint, cspell, knip, audit)
 	yarn lint
 	yarn lint:md
 	yarn lint:cspell
+	yarn lint:format
+	yarn lint:renovate
 	yarn lint:knip
 	yarn lint:audit
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
lint-all: ## Run all lint checks (eslint, markdownlint, cspell, knip, audit)
yarn lint
yarn lint:md
yarn lint:cspell
yarn lint:knip
yarn lint:audit
lint-all: ## Run all lint checks (eslint, markdownlint, cspell, knip, audit)
yarn lint
yarn lint:md
yarn lint:cspell
yarn lint:format
yarn lint:renovate
yarn lint:knip
yarn lint:audit
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@Makefile` around lines 25 - 30, Update the lint-all target to invoke both
documented checks, lint:format and lint:renovate, in addition to its existing
lint commands so every documented lint check runs.

Decipher added a commit that referenced this pull request Aug 13, 2026
- Set enableGlobalCache: false in both .yarnrc.yml files so the CI
  actions/cache step caches the correct local .yarn/cache directory
  (Yarn 3.6.1 defaults to global cache otherwise)
- Add lint:format and lint:renovate to Makefile lint-all target
  to match the CI lint suite

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In @.gitlab-ci.yml:
- Around line 49-54: Update the GitLab CI cache configuration to add a separate
cache entry for the docs/nuxt Yarn project, keyed by its lockfile and covering
docs/nuxt/.yarn/cache/ and docs/nuxt/node_modules/. Keep the existing
root-project cache entry unchanged.
- Around line 47-54: Update the CI cache key in the top-level cache
configuration to include both the runner architecture and the Node image
identifier alongside yarn.lock, ensuring node_modules native binaries are not
shared across incompatible environments.
🪄 Autofix

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: f43d526e-c7bc-464f-8f7a-dcd13ca4c05c

📥 Commits

Reviewing files that changed from the base of the PR and between 81fb53f and b3835d7.

📒 Files selected for processing (4)
  • .cspell-project-words.txt
  • .github/dependabot.yml
  • .gitlab-ci.yml
  • renovate.json

Comment thread .gitlab-ci.yml Outdated
Comment on lines +47 to +54
image: node:16.20.1
cache:
key:
files:
- yarn.lock
paths:
- .yarn/cache/
- node_modules/

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🩺 Stability & Availability | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -eu

printf '%s\n' '--- CI structure and cache definitions ---'
sed -n '1,290p' .gitlab-ci.yml

printf '%s\n' '--- dependency and toolchain declarations ---'
for f in package.json yarn.lock .yarnrc.yml docs/nuxt/.yarnrc.yml docs/nuxt/package.json; do
  if [ -f "$f" ]; then
    echo "### $f"
    sed -n '1,180p' "$f"
  fi
done

printf '%s\n' '--- native dependency references ---'
rg -n --hidden --glob '!node_modules/**' --glob '!dist/**' '(^|["'\''])((@[^/"'\'']+/)?(deasync|re2))(["'\'']|@|:)|deasync|re2' .

printf '%s\n' '--- working-directory and runner settings ---'
rg -n --hidden --glob '.gitlab-ci.yml' 'extends:|image:|cache:|key:|paths:|before_script:|script:|cd |CI_RUNNER|tags:|yarn|corepack|working_directory|YARN' .

Repository: druxt/druxt.js

Length of output: 25010


🏁 Script executed:

#!/bin/bash
set -eu

printf '%s\n' '--- native package lock entries and dependency context ---'
sed -n '9428,9465p' yarn.lock
sed -n '18490,18525p' yarn.lock
sed -n '18980,19025p' yarn.lock
sed -n '22070,22095p' yarn.lock

printf '%s\n' '--- all tracked Yarn configuration and lockfiles ---'
git ls-files '*yarn.lock' '*yarnrc.yml' '.gitlab-ci.yml'

printf '%s\n' '--- cache-path relationship to install locations ---'
python3 - <<'PY'
from pathlib import Path
ci = Path(".gitlab-ci.yml").read_text()
print("root cache includes node_modules/:", "      - node_modules/" in ci)
print("root cache includes .yarn/cache/:", "      - .yarn/cache/" in ci)
for p in [Path("node_modules"), Path(".yarn/cache"), Path("docs/nuxt/node_modules"), Path("docs/nuxt/.yarn/cache")]:
    print(f"{p}: tracked={p.exists()} (source tree presence only)")
PY

printf '%s\n' '--- runner/image/architecture identifiers in repository ---'
rg -n --hidden --glob '!yarn.lock' --glob '!docs/nuxt/yarn.lock' --glob '!examples/**/yarn.lock' \
  'node:16\.20\.1|platform|architecture|arch|amd64|arm64|aarch64|docker' .gitlab-ci.yml .github package.json docs/nuxt/package.json 2>/dev/null || true

Repository: druxt/druxt.js

Length of output: 6207


🌐 Web query:

GitLab CI cache key files cache paths runner architecture cache isolation documentation

💡 Result:

In GitLab CI/CD, caching is a mechanism used to speed up jobs by storing project dependencies or intermediate files between runs [1][2]. Below is a synthesis of the key components requested. Cache Key Files and Paths Cache keys are defined in the.gitlab-ci.yml file to identify and reuse cache archives [3][4]. - cache:key:files: Allows you to generate a cache key based on the SHA checksum of specific files (e.g., Gemfile.lock, package-lock.json, or yarn.lock) [1][4]. The cache key only changes when the content of these files changes, ensuring the cache is reused when dependencies remain stable [3][4]. - cache:paths: Defines the files and directories that should be cached. Paths must be relative to the project directory, as files outside this directory cannot be cached [1][2]. - cache:key:files_commits: A variation that generates keys based on the latest commit of specified files, causing the key to change whenever the files are updated, even if the content is otherwise identical [3][4]. Runner Architecture and Caching The runner architecture dictates how cache files are stored and accessed: - Local Caching: By default, caches are stored on the machine where the GitLab Runner is installed, often within the runner's home directory or as Docker volumes for Docker executors [1][2]. - Distributed Caching: To support multiple runners (e.g., autoscaling environments), runners can be configured to use distributed caching (e.g., via S3 or GCS buckets) [1][2][5]. This allows different runner instances to share the same cache. - Network-Mounted Caching: Runners sharing the same architecture can alternatively be configured to use a common, network-mounted directory (such as NFS) to share cache data [1][2]. Cache Isolation Cache isolation is primarily managed through key scoping and runner configuration: - Key Scoping: Caches are associated with specific keys. Jobs using the same key share the same cache, which can span different branches and pipelines [3][4]. You can use predefined variables like $CI_COMMIT_REF_SLUG in the cache key to scope caches to specific branches [6][2]. - Runner Isolation: GitLab-hosted runners on GitLab.com are highly isolated; they run in ephemeral VMs that are destroyed immediately after a single job completes [5][7]. These runners utilize a shared distributed cache (GCS) that is logically separated by project, ensuring security and preventing unauthorized access to cache data between different projects [5][7]. For detailed configuration options and syntax, refer to the official GitLab documentation on Caching in GitLab CI/CD and the CI/CD YAML syntax reference [1][3][4].

Citations:


Scope the native-module cache by runner architecture.

node_modules/ contains native packages such as deasync and re2, but the cache key hashes only yarn.lock. Jobs using different runner architectures can share this key and restore incompatible binaries. Add the runner architecture and Node image identifier to the key, or restrict the runner to one architecture.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.gitlab-ci.yml around lines 47 - 54, Update the CI cache key in the
top-level cache configuration to include both the runner architecture and the
Node image identifier alongside yarn.lock, ensuring node_modules native binaries
are not shared across incompatible environments.

Comment thread .gitlab-ci.yml Outdated
Comment on lines +49 to +54
key:
files:
- yarn.lock
paths:
- .yarn/cache/
- node_modules/

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🗄️ Data Integrity & Integration | 🟡 Minor | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/usr/bin/env bash
set -euo pipefail

# Expected: docs jobs use the root project, or define a docs-specific cache.
rg -n -C 25 \
  '^(pages:preview|docs:review):|docs/nuxt|yarn ' \
  .gitlab-ci.yml || true

printf '\nLockfiles and Yarn configuration files:\n'
fd -H -t f 'yarn\.lock$' .
fd -H -t f '\.yarnrc\.yml$' .

Repository: druxt/druxt.js

Length of output: 7884


🏁 Script executed:

#!/usr/bin/env bash
set -euo pipefail

printf '%s\n' 'CI cache template:'
sed -n '35,60p' .gitlab-ci.yml

printf '\n%s\n' 'Root and docs Yarn configuration:'
cat .yarnrc.yml
printf '\n--- docs/nuxt/.yarnrc.yml ---\n'
cat docs/nuxt/.yarnrc.yml

printf '\n%s\n' 'Relevant package metadata:'
python3 - <<'PY'
import json
for path in ("package.json", "docs/nuxt/package.json"):
    with open(path) as f:
        data = json.load(f)
    print(path)
    print("packageManager:", data.get("packageManager"))
    print("installConfig:", data.get("installConfig"))
PY

Repository: druxt/druxt.js

Length of output: 1363


Cache the docs/nuxt Yarn project separately.

docs/nuxt has its own yarn.lock, .yarnrc.yml, .yarn/cache/, and node_modules/. The shared cache currently covers only the root project, so documentation dependencies are reinstalled on every job.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In @.gitlab-ci.yml around lines 49 - 54, Update the GitLab CI cache
configuration to add a separate cache entry for the docs/nuxt Yarn project,
keyed by its lockfile and covering docs/nuxt/.yarn/cache/ and
docs/nuxt/node_modules/. Keep the existing root-project cache entry unchanged.

Corepack / yarnPath fix:
- Remove yarnPath from .yarnrc.yml, delete 3MB vendored Berry binary
- Add enableGlobalCache: false to both .yarnrc.yml files
- Replace cache: yarn in setup-node with corepack enable + actions/cache
  in all 4 GitHub Actions CI jobs
- Root cause: yarnPath was how the runner's yarn 1.22 delegated to Berry,
  not via corepack; also blocked bot lockfile regeneration (#10632)

Makefile + docs:
- Add Makefile (setup, build, test, lint, lint-all, dev, docs, clean, help)
- Update CONTRIBUTING.md, AGENTS.md, .gitpod.yml for corepack workflow

Dependabot / Renovate separation:
- renovate.json: automerge false, vulnerabilityAlerts disabled
- dependabot.yml: 8 subdirectories, open-pull-requests-limit 0 (version
  PRs only; security PRs unaffected)
- Dependabot security updates + private vuln reporting enabled via API
- 19 stale Dependabot PRs closed

Renovate hardening:
- pinDigests scoped to github-actions only (global caused lockfile failures)
- markdownlint-cli2 added to freeze list (Node 16 incompatible past 0.13)

GitLab CI cache:
- Hidden .node template with yarn.lock-keyed cache for .yarn/cache/ and
  node_modules/, scoped by Node image tag
- Separate cache entry for docs/nuxt workspace
- Eliminates flaky native module rebuilds (deasync, dtrace-provider)
@Decipher
Decipher force-pushed the feature/corepack-yarnpath-fix branch from b3835d7 to 1a6b032 Compare August 14, 2026 02:25
@Decipher
Decipher merged commit 6a59f71 into develop Aug 14, 2026
9 checks passed
@Decipher
Decipher deleted the feature/corepack-yarnpath-fix branch August 14, 2026 04:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Dependency cleanup + automated dep/security auditing in CI

1 participant