fix: build dist/ before setup-credentials in self-review-pr.yml#191
Merged
Merged
Conversation
dist/ is excluded from .gitignore and not committed to the repo. The setup-credentials action runs `node dist/credentials.js` but that file only exists after `pnpm install && pnpm build` is run. release.yml already does this correctly (build then setup-credentials). self-review-pr.yml did not have a build step, causing all three jobs that call setup-credentials to fail with: Cannot find module '.../dist/credentials.js' Add pnpm/action-setup + setup-node + pnpm build steps immediately after the initial checkout in each of the four affected jobs: - resolve-context - review - reply-to-feedback - reply-to-mention Pinned action SHAs match the versions already used in release.yml.
derekmisler
approved these changes
May 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
self-review-pr.ymlwas failing with:The
.github/actions/setup-credentialsaction runs:node "$GITHUB_ACTION_PATH/../../../dist/credentials.js"But
dist/is in.gitignoreand never committed to the repo. So when a workflow checks out the repo and immediately calls./.github/actions/setup-credentials, thedist/files don't exist.Root cause
release.ymlworks correctly because it runspnpm install && pnpm buildin the same job before callingsetup-credentials.self-review-pr.ymlhad no such build step.Fix
Add
pnpm/action-setup+actions/setup-node+pnpm install --frozen-lockfile && pnpm buildsteps immediately after the initialactions/checkoutstep in each of the four affected jobs:resolve-contextreviewreply-to-feedbackreply-to-mentionThe pinned action SHAs (
pnpm/action-setup@8912a9102ac27614460f54aedde9e1e7f9aec20dandactions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e) match the versions already used inrelease.yml.Validation
biome ci .— passes ✓tsc --noEmit— passes ✓actionlint— only pre-existingnode24runner warnings (present onmainbefore this PR) ✓