Skip to content
Open
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
52 changes: 52 additions & 0 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,58 @@ jobs:
path: ${{ env.CCACHE_DIR }}
key: ${{ steps.cache.outputs.cache-primary-key }}

node-complexity:
if: ${{ github.actor != 'grout-bot' }}
permissions:
actions: write
runs-on: ubuntu-24.04
container: fedora:latest
env:
DEBIAN_FRONTEND: noninteractive
NEEDRESTART_MODE: l
CC: ccache gcc
BUILDTYPE: debugoptimized
SANITIZE: none
MESON_EXTRA_OPTS: -Ddpdk:cpu_instruction_set=x86-64-v3
steps:
- name: install system dependencies
run: |
set -xe
dnf install -y ccache git gcc make meson ninja-build \
pkgconf python3-pyelftools scdoc libmnl-devel binutils \
libcmocka-devel libedit-devel libevent-devel numactl-devel \
libsmartcols-devel libarchive-devel rdma-core-devel
- uses: actions/checkout@v4
Copy link

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

Missing checkout options compared to other jobs.

The actions/checkout@v4 step is missing persist-credentials: false and fetch-depth options that are explicitly set in the other jobs (build-and-tests, build-cross-aarch64, lint, commits). While the shallow clone may work for this job, the inconsistency with persist-credentials could be a security consideration.

Suggested fix
       - uses: actions/checkout@v4
+        with:
+          persist-credentials: false
+          fetch-depth: 0
+          ref: ${{ github.event.pull_request.head.sha || github.ref }}
🤖 Prompt for AI Agents
In @.github/workflows/check.yml at line 150, The checkout step using
actions/checkout@v4 is missing the same options used in other jobs; update that
step to include persist-credentials: false and the same fetch-depth value used
elsewhere (e.g., fetch-depth: 0) so it matches the other jobs' configuration and
removes the credential persistence inconsistency.

- run: echo "CCACHE_DIR=$(ccache -k cache_dir)" >> $GITHUB_ENV
- uses: actions/cache/restore@v4
id: cache
with:
path: ${{ env.CCACHE_DIR }}
key: ccache-x86_64-gcc-node-complexity
- run: ccache -z
- run: make
- run: devtools/node-complexity --compare devtools/complexity.json
- run: ccache -sv
- name: delete old cache
if: ${{ ! github.event.pull_request.commits }}
uses: actions/github-script@v7
with:
script: |
try {
await github.rest.actions.deleteActionsCacheByKey({
owner: context.repo.owner,
repo: context.repo.repo,
key: "${{ steps.cache.outputs.cache-primary-key }}"
});
} catch (error) {
if (error.status !== 404) throw error;
}
- uses: actions/cache/save@v4
if: ${{ ! github.event.pull_request.commits }}
with:
path: ${{ env.CCACHE_DIR }}
key: ${{ steps.cache.outputs.cache-primary-key }}

build-cross-aarch64:
if: ${{ github.actor != 'grout-bot' }}
permissions:
Expand Down
2 changes: 1 addition & 1 deletion GNUmakefile
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ rpm:
CLANG_FORMAT ?= clang-format
c_src = git ls-files '*.[ch]' ':!:subprojects'
all_files = git ls-files ':!:subprojects'
licensed_files = git ls-files ':!:*.svg' ':!:licenses' ':!:*.md' ':!:*.asc' ':!:subprojects' ':!:debian' ':!:.*' ':!:*.scdoc'
licensed_files = git ls-files ':!:*.svg' ':!:licenses' ':!:*.md' ':!:*.asc' ':!:subprojects' ':!:debian' ':!:.*' ':!:*.scdoc' ':!:*.json'

.PHONY: lint
lint:
Expand Down
Loading