Skip to content

node:worker_threads: per-thread --use-system-ca, real eventLoopUtilization, --cpu-prof in workers, node's online timing, error.code / stack-getter / timeOrigin fixes, async_hooks WORKER resource, worker_threads dc channel (+10 upstream tests) #22673

node:worker_threads: per-thread --use-system-ca, real eventLoopUtilization, --cpu-prof in workers, node's online timing, error.code / stack-getter / timeOrigin fixes, async_hooks WORKER resource, worker_threads dc channel (+10 upstream tests)

node:worker_threads: per-thread --use-system-ca, real eventLoopUtilization, --cpu-prof in workers, node's online timing, error.code / stack-getter / timeOrigin fixes, async_hooks WORKER resource, worker_threads dc channel (+10 upstream tests) #22673

Workflow file for this run

name: Clippy
permissions:
contents: read
on:
workflow_call:
workflow_dispatch:
pull_request:
paths:
- "src/**/*.rs"
- "src/**/*.classes.ts"
- "src/codegen/**"
- "scripts/build/**"
- "scripts/build.ts"
- "Cargo.toml"
- "Cargo.lock"
- "clippy.toml"
- "rust-toolchain.toml"
- ".github/workflows/clippy.yml"
- ".github/actions/setup-bun/**"
- ".github/rust-matcher.json"
merge_group:
env:
BUN_VERSION: "1.3.14"
LLVM_VERSION_MAJOR: "21"
# Pin the toolchain explicitly so rustup ignores rust-toolchain.toml's
# `targets` list (11 cross triples ≈ 450 MB of prebuilt std we don't need
# to lint the host). Keep in sync with `channel` in rust-toolchain.toml.
RUSTUP_TOOLCHAIN: nightly-2026-07-20
jobs:
clippy:
name: cargo clippy
runs-on: ubuntu-latest
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
steps:
- name: Checkout
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Setup Bun
uses: ./.github/actions/setup-bun
with:
bun-version: ${{ env.BUN_VERSION }}
- name: Setup system deps
# cmake/ninja for `--configure-only`; clang-21 for toolchain detection
# (configure resolves cfg.cc/cxx even though we won't compile C++).
run: |
wget -qO- https://apt.llvm.org/llvm-snapshot.gpg.key | sudo tee /etc/apt/trusted.gpg.d/apt.llvm.org.asc > /dev/null
echo "deb http://apt.llvm.org/$(lsb_release -cs)/ llvm-toolchain-$(lsb_release -cs)-${LLVM_VERSION_MAJOR} main" | sudo tee /etc/apt/sources.list.d/llvm.list > /dev/null
sudo apt-get update -qq
sudo apt-get install -y -qq --no-install-recommends cmake ninja-build clang-${LLVM_VERSION_MAJOR} lld-${LLVM_VERSION_MAJOR} llvm-${LLVM_VERSION_MAJOR}
- name: Setup Rust
run: |
rustup toolchain install "$RUSTUP_TOOLCHAIN" --profile minimal --component clippy
rustup override set "$RUSTUP_TOOLCHAIN"
# rustc/clippy diagnostics → inline PR annotations
echo "::add-matcher::.github/rust-matcher.json"
- name: Generate codegen
# bun_runtime/bun_jsc/bun_core `include!()` files under
# build/debug/codegen/; clippy can't lint those crates without them.
# `clone-lolhtml` fetches the vendored Rust path-dep
# (the root `Cargo.toml` path-deps `lol_html` at `vendor/lolhtml`).
run: |
bun install --frozen-lockfile
bun scripts/build.ts --configure-only
ninja -C build/debug codegen clone-lolhtml
- name: cargo clippy
env:
BUN_CODEGEN_DIR: ${{ github.workspace }}/build/debug/codegen
run: bun run rust:clippy