Skip to content

ci(.github/workflows): use the runner's system Python 3.11 (peco-driver)#539

Merged
eric-wang-1990 merged 1 commit into
mainfrom
ci/bot-python-self-hosted
Jun 21, 2026
Merged

ci(.github/workflows): use the runner's system Python 3.11 (peco-driver)#539
eric-wang-1990 merged 1 commit into
mainfrom
ci/bot-python-self-hosted

Conversation

@eric-wang-1990

@eric-wang-1990 eric-wang-1990 commented Jun 21, 2026

Copy link
Copy Markdown
Collaborator

Problem

After moving the bot workflows to the self-hosted peco-driver runner (#538), actions/setup-python fails there:

Version 3.11 was not found in the local cache … not found for this operating system.

Self-hosted runners have no GitHub tool-cache (that's why setup-python "just worked" on ubuntu-latest), and this one can't reach the version manifest.

Fix

The runner is provisioned with system python3.11 + Node. All four bot workflows drop actions/setup-python and instead build a venv from the runner's python3.11, put on $GITHUB_PATH so later pip / python -m … steps resolve to 3.11 unchanged. Node (for @anthropic-ai/claude-code, which the Python SDK shells out to) comes from the runner.

Followup workflows keep their if: skip != 'true' guard. YAML validated; title checked against adbc's checker.

Requires (runner provisioning, one-time)

python3.11 + python3.11-venv and Node/npm installed on the peco-driver runner and on the runner service's PATH.

This pull request and its description were written by Isaac.

actions/setup-python can't provision Python on the self-hosted peco-driver
runner (no GitHub hosted tool-cache; can't reach the version manifest). The
runner is provisioned with system python3.11 + Node; replace setup-python in
all four bot workflows with a venv built from the runner's python3.11 (kept on
PATH so later pip / python -m steps resolve to 3.11). Node (for the
@anthropic-ai/claude-code CLI the SDK shells out to) comes from the runner.

Co-authored-by: Isaac
@eric-wang-1990 eric-wang-1990 changed the title ci(.github/workflows): self-install Python 3.11 via uv on the peco-driver runner ci(.github/workflows): use the runner's system Python 3.11 (peco-driver) Jun 21, 2026
@eric-wang-1990
eric-wang-1990 force-pushed the ci/bot-python-self-hosted branch from 75999cb to 41db3d5 Compare June 21, 2026 07:36
@eric-wang-1990
eric-wang-1990 merged commit fed4f79 into main Jun 21, 2026
16 checks passed
@eric-wang-1990
eric-wang-1990 deleted the ci/bot-python-self-hosted branch June 21, 2026 07:59
eric-wang-1990 added a commit that referenced this pull request Jun 21, 2026
…fix (#540)

## Problem

On the self-hosted peco-driver runner, `npm install -g
@anthropic-ai/claude-code` fails:

> npm error EACCES: permission denied, mkdir
'/usr/local/lib/node_modules'

The default global npm dir is root-owned; the runner runs as a non-root
user (`azureuser`). (This is the step after the now-fixed Python setup +
SSO'd engine clone.)

## Fix

All four bot workflows: install the CLI to a per-job prefix the runner
user owns and put it on PATH:
```bash
export NPM_CONFIG_PREFIX="$RUNNER_TEMP/npm-global"
mkdir -p "$NPM_CONFIG_PREFIX/bin"
npm install -g @anthropic-ai/claude-code
echo "$RUNNER_TEMP/npm-global/bin" >> "$GITHUB_PATH"
```

So the `claude` CLI (which the Python `claude-agent-sdk` shells out to)
is on PATH for the run step. Self-contained — no runner changes,
survives runner reimage. Same per-job philosophy as the Python venv
(#539).

This pull request and its description were written by Isaac.
eric-wang-1990 added a commit that referenced this pull request Jun 22, 2026
…iver (#541)

## Problem

The engineer-bot Fix workflow fails at **Setup .NET** on the self-hosted
peco-driver runner:
> mkdir: cannot create directory '/usr/share/dotnet': Permission denied
> ##[error]Failed to install dotnet, exit code: 1

`actions/setup-dotnet` installs to root-owned `/usr/share/dotnet`, but
the runner runs as non-root (`azureuser`).

## Fix

Set `DOTNET_INSTALL_DIR: ${{ runner.temp }}/dotnet` on the Setup .NET
step in `engineer-bot.yaml` + `engineer-bot-followup.yml`, so it
installs to a user-writable dir (setup-dotnet then adds it to PATH +
sets DOTNET_ROOT for later steps). Self-contained; works regardless of
which peco-driver runner the job lands on.

Same non-root-runner class we already fixed for the Python venv (#539)
and the npm prefix (#540). (`reyden-rest-nightly.yml` happens to land on
runners with .NET pre-installed, so it no-ops setup-dotnet — but the
bots can't rely on that.)

This pull request and its description were written by Isaac.
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.

1 participant