Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/workflows/engineer-bot-followup.yml
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,10 @@ jobs:
- name: Install connector deps (npm ci)
run: npm ci

- name: Restore lockfile after dependency installation
# Keep setup-jfrog's registry rewrite out of the agent's changes.
run: git restore --source=HEAD --worktree -- package-lock.json

# Scope the JFrog credential away from the model-driven followup step:
# `npm ci` above consumed ~/.npmrc, and the agent's `npm test` doesn't need
# the registry. (Addresses the reviewer-bot finding on the odbc onboarding PR.)
Expand Down
7 changes: 5 additions & 2 deletions .github/workflows/engineer-bot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,13 @@ jobs:

- name: Install connector deps (npm ci)
# `prepare` lifecycle runs `npm run build` (tsc) automatically here, so the
# dist/ + lib/version.ts are built for the agent. Both are gitignored, so
# this leaves no tracked-file churn for publish to trip on.
# dist/ + lib/version.ts are built for the agent. Both are gitignored.
run: npm ci

- name: Restore lockfile after dependency installation
# Keep setup-jfrog's registry rewrite out of the agent's changes.
run: git restore --source=HEAD --worktree -- package-lock.json

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🔵 Low — This restores only package-lock.json, which matches what setup-jfrog rewrites today (.github/actions/setup-jfrog/action.yml:51-58). If setup ever touches another tracked file (for example, a prepare/build step that writes into a tracked path, or a new rewrite in setup-jfrog), the failure will come back. It would also show up late, as the same opaque "Unstaged paths remain" error in publish, after a full agent run.

Consider adding a fail-fast check right after the restore so setup churn is caught before the agent runs, e.g.:

run: |
  git restore --source=HEAD --worktree -- package-lock.json
  git diff --exit-code || { echo "::error::setup left tracked changes"; exit 1; }

The same applies to the follow-up workflow's restore step.


# Scope the JFrog credential AWAY from the model-driven steps. setup-jfrog
# wrote ~/.npmrc with an embedded auth token + exported JFROG_ACCESS_TOKEN to
# $GITHUB_ENV; `npm ci` above already consumed them, and the agent's test
Expand Down
Loading