Skip to content

verify-hardcoded-version: failures targeting 'release/YY.MM' branch #121

@jameslamb

Description

@jameslamb

Description

We recently started burndown for the RAPIDS 26.06 release, and so PRs started targeting a branch called release/26.04.

That caused verify-hardcoded-version failures like this, complaining about a few places where branches commonly show up in RAPIDS repos:

In file cpp/scripts/run-cmake-format.sh:6:70:
 # copied from: 
https://github.com/rapidsai/rapids-cmake/blob/release/26.04/ci/checks/run-cmake-
format.sh
warning: do not hard-code version, read from VERSION file instead

In file cpp/scripts/run-cmake-format.sh:6:70:
 # copied from: 
https://github.com/rapidsai/rapids-cmake/blob/release/26.04/ci/checks/run-cmake-
format.sh

In file RAPIDS_BRANCH:1:9:
 release/26.04
warning: do not hard-code version, read from VERSION file instead

In file RAPIDS_BRANCH:1:9:
 release/26.04

verify-pyproject-license.................................................Passed
RAPIDS dependency file generator.........................................Passed
cmake-format.............................................................Passed
- hook id: cmake-format
- duration: 0.67s

Using format file /tmp/rapids_cmake_ci/cmake-format-rapids-cmake.json

cmake-lint...............................................................Passed
- hook id: cmake-lint
- duration: 0.19s

Using format file /tmp/rapids_cmake_ci/cmake-format-rapids-cmake.json

(cugraph-gnn build)

On any repo overriding the default exclude: and not including RAPIDS_BRANCH.

Reproducible Example

In any repo overriding exclude: for this hook and not excluding RAPIDS_BRANCH, or downloading those cmake-format files.

pre-commit run --all-files verify-hardcoded-version

Notes

exclude: is relevant here because RAPIDS_BRANCH is excluded by default:

exclude: |
(?x)
(^|/)devcontainer[.]json$|
(^|/)dependencies[.]yaml$|
^[.]github/(workflows|ISSUE_TEMPLATE)/|
(^|/)pom[.]xml$|
^[.]pre-commit-config[.]yaml$|
^conda/environments/|
(^|/)VERSION$|
(^|/)RAPIDS_BRANCH$|
[.](md|rst|avro|parquet|png|orc|gz|pkl|sas7bdat)$

But that is ignored if a project passes its own exclude: configuration.

verify-hardcoded-version was rolled out to some RAPIDS repos in PRs like rapidsai/cucim#1022 (no central tracking issue).

Approach

check all the repos and fix them if needed

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions