Skip to content

fix(deps): lock filelock 4.2.4 past litellm's declared cap - #375

Merged
xaleryb merged 2 commits into
intel:mainfrom
xaleryb:fix/filelock-4-override
Nov 4, 2026
Merged

xaleryb merged 2 commits into
intel:mainfrom
xaleryb:fix/filelock-4-override

Conversation

@xaleryb

@xaleryb xaleryb commented Nov 3, 2026

Copy link
Copy Markdown
Contributor

filelock 3.32.7 in requirements.lock.txt and requirements-ci.lock.txt carries thirteen advisories (GHSA-v4x8-3wr5-3wq8, GHSA-9vhv-jxww-xfm5, GHSA-567q-5qvw-pf92, GHSA-j8f7-rjxc-mr56, GHSA-cwqr-hh33-gh44, GHSA-9c4x-gm8v-wgc4, GHSA-6627-m3xw-93mp, GHSA-m462-7rxw-wvpg, GHSA-69hj-f68j-2879, GHSA-8mx5-7m5m-r77g, GHSA-9j6q-wvj5-jgjg, GHSA-rfpc-qcw5-3pc4, GHSA-fq56-3cx3-fjxp), all fixed in 4.2.1. Scanners that read both locks report each of them twice. This PR locks filelock 4.2.4 and empties the three ignore lists.

Why an override and not a wait. Every litellm release up to 1.106.6 declares filelock<4.0. litellm lifted it on its main (filelock<5, BerriAI/litellm#49137, merged 2026-10-30), but no release carries it yet, and its stable line has stayed on 1.106 since 2026-10-18. The cap is metadata only: litellm calls FileLock(path, timeout=10, mode=0o600) in two proxy CLI commands, a signature 4.x keeps. Every other consumer in the locks already accepts 4.x (huggingface-hub, datasets, cachecontrol, python-discovery, virtualenv).

What changes

  • requirements-overrides.txt (filelock>=4.2.1) is passed to both lock header commands as --override=requirements-overrides.txt, a form Renovate's pip-compile manager accepts. Recompiling changes one pin in each lock: filelock 3.32.7 -> 4.2.4.
  • Every install that includes requirements.lock.txt passes --no-deps: 12 workflow steps, .agent-eval/Dockerfile and make dev. The locks are the full closure; without the flag, pip and uv refuse litellm's declared cap. Installs of the tools lock alone are unchanged.
  • The thirteen IDs leave pip-audit.yml, dokimi/osv-scanner.toml and allow-ghsas in dependency-review.yml. SECURITY.md, CONTRIBUTING.md and a changelog fragment say what was done and when to undo it.
  • tests/test_advisory_lists.py accepts empty lists, and a new test fails when a list ignores an ID while SECURITY.md says the locks have no advisory.

Checked on Linux, Python 3.13

  • pip install --no-deps --require-hashes of the main lock with the tools, docs and mutation locks installs filelock 4.2.4; the same install without --no-deps, and uv without it, fail on litellm's cap.
  • Full suite 12621 passed; ruff, mypy, bandit -ll clean; cli.py run --strict exits 0; make dev and the eval image build succeed.
  • The pip-audit step as written in this branch reports no advisory; the same step on the main locks fails with the 13 filelock IDs.
  • pip check reports one mismatch, litellm's filelock<4.0, as SECURITY.md says.

Undo once a litellm release allows filelock 4: delete requirements-overrides.txt, drop --override from both headers and --no-deps from those installs, and recompile.

filelock 3.32.7 carries thirteen advisories, all fixed in 4.2.1. Every litellm
release still declares filelock<4.0 (its main has lifted it) while its code
only calls FileLock(path, timeout=, mode=), which 4.x keeps. Both lock headers
pass --override=requirements-overrides.txt, every install of the main lock
passes --no-deps, and the three ignore lists are empty again.

Signed-off-by: Alexander Rybkin <alexander.rybkin@intel.com>
@xaleryb
xaleryb requested a review from a team as a code owner November 3, 2026 06:32
@exai-bot

exai-bot commented Nov 3, 2026 •

Copy link
Copy Markdown

✅ OpenCodeReview: Review complete: 0 finding(s) across 15 selected item(s).

Review details
  • Commit reviewed: 419ef54 against merge base d32c4d6
  • Coverage: 15 files in 2 groups
  • Engine: OpenCodeReview v1.13.3, us.openai.gpt-6.1-sol
  • Usage: 179k tokens (116k from cache), 28s
  • Tool calls: 10 (5 file_read, 4 code_search, 1 file_find)
  • Development and CI environment updates: 9 files
  • Dependency security policy and advisory handling: 6 files

check_comment_blocks.py caps a touched comment block at 2 lines; the --no-deps reason is in SECURITY.md and CONTRIBUTING.md.

Signed-off-by: Alexander Rybkin <alexander.rybkin@intel.com>

@napetrov napetrov left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Two nits inline. Also: ci_local.py tools now prints --no-deps as a spec, so make dev passes it through (harmless, unannounced). The reworked lock-advisory test passes on base too, so offline nothing pins the filelock change; only the network pip-audit job does.

Coverage: plain + edge passes with probes; CI green.

Findings outside the diff

dokimi/mkdocs.yml:6

nit: this header (and line 8 of requirements-docs.lock.txt) still says pip install -r requirements.lock.txt -r requirements-docs.lock.txt without --no-deps. On head pip's resolver then rejects the pinned filelock==4.2.4 against litellm's filelock<4.0. Every other install line got --no-deps.


def _dependency_review_ids() -> set[str]:
"""No allow-ghsas line means none allowed."""
match = re.search(r"allow-ghsas:\s*(.+)", DEPENDENCY_REVIEW.read_text(encoding="utf-8"))

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

nit: allow-ghsas:\s*(.+) takes the next line when the value is empty (allow-ghsas: alone or ""), giving a bogus ID set like {'# summary only'}. Use [ \t]*([^\n]*) and treat empty as none, as the docstring says.

@napetrov napetrov left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Approving at 419ef54: CI green, only nits (inline); they can go in this PR or a follow-up.

@codecov-commenter

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.30%. Comparing base (d32c4d6) to head (419ef54).
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #375      +/-   ##
==========================================
- Coverage   94.31%   94.30%   -0.01%     
==========================================
  Files         309      309              
  Lines       39437    39437              
  Branches     6672     6672              
==========================================
- Hits        37194    37192       -2     
- Misses       1432     1433       +1     
- Partials      811      812       +1     

see 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@antonwolfy antonwolfy left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM. The override is applied in both lock headers, filelock 4.2.4 is pinned with identical hashes in both locks, and every install of the main lock in the workflows, the Dockerfile and make dev passes --no-deps. The ignore lists are empty and consistent with SECURITY.md.

I agree with @napetrov's nits on the allow-ghsas regex in test_advisory_lists.py and on mkdocs.yml:6 and requirements-docs.lock.txt:8 missing --no-deps. New evidence: pip check on the installed head venv reports only litellm's filelock<4.0, so the docs install fails loudly, not silently.

What I ran, on a Linux review host at 419ef54:

  • make ci-local: 30 passed, 0 failed, 7 skipped (job conditions or tools absent offline); the pip-audit step reports no advisory with the ignore flags removed.
  • Both commits carry a Signed-off-by.
  • Mutation checks on the advisory-list tests: an ID left in only one list, or in all three while SECURITY.md says there is no advisory, or the reverse, each fail the suite.

Checked, no issues

  • Installs: a grep of every requirements.lock.txt install in .github/workflows, .agent-eval/Dockerfile and the Makefile found --no-deps on each, except the docs lines named above. Tools-lock-only installs do not include litellm and need no flag.
  • Locks: pip check reports exactly the one litellm mismatch that SECURITY.md describes; no other consumer of filelock objects to 4.2.4.
  • Docs: SECURITY.md, CONTRIBUTING.md and the changelog fragment match the tree.

@xaleryb
xaleryb merged commit c10065b into intel:main Nov 4, 2026
24 checks passed
@xaleryb
xaleryb deleted the fix/filelock-4-override branch November 4, 2026 04:11
xaleryb added a commit to napetrov/dokimi that referenced this pull request Nov 4, 2026
…ince intel#375

The lock pins filelock 4.2.4 past litellm's declared filelock<4.0, so pip's resolver
refuses it without --no-deps. The install-step test now pins the flag.

Signed-off-by: Alexander Rybkin <alexander.rybkin@intel.com>
xaleryb added a commit that referenced this pull request Nov 4, 2026
… (part of #318) (#319)

* feat(action): composite setup action; repo-eval uses it (part of #318)

action/setup installs dokimi at a pinned commit (SHA, or a tag resolved to
its commit; a branch is refused) with the locked dependencies, sets up
Python, and exports CI=true, DOKIMI_RUNS_DIR and, with max-usd, DOKIMI_MAX_USD.
The output directory has a fixed layout (runs/) for upload-artifact. A paid
job (paid: true) must pass max-usd; a free job needs none.

repo-eval.yml moves its ref resolution and install into the action; its
inputs, outputs and permissions are unchanged. The action is read from the
called workflow's own commit (job.workflow_sha), so external callers need no
checkout of their own, and it is removed again after the setup step.

zizmor covers action/ in CI and pre-commit; repo-eval-self runs on action/ changes.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* fix(action): keep the setup action checkout until the job ends (part of #318)

The composite's post steps read its action.yml from .dokimi-action at job
end. Removing the checkout after the setup step made "Post Set up dokimi"
fail (CI run 41170348715, self / repo validate; scan and tasks-check were
skipped behind it). The checkout is one sparse file tree, so it stays.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* ci(repo-eval): keep the setup-action comment to two lines

The comment block above the validate job's setup-action checkout ran to
three lines, which the comment-block check fails (AGENTS.md: two lines of
reason, link the rest). Same content, shorter: the action comes from the
workflow's commit, and it stays until the job ends because the composite's
post steps read it.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* ci: move the setup action to actions/setup

Follows the layout of abicheck: sub-actions live under actions/<name>/, and
the public entry, if one is added later, is a root action.yml. Paths move in
repo-eval.yml (sparse checkout and the uses line), repo-eval-self.yml (the
path filter and smoke paths), ci.yml (the zizmor scope) and the pre-commit
zizmor files regex. No behaviour change.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* Address review: key the pip cache file under the workspace

setup-python hashes cache-dependency-path with glob.hashFiles, which only
sees files under GITHUB_WORKSPACE. The key file was in runner.temp, so a
cache-enabled call hashed nothing and setup-python failed.

The key file now sits in $GITHUB_WORKSPACE/.dokimi-setup, and
cache-dependency-path points at it. The test pins both ends statically;
no runner runs a cache-enabled job here.

Thread: PRRT_kwDOVBg7g86ySzDB
Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* fix(setup): check the action out at dokimi-ref from its own repository

The reusable workflow checked out the setup action from dokimi-repository,
the package source, at job.workflow_sha. That expression is not a context
property, so the ref was empty, and a fork's dokimi-repository asked the
fork for a commit it may not hold.

- New input dokimi-action-repository (default intel/dokimi) is the repository
  of the action checkout; all three checkouts use it.
- The checkout ref is dokimi-ref, the commit the caller already pins in uses:.
- repo-eval-self.yml passes its own repository, so a fork's self-check still
  finds its commit.

The setup action also drops the paid and max-usd inputs and the DOKIMI_RUNS_DIR
and DOKIMI_MAX_USD exports. Nothing enforced the cap, and no writer reads
DOKIMI_RUNS_DIR; out-dir is the directory the caller writes to.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* fix(setup): drop a comment about a post step, widen zizmor's hook, tighten the key test

- repo-eval.yml: the checkout comment said the composite's post steps read the
  checkout; the composite has no post step.
- .pre-commit-config.yaml: the zizmor hook matched only actions/<dir>/action.yml,
  not nested composites that the CI zizmor run on `actions` covers.
- test_setup_action.py: the pip-key test matched the path anywhere in a step;
  it now needs the path to be the target of a redirect.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* fix(setup): drop the pip cache; out-dir newline; pin the action commit

CodeQL reports actions/cache-poisoning/poisonable-step on the setup
steps: a pip cache restored in a run that checks out the caller's
dokimi-ref is the path it flags. The cache input was opt-in and no
caller or doc uses it, so setup-python runs without a cache, and the
key file that fed it is gone.

out-dir: a newline is refused before mkdir, and the captured absolute
path keeps a trailing newline so the check after the capture sees it.

validate records the commit the setup action was checked out at
(action-sha). scan and tasks-check check the action out at that SHA,
not at dokimi-ref again, so a tag that moves mid-run does not split
the jobs.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* fix(setup): keep the out-dir path intact when capturing it

pwd prints a line terminator, so the capture always kept a newline and
the next check refused every out-dir, failing validate and its
dependents. The capture keeps the sentinel so a newline at the end of
the path is still seen and refused. The tests now run the step script
with bash, covering the default path, an out-dir with a newline, and a
cwd ending in a newline.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* Treat an out-dir starting with a dash as a path

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* Run the newline cwd test with out-dir set to a dot

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* Assert the exact action-sha mapping and recorder command

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* Prefix a relative out-dir with ./ so a lone dash is a path

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* ci(repo-eval): check the setup action out at a commit resolved first

dokimi-ref used to go to actions/checkout as is, so a branch named like a
tag could make the checkout run branch code. The validate job now resolves
the ref to a commit before the checkout: a 40-digit SHA passes through, a
tag resolves to its peeled commit, anything else is refused. The test runs
the resolver with a fake git that lists a tag and its peeled commit.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* ci(repo-eval): install the action's resolved commit when both repos match

validate resolved dokimi-ref for the action checkout, then the setup step
resolved the same tag again with its own ls-remote. A tag that moved in
between made validate run one commit and install another. With
dokimi-repository equal to dokimi-action-repository the setup step now gets
the resolved commit; a different package repository still resolves its own ref.

Tests: the wiring is pinned in test_repo_eval_action_checkout; a commit ref
is installed as given with no ls-remote, and a tag resolves to its peeled commit.
Comment block in repo-eval.yml cut to two lines (check_comment_blocks).

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* test(ci): two-line comment for the repo-eval wiring test

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* Accept an uppercase 40-digit SHA as dokimi-ref and lower-case it

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* test(ci): pin the setup wiring: package commit, no credentials, install step, uppercase resolver

- scan and tasks-check install the package commit validate gated (dokimi-sha), not dokimi-ref.
- Every actions/checkout in repo-eval.yml sets persist-credentials: false.
- The Install dokimi step installs the resolved SHA, with --require-hashes for the lock and --no-deps for dokimi.
- The repo-eval resolver lower-cases an uppercase 40-digit SHA, as action.yml does.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* test(ci): the wiring tests check needs: validate and the install URL uses the resolved SHA

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* Allow a slash in a tag name in both dokimi-ref resolvers

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* Allow a plus in a tag name in both dokimi-ref resolvers

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* test(setup): pin the full lock URL and the validate output dokimi-sha reads

The install test accepted any lock URL, so /main/ passed. The checkout test
did not pin where validate's dokimi-sha output comes from, so a mutation to
the raw input passed. Both assertions were red on the mutations before this.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* Pin setup-python to v7.1.0 in the setup action

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* docs(ci): zizmor command covers the composite actions too

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* Run CodeQL on pull requests that change only actions/

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* Pin that validate runs the pinned setup action copy

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* docs(ci): dokimi-ref must contain actions/setup

A ref from before the setup action has no actions/ directory, so the
job fails at Set up dokimi. Say so in the input, the workflow header
and the contract.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* fix(action): install the lock with --no-deps, as main's installs do since #375

The lock pins filelock 4.2.4 past litellm's declared filelock<4.0, so pip's resolver
refuses it without --no-deps. The install-step test now pins the flag.

Signed-off-by: Alexander Rybkin <alexander.rybkin@intel.com>

* ci: keep repo-eval.yml's header comment as on main

The actions/setup requirement is already in the dokimi-ref input description; the edited 21-line header failed check_comment_blocks.py.

Signed-off-by: Alexander Rybkin <alexander.rybkin@intel.com>

---------

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>
Signed-off-by: Anton Volkov <antonwolfy@gmail.com>
Signed-off-by: Alexander Rybkin <alexander.rybkin@intel.com>
Co-authored-by: Anton Volkov <antonwolfy@gmail.com>
Co-authored-by: Vladislav Perevezentsev <vladislav.perevezentsev@intel.com>
Co-authored-by: Alexander Rybkin <alexander.rybkin@intel.com>
napetrov pushed a commit to napetrov/dokimi that referenced this pull request Nov 4, 2026
* fix(deps): lock filelock 4.2.4 past litellm's declared cap

filelock 3.32.7 carries thirteen advisories, all fixed in 4.2.1. Every litellm
release still declares filelock<4.0 (its main has lifted it) while its code
only calls FileLock(path, timeout=, mode=), which 4.x keeps. Both lock headers
pass --override=requirements-overrides.txt, every install of the main lock
passes --no-deps, and the three ignore lists are empty again.

Signed-off-by: Alexander Rybkin <alexander.rybkin@intel.com>

* ci: leave the tools-step comment as it was

check_comment_blocks.py caps a touched comment block at 2 lines; the --no-deps reason is in SECURITY.md and CONTRIBUTING.md.

Signed-off-by: Alexander Rybkin <alexander.rybkin@intel.com>

---------

Signed-off-by: Alexander Rybkin <alexander.rybkin@intel.com>
napetrov added a commit to napetrov/dokimi that referenced this pull request Nov 4, 2026
… (part of intel#318) (intel#319)

* feat(action): composite setup action; repo-eval uses it (part of intel#318)

action/setup installs dokimi at a pinned commit (SHA, or a tag resolved to
its commit; a branch is refused) with the locked dependencies, sets up
Python, and exports CI=true, DOKIMI_RUNS_DIR and, with max-usd, DOKIMI_MAX_USD.
The output directory has a fixed layout (runs/) for upload-artifact. A paid
job (paid: true) must pass max-usd; a free job needs none.

repo-eval.yml moves its ref resolution and install into the action; its
inputs, outputs and permissions are unchanged. The action is read from the
called workflow's own commit (job.workflow_sha), so external callers need no
checkout of their own, and it is removed again after the setup step.

zizmor covers action/ in CI and pre-commit; repo-eval-self runs on action/ changes.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* fix(action): keep the setup action checkout until the job ends (part of intel#318)

The composite's post steps read its action.yml from .dokimi-action at job
end. Removing the checkout after the setup step made "Post Set up dokimi"
fail (CI run 41170348715, self / repo validate; scan and tasks-check were
skipped behind it). The checkout is one sparse file tree, so it stays.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* ci(repo-eval): keep the setup-action comment to two lines

The comment block above the validate job's setup-action checkout ran to
three lines, which the comment-block check fails (AGENTS.md: two lines of
reason, link the rest). Same content, shorter: the action comes from the
workflow's commit, and it stays until the job ends because the composite's
post steps read it.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* ci: move the setup action to actions/setup

Follows the layout of abicheck: sub-actions live under actions/<name>/, and
the public entry, if one is added later, is a root action.yml. Paths move in
repo-eval.yml (sparse checkout and the uses line), repo-eval-self.yml (the
path filter and smoke paths), ci.yml (the zizmor scope) and the pre-commit
zizmor files regex. No behaviour change.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* Address review: key the pip cache file under the workspace

setup-python hashes cache-dependency-path with glob.hashFiles, which only
sees files under GITHUB_WORKSPACE. The key file was in runner.temp, so a
cache-enabled call hashed nothing and setup-python failed.

The key file now sits in $GITHUB_WORKSPACE/.dokimi-setup, and
cache-dependency-path points at it. The test pins both ends statically;
no runner runs a cache-enabled job here.

Thread: PRRT_kwDOVBg7g86ySzDB
Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* fix(setup): check the action out at dokimi-ref from its own repository

The reusable workflow checked out the setup action from dokimi-repository,
the package source, at job.workflow_sha. That expression is not a context
property, so the ref was empty, and a fork's dokimi-repository asked the
fork for a commit it may not hold.

- New input dokimi-action-repository (default intel/dokimi) is the repository
  of the action checkout; all three checkouts use it.
- The checkout ref is dokimi-ref, the commit the caller already pins in uses:.
- repo-eval-self.yml passes its own repository, so a fork's self-check still
  finds its commit.

The setup action also drops the paid and max-usd inputs and the DOKIMI_RUNS_DIR
and DOKIMI_MAX_USD exports. Nothing enforced the cap, and no writer reads
DOKIMI_RUNS_DIR; out-dir is the directory the caller writes to.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* fix(setup): drop a comment about a post step, widen zizmor's hook, tighten the key test

- repo-eval.yml: the checkout comment said the composite's post steps read the
  checkout; the composite has no post step.
- .pre-commit-config.yaml: the zizmor hook matched only actions/<dir>/action.yml,
  not nested composites that the CI zizmor run on `actions` covers.
- test_setup_action.py: the pip-key test matched the path anywhere in a step;
  it now needs the path to be the target of a redirect.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* fix(setup): drop the pip cache; out-dir newline; pin the action commit

CodeQL reports actions/cache-poisoning/poisonable-step on the setup
steps: a pip cache restored in a run that checks out the caller's
dokimi-ref is the path it flags. The cache input was opt-in and no
caller or doc uses it, so setup-python runs without a cache, and the
key file that fed it is gone.

out-dir: a newline is refused before mkdir, and the captured absolute
path keeps a trailing newline so the check after the capture sees it.

validate records the commit the setup action was checked out at
(action-sha). scan and tasks-check check the action out at that SHA,
not at dokimi-ref again, so a tag that moves mid-run does not split
the jobs.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* fix(setup): keep the out-dir path intact when capturing it

pwd prints a line terminator, so the capture always kept a newline and
the next check refused every out-dir, failing validate and its
dependents. The capture keeps the sentinel so a newline at the end of
the path is still seen and refused. The tests now run the step script
with bash, covering the default path, an out-dir with a newline, and a
cwd ending in a newline.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* Treat an out-dir starting with a dash as a path

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* Run the newline cwd test with out-dir set to a dot

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* Assert the exact action-sha mapping and recorder command

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* Prefix a relative out-dir with ./ so a lone dash is a path

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* ci(repo-eval): check the setup action out at a commit resolved first

dokimi-ref used to go to actions/checkout as is, so a branch named like a
tag could make the checkout run branch code. The validate job now resolves
the ref to a commit before the checkout: a 40-digit SHA passes through, a
tag resolves to its peeled commit, anything else is refused. The test runs
the resolver with a fake git that lists a tag and its peeled commit.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* ci(repo-eval): install the action's resolved commit when both repos match

validate resolved dokimi-ref for the action checkout, then the setup step
resolved the same tag again with its own ls-remote. A tag that moved in
between made validate run one commit and install another. With
dokimi-repository equal to dokimi-action-repository the setup step now gets
the resolved commit; a different package repository still resolves its own ref.

Tests: the wiring is pinned in test_repo_eval_action_checkout; a commit ref
is installed as given with no ls-remote, and a tag resolves to its peeled commit.
Comment block in repo-eval.yml cut to two lines (check_comment_blocks).

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* test(ci): two-line comment for the repo-eval wiring test

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* Accept an uppercase 40-digit SHA as dokimi-ref and lower-case it

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* test(ci): pin the setup wiring: package commit, no credentials, install step, uppercase resolver

- scan and tasks-check install the package commit validate gated (dokimi-sha), not dokimi-ref.
- Every actions/checkout in repo-eval.yml sets persist-credentials: false.
- The Install dokimi step installs the resolved SHA, with --require-hashes for the lock and --no-deps for dokimi.
- The repo-eval resolver lower-cases an uppercase 40-digit SHA, as action.yml does.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* test(ci): the wiring tests check needs: validate and the install URL uses the resolved SHA

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* Allow a slash in a tag name in both dokimi-ref resolvers

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* Allow a plus in a tag name in both dokimi-ref resolvers

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* test(setup): pin the full lock URL and the validate output dokimi-sha reads

The install test accepted any lock URL, so /main/ passed. The checkout test
did not pin where validate's dokimi-sha output comes from, so a mutation to
the raw input passed. Both assertions were red on the mutations before this.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* Pin setup-python to v7.1.0 in the setup action

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* docs(ci): zizmor command covers the composite actions too

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* Run CodeQL on pull requests that change only actions/

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* Pin that validate runs the pinned setup action copy

Signed-off-by: Anton Volkov <antonwolfy@gmail.com>

* docs(ci): dokimi-ref must contain actions/setup

A ref from before the setup action has no actions/ directory, so the
job fails at Set up dokimi. Say so in the input, the workflow header
and the contract.

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>

* fix(action): install the lock with --no-deps, as main's installs do since intel#375

The lock pins filelock 4.2.4 past litellm's declared filelock<4.0, so pip's resolver
refuses it without --no-deps. The install-step test now pins the flag.

Signed-off-by: Alexander Rybkin <alexander.rybkin@intel.com>

* ci: keep repo-eval.yml's header comment as on main

The actions/setup requirement is already in the dokimi-ref input description; the edited 21-line header failed check_comment_blocks.py.

Signed-off-by: Alexander Rybkin <alexander.rybkin@intel.com>

---------

Signed-off-by: Nikolay Petrov <nikolay.a.petrov@intel.com>
Signed-off-by: Anton Volkov <antonwolfy@gmail.com>
Signed-off-by: Alexander Rybkin <alexander.rybkin@intel.com>
Co-authored-by: Anton Volkov <antonwolfy@gmail.com>
Co-authored-by: Vladislav Perevezentsev <vladislav.perevezentsev@intel.com>
Co-authored-by: Alexander Rybkin <alexander.rybkin@intel.com>
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.

5 participants