Skip to content

ci: skip uv-lock on pre-commit.ci (no network access there) - #15112

Merged
cclauss merged 1 commit into
TheAlgorithms:masterfrom
priya-sundaram-dev:fix-precommit-ci-uv-lock-network
Aug 28, 2026
Merged

ci: skip uv-lock on pre-commit.ci (no network access there)#15112
cclauss merged 1 commit into
TheAlgorithms:masterfrom
priya-sundaram-dev:fix-precommit-ci-uv-lock-network

Conversation

@priya-sundaram-dev

Copy link
Copy Markdown
Contributor

Describe your change:

The uv-lock hook added in #15111 is failing on pre-commit.ci for every PR:

uv-lock..................................................................Failed
- hook id: uv-lock
error: Request failed after 3 retries in 3.4s
  Caused by: Failed to fetch: `https://pypi.org/simple/matplotlib/`
  Caused by: dns error: failed to lookup address information: Temporary failure in name resolution

pre-commit.ci runs hooks in a sandbox without network access, but uv-lock resolves dependencies against PyPI, so it can never succeed there. This adds skip: [uv-lock] under the ci key so pre-commit.ci stops reporting a red check on unrelated PRs. The hook still runs locally and the uv.lock file is still kept in sync by the dedicated uv-lock GitHub Actions job / local runs.

This is a follow-up fixing a regression from my own #15111 — sorry for the noise.

  • Add an algorithm?
  • Fix a bug or typo in an existing algorithm?
  • Add or change doctests? — Note: Please avoid changing both code and tests in a single pull request.
  • Documentation change?

Checklist:

  • I have read CONTRIBUTING.md.
  • This pull request is all my own work -- I have not plagiarized.
  • I know that pull requests will not be merged if they fail the automated tests.
  • This PR only changes one algorithm file. — CI/config change only.
  • All new Python files are placed inside an existing directory.
  • All filenames are in all lowercase characters with no spaces or dashes.
  • All functions and variable names follow Python naming conventions.
  • All function parameters and return values are annotated with Python type hints.
  • All functions have doctests that pass the automated testing.
  • All new algorithms include at least one URL that points to Wikipedia or another similar explanation.
  • If this pull request resolves one or more open issues then the description above includes the issue number(s).

The uv-lock hook (added in TheAlgorithms#15111) resolves dependencies against PyPI, but
pre-commit.ci runs hooks in a sandbox with no network access, so it fails on
every PR with a DNS lookup error. Skip it on pre-commit.ci via the ci.skip
key; the hook still runs locally and in the uv-lock CI job.
@algorithms-keeper algorithms-keeper Bot added enhancement This PR modified some existing files awaiting reviews This PR is ready to be reviewed labels Aug 28, 2026
@cclauss
cclauss enabled auto-merge (squash) August 28, 2026 13:38
@algorithms-keeper algorithms-keeper Bot removed the awaiting reviews This PR is ready to be reviewed label Aug 28, 2026
@cclauss
cclauss merged commit 2b81877 into TheAlgorithms:master Aug 28, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement This PR modified some existing files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants