diff --git a/.aspect/bazelrc/BUILD.bazel b/.aspect/bazelrc/BUILD.bazel index bfa2fb35..adf63e80 100644 --- a/.aspect/bazelrc/BUILD.bazel +++ b/.aspect/bazelrc/BUILD.bazel @@ -2,4 +2,10 @@ load("@aspect_bazel_lib//lib:bazelrc_presets.bzl", "write_aspect_bazelrc_presets") +filegroup( + name = "all_files", + srcs = glob(["**"]), + visibility = ["//:__pkg__"], +) + write_aspect_bazelrc_presets(name = "update_aspect_bazelrc_presets") diff --git a/.bazelignore b/.bazelignore index c7ca8d09..8356632e 100644 --- a/.bazelignore +++ b/.bazelignore @@ -1 +1,33 @@ -e2e +# make sure we ignore bazel managed directories for e2e tests +e2e/bazel-bzlmod-lock-file-from-args/bazel-bin +e2e/bazel-bzlmod-lock-file-from-args/bazel-out +e2e/bazel-bzlmod-lock-file-from-args/bazel-bazel-bzlmod-lock-file-from-args +e2e/bazel-bzlmod-lock-file-from-args/bazel-testlogs +e2e/bazel-bzlmod-lock-file/bazel-bin +e2e/bazel-bzlmod-lock-file/bazel-out +e2e/bazel-bzlmod-lock-file/bazel-bazel-bzlmod-lock-file +e2e/bazel-bzlmod-lock-file/bazel-testlogs +e2e/bazel-bzlmod-toolchain-from-source-lock-file/bazel-bin +e2e/bazel-bzlmod-toolchain-from-source-lock-file/bazel-out +e2e/bazel-bzlmod-toolchain-from-source-lock-file/bazel-bazel-bzlmod-toolchain-from-source-lock-file +e2e/bazel-bzlmod-toolchain-from-source-lock-file/bazel-testlogs +e2e/bazel-bzlmod-toolchain-from-source/bazel-bin +e2e/bazel-bzlmod-toolchain-from-source/bazel-out +e2e/bazel-bzlmod-toolchain-from-source/bazel-bazel-bzlmod-toolchain-from-source +e2e/bazel-bzlmod-toolchain-from-source/bazel-testlogs +e2e/bazel-bzlmod/bazel-bin +e2e/bazel-bzlmod/bazel-out +e2e/bazel-bzlmod/bazel-bazel-bzlmod +e2e/bazel-bzlmod/bazel-testlogs +e2e/bazel-workspace/bazel-bin +e2e/bazel-workspace/bazel-out +e2e/bazel-workspace/bazel-bazel-workspace +e2e/bazel-workspace/bazel-testlogs +e2e/bzlmod-toolchain-circular-dependencies/bazel-bin +e2e/bzlmod-toolchain-circular-dependencies/bazel-out +e2e/bzlmod-toolchain-circular-dependencies/bazel-bzlmod-toolchain-circular-dependencies +e2e/bzlmod-toolchain-circular-dependencies/bazel-testlogs +e2e/repo-yaml/bazel-bin +e2e/repo-yaml/bazel-out +e2e/repo-yaml/bazel-repo-yaml +e2e/repo-yaml/bazel-testlogs diff --git a/.bazelrc b/.bazelrc index 3700c9e5..86d9a12a 100644 --- a/.bazelrc +++ b/.bazelrc @@ -1,12 +1,20 @@ # Import Aspect bazelrc presets -import %workspace%/.aspect/bazelrc/bazel7.bazelrc # will only work in bazel7+ +import %workspace%/.aspect/bazelrc/bazel7.bazelrc import %workspace%/.aspect/bazelrc/convenience.bazelrc import %workspace%/.aspect/bazelrc/correctness.bazelrc import %workspace%/.aspect/bazelrc/debug.bazelrc import %workspace%/.aspect/bazelrc/performance.bazelrc +# Prevent Bazel from treating e2e child workspace BUILD files as packages +# When adding a new e2e test then `bazel run @rules_bazel_integration_test//tools:update_deleted_packages` +# needs to be executed +common --deleted_packages=e2e/bazel-bzlmod,e2e/bazel-bzlmod-lock-file,e2e/bazel-bzlmod-lock-file-from-args,e2e/bazel-bzlmod-toolchain-from-source,e2e/bazel-bzlmod-toolchain-from-source-lock-file,e2e/bazel-workspace,e2e/bzlmod-toolchain-circular-dependencies,e2e/repo-yaml + # Specific project flags go here if we have some + +# use prebuilt protoc common --incompatible_enable_proto_toolchain_resolution +common --@protobuf//bazel/toolchains:prefer_prebuilt_protoc # inside the rules project we build from source common --extra_toolchains=//cmd:bazeldnf-host-toolchain @@ -15,6 +23,9 @@ common --@protobuf//bazel/toolchains:prefer_prebuilt_protoc # make sure bazel doesn't complain on hosts without java common --java_runtime_version=remotejdk_21 +test --test_tag_filters=-allowed-to-fail +test --test_env=GO_TEST_WRAP_TESTV=1 + # Load any settings & overrides specific to the current user from `.bazelrc.user`. # This file should appear in `.gitignore` so that settings are not shared with team members. This # should be last statement in this config so the user configuration is able to overwrite flags from diff --git a/.gitattributes b/.gitattributes index e3d4e3b4..82aee033 100644 --- a/.gitattributes +++ b/.gitattributes @@ -5,6 +5,8 @@ docs/*.md linguist-generated=true # Exclude a bunch of paths to save some disk space e2e/bazel-bzlmod-* export-ignore e2e/bazel-workspace* export-ignore +e2e/.bazelrc export-ignore .github export-ignore pkg/*/testdata export-ignore tools/release export-ignore +REPO.bazel export-ignore diff --git a/.github/workflows/action.yml b/.github/workflows/action.yml index b3ed4e0b..ccc16a8e 100644 --- a/.github/workflows/action.yml +++ b/.github/workflows/action.yml @@ -17,8 +17,8 @@ jobs: build-and-test: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 - - uses: bazel-contrib/setup-bazel@0.8.5 + - uses: actions/checkout@v6.0.2 + - uses: bazel-contrib/setup-bazel@0.18.0 with: # Avoid downloading Bazel every time. bazelisk-cache: true @@ -28,159 +28,42 @@ jobs: repository-cache: true # enable some flags for CI bazelrc: | - import %workspace%/.aspect/bazelrc/ci.bazelrc - import %workspace%/.github/workflows/ci.bazelrc + try-import %workspace%/.aspect/bazelrc/ci.bazelrc + try-import %workspace%/.github/workflows/ci.bazelrc + try-import %workspace%/../../.aspect/bazelrc/ci.bazelrc + try-import %workspace%/../../.github/workflows/ci.bazelrc # keep a cache for MODULE.bazel repos external-cache: true - - run: bazelisk build //... && bazelisk test //... - - e2e-workspace-matrix: - strategy: - matrix: - version: - - version: 6.x - bazelrc: | - import %workspace%/../../.aspect/bazelrc/bazel6.bazelrc - - version: 7.x - bazelrc: | - import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc - import %workspace%/../../.aspect/bazelrc/bazel6.bazelrc - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: bazel-contrib/setup-bazel@0.8.5 - with: - # Avoid downloading Bazel every time. - bazelisk-cache: true - # Keep a disk-cache - disk-cache: true - # Share repository cache between workflows. - repository-cache: true - # enable some flags for CI - bazelrc: | - import %workspace%/../../.aspect/bazelrc/ci.bazelrc - import %workspace%/../../.github/workflows/ci.bazelrc - ${{ matrix.version.bazelrc }} - - run: cd e2e/bazel-workspace && USE_BAZEL_VERSION=${{ matrix.version.version }} bazelisk build //... - - e2e-bzlmod-matrix: - strategy: - matrix: - version: [7.x, 8.x] - path: - - bazel-bzlmod - - bazel-bzlmod-lock-file - - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: bazel-contrib/setup-bazel@0.8.5 - with: - # Avoid downloading Bazel every time. - bazelisk-cache: true - # Keep a disk-cache - disk-cache: true - # Share repository cache between workflows. - repository-cache: true - # enable some flags for CI - bazelrc: | - import %workspace%/../../.aspect/bazelrc/ci.bazelrc - import %workspace%/../../.github/workflows/ci.bazelrc - - run: cd e2e/${{ matrix.path }} && USE_BAZEL_VERSION=${{ matrix.version }} bazelisk build //... - - e2e-bzlmod-build-toolchain-matrix: - strategy: - matrix: - version: [7.x, 8.x] - - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: bazel-contrib/setup-bazel@0.8.5 - with: - # Avoid downloading Bazel every time. - bazelisk-cache: true - # Keep a disk-cache - disk-cache: true - # Share repository cache between workflows. - repository-cache: true - # enable some flags for CI - bazelrc: | - import %workspace%/../../.aspect/bazelrc/ci.bazelrc - import %workspace%/../../.github/workflows/ci.bazelrc - - run: cd e2e/bazel-bzlmod-toolchain-from-source && USE_BAZEL_VERSION=${{ matrix.version }} bazelisk build //... - - e2e-repo-yaml: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: bazel-contrib/setup-bazel@0.8.5 - with: - # Avoid downloading Bazel every time. - bazelisk-cache: true - # Keep a disk-cache - disk-cache: true - # Share repository cache between workflows. - repository-cache: true - # enable some flags for CI - bazelrc: | - import %workspace%/.aspect/bazelrc/ci.bazelrc - import %workspace%/.github/workflows/ci.bazelrc - - run: | - export USE_BAZEL_VERSION=7.x - bazelisk run //cmd -- init --fc 41 --output $(pwd)/repo.yaml - bazelisk run //cmd -- fetch --repofile $(pwd)/repo.yaml - bazelisk run //cmd -- resolve --repofile $(pwd)/repo.yaml bash - - e2e-bzlmod-lock-file-from-args: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: bazel-contrib/setup-bazel@0.8.5 - with: - # Avoid downloading Bazel every time. - bazelisk-cache: true - # Keep a disk-cache - disk-cache: true - # Share repository cache between workflows. - repository-cache: true - # enable some flags for CI - bazelrc: | - import %workspace%/../../.aspect/bazelrc/ci.bazelrc - import %workspace%/../../.github/workflows/ci.bazelrc - - run: | - export USE_BAZEL_VERSION=8.x - cd e2e/bazel-bzlmod-lock-file-from-args && bazelisk run :bazeldnf -- fetch && bazelisk run @bazeldnf_rpms//:update-lock-file && bazelisk build ... - - e2e-bzlmod-toolchain-circular-dependencies: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - uses: bazel-contrib/setup-bazel@0.8.5 - with: - # Avoid downloading Bazel every time. - bazelisk-cache: true - # Keep a disk-cache - disk-cache: true - # Share repository cache between workflows. - repository-cache: true - # enable some flags for CI - bazelrc: | - import %workspace%/../../.aspect/bazelrc/ci.bazelrc - import %workspace%/../../.github/workflows/ci.bazelrc - - id: prepare + - id: build + name: building repository + run: bazelisk build //... + - id: unit-tests + name: running unit tests + run: bazelisk test //... + - id: prepare-e2e-runner + name: preparing for e2e + # workaround for https://github.com/bazel-contrib/setup-bazel/issues/108 + # together with our customized default_test_runner + run: cat ~/.bazelrc | grep -v output_base > ~/.bazelrc.clean + if: success() || failure() # always run even if the previous step fails + - id: e2e-that-should-pass + name: running mandatory e2e tests + run: bazelisk test e2e --notest_keep_going + if: success() || failure() # always run even if the previous step fails + - id: e2e-that-are-allowed-to-fail + name: running e2e tests that are allowed to fail + if: success() || failure() # always run even if the previous step fails run: | - export USE_BAZEL_VERSION=8.x - cd e2e/bzlmod-toolchain-circular-dependencies - bazelisk run @bazeldnf_rpms//:fetch-repo - bazelisk run @bazeldnf_rpms//:update-lock-file - - id: test - run: | - export USE_BAZEL_VERSION=8.x - cd e2e/bzlmod-toolchain-circular-dependencies - bazelisk build //... || status=$? - if [ ${status} -ne 0 ]; then - echo "::warning::Optional job failed." - echo "optional_fail=true" >> "${GITHUB_OUTPUT}" - echo "optional_fail_status=${status}" >> "${GITHUB_OUTPUT}" - fi + ret_code=0 + bazel test //e2e --notest_keep_going --test_tag_filters=allowed-to-fail || ret_code=$? + case $ret_code in + 0) echo "All allowed-to-fail tests passed." ;; + 3) echo "::warning::Some allowed-to-fail e2e tests failed or timed out." ;; + 4) echo "No tests matched the allowed-to-fail filter." ;; + *) exit $ret_code ;; + esac + - uses: actions/upload-artifact@v4 # upload test results + if: success() || failure() # always run even if the previous step fails + with: + name: test-results + path: 'bazel-testlogs/**/test.xml' diff --git a/.github/workflows/allowed-to-fail.yml b/.github/workflows/allowed-to-fail.yml deleted file mode 100644 index 40b8a90a..00000000 --- a/.github/workflows/allowed-to-fail.yml +++ /dev/null @@ -1,56 +0,0 @@ -name: "build and test - allowed to fail" - -on: - pull_request_target: - branches: [ main ] - -concurrency: - # Cancel previous actions from the same PR or branch except 'main' branch. - # See https://docs.github.com/en/actions/using-jobs/using-concurrency and https://docs.github.com/en/actions/learn-github-actions/contexts for more info. - group: concurrency-group::${{ github.workflow }}::${{ github.event.pull_request.number > 0 && format('pr-{0}', github.event.pull_request.number) || github.ref_name }}${{ github.ref_name == 'main' && format('::{0}', github.run_id) || ''}} - cancel-in-progress: ${{ github.ref_name != 'main' }} - -jobs: - - e2e-bzlmod-toolchain-circular-dependencies: - runs-on: ubuntu-latest - permissions: - pull-requests: write - steps: - - uses: actions/checkout@v4 - - uses: bazel-contrib/setup-bazel@0.8.5 - with: - # Avoid downloading Bazel every time. - bazelisk-cache: true - # Keep a disk-cache - disk-cache: true - # Share repository cache between workflows. - repository-cache: true - # enable some flags for CI - bazelrc: | - import %workspace%/../../.aspect/bazelrc/ci.bazelrc - import %workspace%/../../.github/workflows/ci.bazelrc - - id: prepare - run: | - export USE_BAZEL_VERSION=8.x - cd e2e/bzlmod-toolchain-circular-dependencies - bazelisk run @bazeldnf_rpms//:fetch-repo - bazelisk run @bazeldnf_rpms//:update-lock-file - - id: test - run: | - export USE_BAZEL_VERSION=8.x - cd e2e/bzlmod-toolchain-circular-dependencies - bazelisk build //... || status=$? - if [ ${status} -ne 0 ]; then - echo "::warning::Optional job failed." - echo "optional_fail=true" >> "${GITHUB_OUTPUT}" - echo "optional_fail_status=${status}" >> "${GITHUB_OUTPUT}" - fi; - - name: Add comment if optional job failed; delete otherwise - uses: thollander/actions-comment-pull-request@v3 - with: - comment-tag: "circular-dependencies-optional-notice" - message: | - ### ⚠️ Optional job e2e-bzlmod-toolchain-circular-dependencies failed ⚠️ - - exit status: ${{ steps.test.outputs.optional_fail_status }} - mode: ${{ steps.test.outputs.optional_fail == 'true' && 'upsert' || 'delete' }} diff --git a/.github/workflows/test-report.yml b/.github/workflows/test-report.yml new file mode 100644 index 00000000..682f3e16 --- /dev/null +++ b/.github/workflows/test-report.yml @@ -0,0 +1,21 @@ +name: 'Test Report' +on: + workflow_run: + workflows: ['build and test'] # runs after our CI workflow for the given MR + types: + - completed +permissions: + contents: read + actions: read + checks: write +jobs: + report: + runs-on: ubuntu-latest + steps: + - uses: dorny/test-reporter@v2 + with: + artifact: test-results # artifact name + name: Bazel Test results + path: '**/test.xml' # Path to test results (inside artifact .zip) + reporter: java-junit + fail-on-error: 'false' # If allowed to fail tests fail then don't block the MR diff --git a/BUILD.bazel b/BUILD.bazel index ba608e97..fa6997ef 100644 --- a/BUILD.bazel +++ b/BUILD.bazel @@ -15,6 +15,7 @@ gazelle_binary( ) # gazelle:exclude .bazelbsp +# gazelle:exclude e2e/*/* # gazelle:prefix github.com/rmohr/bazeldnf # gazelle:resolve go github.com/bazelbuild/buildtools/build @com_github_bazelbuild_buildtools//build:go_default_library # gazelle:resolve go github.com/bazelbuild/buildtools/edit @com_github_bazelbuild_buildtools//edit:go_default_library @@ -95,3 +96,23 @@ bzl_library( ) # gazelle:exclude deps.bzl + +# Aggregates all parent workspace files so that child workspaces using +# local_path_override(path = "../..") can resolve the full module. +filegroup( + name = "local_repository_files", + srcs = [ + "MODULE.bazel", + "WORKSPACE", + "//:.github/workflows/ci.bazelrc", + "//.aspect/bazelrc:all_files", + "//bazeldnf:all_files", + "//bazeldnf/private:all_files", + "//internal:all_files", + "//tools:all_files", + "//tools/e2e:toolchain", + ], + visibility = [ + "//e2e:__subpackages__", + ], +) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 00000000..23f5bc6a --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,490 @@ +# Contributing to bazeldnf + +Thank you for your interest in contributing to bazeldnf! This guide covers the +development workflow for making changes to Go code, Starlark rules, dependency +management, and end-to-end tests. + +## Prerequisites + +- [Bazelisk](https://github.com/bazelbuild/bazelisk) (symlinked as `bazel`) +- Git + +## Project Layout + +``` +bazeldnf/ +├── cmd/ # CLI binary (cobra commands) +├── pkg/ # Go library packages +│ ├── api/ # Core API types +│ ├── bazel/ # BUILD file manipulation +│ ├── ldd/ # Shared library dependency analysis +│ ├── order/ # Package ordering +│ ├── reducer/ # SAT solver wrapper +│ ├── repo/ # DNF/RPM repo fetching and parsing +│ ├── rpm/ # RPM file handling +│ ├── sat/ # SAT solver integration +│ └── xattr/ # Extended attributes +├── bazeldnf/ # Public Starlark API (.bzl files) +│ └── private/ # Private Starlark helpers +├── internal/ # Starlark rule implementations +├── tools/ # Release tooling, version info, integrity checksums +├── e2e/ # End-to-end integration test workspaces +├── MODULE.bazel # Bazel module definition (bzlmod) +├── go.mod / go.sum # Go module dependencies +└── BUILD.bazel # Root build targets (gazelle, buildifier, etc.) +``` + +## Building and Testing + +```sh +# Build everything +bazel build //... + +# Run all unit tests +bazel test //... + +# Run all end-to-end tests that should pass +bazel test e2e + +# Run end-to-end tests that are allowed to fail +bazel test //e2e/... --test_tag_filters=allowed-to-fail +``` + +## Making Changes to Go Code + +The Go source lives in `cmd/` (CLI binary) and `pkg/` (library packages). + +### Workflow + +1. **Make your code changes** in the relevant `cmd/` or `pkg/` package. + +2. **Format your code**: + ```sh + bazel run @rules_go//go -- fmt ./... + ``` + +3. **Regenerate BUILD files** with Gazelle. Bazel BUILD files for Go packages + are managed by Gazelle, so any new files, packages, or import changes + require updating them: + ```sh + bazel run //:gazelle + ``` + +4. **Run unit tests** to verify your changes: + ```sh + bazel test //... + ``` + +### Adding a New Go Package + +If you add a new package under `pkg/` or `cmd/`: + +1. Create the directory and add your `.go` files. +2. Run Gazelle to auto-generate the `BUILD.bazel` file: + ```sh + bazel run //:gazelle + ``` + Gazelle will create the `go_library`, `go_test`, and/or `go_binary` targets + automatically based on your source files. + +### Unit Tests + +Go tests use [gomega](https://onsi.github.io/gomega/) for assertions. Place +test files (`*_test.go`) alongside the code they test. Gazelle will +automatically include them in the generated `go_test` targets. + +## Adding New Go Dependencies + +Go dependencies are managed with standard Go modules and synced to Bazel via +Gazelle and bzlmod. + +1. **Add the dependency**: + ```sh + bazel run @rules_go//go -- get github.com/example/newdep@latest + ``` + This updates `go.mod` and `go.sum`. + +2. **Sync bzlmod `use_repo` declarations**: + ```sh + bazel mod tidy + ``` + This automatically updates the `use_repo` calls in `MODULE.bazel`. + +3. **Regenerate BUILD files**: + ```sh + bazel run //:gazelle + ``` + +4. **Verify the build**: + ```sh + bazel build //... + bazel test //... + ``` + +## Adding New Bazel Dependencies + +Bazel module dependencies are managed in `MODULE.bazel` using bzlmod. + +1. **Add the `bazel_dep`** to `MODULE.bazel`: + ```python + # Use dev_dependency = True if only needed for development/testing + bazel_dep(name = "rules_foo", version = "1.2.3", dev_dependency = True) + ``` + +2. **Sync `use_repo` declarations**: + ```sh + bazel mod tidy + ``` + +3. **Run Gazelle** if the new dependency provides Starlark libraries that + Gazelle should be aware of: + ```sh + bazel run //:gazelle + ``` + +4. **Verify everything builds**: + ```sh + bazel build //... + ``` + +### Dependency Categories + +In `MODULE.bazel`, dependencies are organized as: + +- **Runtime dependencies** (not `dev_dependency`): required by users of + bazeldnf (e.g., `bazel_skylib`, `platforms`, `bazel_features`, `bazel_lib`). + Be conservative adding non-dev dependencies as they affect all consumers. +- **Toolchain build dependencies**: `gazelle` and `rules_go`, needed when + building the toolchain from source. +- **Dev dependencies** (`dev_dependency = True`): only used within this repo + for building, testing, and linting (e.g., `buildifier_prebuilt`, + `rules_bazel_integration_test`). + +## Making Starlark Changes + +Starlark (`.bzl`) files define the Bazel rules, macros, and extensions that +users interact with. + +### File Organization + +| Directory | Purpose | +|---|---| +| `bazeldnf/defs.bzl` | Public API facade (re-exports all user-facing rules) | +| `bazeldnf/extensions.bzl` | Bzlmod module extensions (`bazeldnf_toolchain`, `bazeldnf`) | +| `bazeldnf/toolchain.bzl` | Toolchain rule definition | +| `bazeldnf/repositories.bzl` | WORKSPACE-mode setup functions | +| `bazeldnf/private/` | Private implementation details (lock file helpers, repo rules) | +| `internal/` | Rule implementations (`rpm.bzl`, `rpmtree.bzl`, `bazeldnf.bzl`, `xattrs.bzl`) | + +### Workflow + +1. **Make your `.bzl` changes**. + +2. **Format with buildifier**: + ```sh + bazel run //:buildifier + ``` + +3. **Run Gazelle** to update any `bzl_library` targets if you added or renamed + `.bzl` files: + ```sh + bazel run //:gazelle + ``` + +4. **Run unit tests and e2e tests** to verify nothing is broken: + ```sh + bazel test //... + bazel test e2e + ``` + +### Tips + +- When modifying user-facing rules in `internal/`, update the re-exports in + `bazeldnf/defs.bzl` if adding new symbols. +- If you change the module extension in `bazeldnf/extensions.bzl`, test with + both the lock-file and non-lock-file e2e workspaces. +- The `internal/runner.bash.template` is used to generate runner scripts for + the `bazeldnf` runnable rule. + +## End-to-End Tests + +E2E tests use +[rules_bazel_integration_test](https://github.com/bazel-contrib/rules_bazel_integration_test) +to spin up isolated Bazel workspaces and verify that bazeldnf works correctly +across different Bazel versions and configurations. + +### Existing E2E Test Suites + +| Suite | Directory | Description | +|---|---|---| +| `e2e:bzlmod` | `e2e/bazel-bzlmod/` | Basic bzlmod with prebuilt toolchain | +| `e2e:bzlmod-lock-file` | `e2e/bazel-bzlmod-lock-file/` | Bzlmod with lock file workflow | +| `e2e:bzlmod-toolchain-from-source` | `e2e/bazel-bzlmod-toolchain-from-source/` | Toolchain built from Go source | +| `e2e:lock-file-from-args` | `e2e/bazel-bzlmod-lock-file-from-args/` | Lock file generated from CLI args | +| `e2e:circular-deps` | `e2e/bzlmod-toolchain-circular-dependencies/` | Circular RPM dependency handling | +| `e2e:repo-yaml` | `e2e/repo-yaml/` | CLI `init`/`fetch`/`resolve` workflow | + +### Running E2E Tests + +```sh +# Run all e2e tests +bazel test e2e + +# Run a specific suite +bazel test e2e:bzlmod +bazel test e2e:bzlmod-lock-file +``` + +### Adding a New E2E Test + +#### 1. Create the Workspace Directory + +Create a new directory under `e2e/` with the files for your test workspace: + +``` +e2e/my-new-test/ +├── MODULE.bazel # Module definition, references parent +├── BUILD.bazel # Build targets that exercise your scenario +└── .bazelrc # Required, see below +``` + +#### 2. Update `.bazelignore` and Deleted Packages + +Since e2e workspaces are nested Bazel projects, you must prevent the parent +workspace from traversing into their Bazel output directories, and update the +`--deleted_packages` flags so the parent doesn't treat child `BUILD` files as +its own packages. + +1. **Add `bazel-*` output symlinks to `.bazelignore`**. Append entries for your + new workspace (follow the pattern of existing entries): + ``` + e2e/my-new-test/bazel-bin + e2e/my-new-test/bazel-out + e2e/my-new-test/bazel-my-new-test + e2e/my-new-test/bazel-testlogs + ``` + +2. **Regenerate `--deleted_packages` flags**: + ```sh + bazel run @rules_bazel_integration_test//tools:update_deleted_packages + ``` + This updates the `.bazelrc` files with the correct `--deleted_packages` + entries so the parent workspace ignores `BUILD` files inside child + workspaces. + +#### 3. Create `.bazelrc` + +Every e2e workspace needs a `.bazelrc` that imports shared configs from the +parent repository: + +``` +# Import Aspect bazelrc presets +import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc + +# Include our e2e shared config +import %workspace%/../.bazelrc + +# Specific project flags go here if needed + +# Load any settings & overrides specific to the current user from `.bazelrc.user`. +# This file should appear in `.gitignore` so that settings are not shared with team members. This +# should be last statement in this config so the user configuration is able to overwrite flags from +# this file. See https://bazel.build/configure/best-practices#bazelrc-file. +try-import %workspace%/../../.bazelrc.user +``` + +#### 4. Set Up MODULE.bazel + +Your test workspace must reference the parent repository using +`local_path_override` so that it uses the local (in-development) version of +bazeldnf: + +```python +module(name = "my-new-test") + +bazel_dep(name = "bazeldnf") +local_path_override( + module_name = "bazeldnf", + path = "../..", +) + +# Use bazeldnf extensions as needed +bazeldnf = use_extension("@bazeldnf//bazeldnf:extensions.bzl", "bazeldnf") +# ... configure RPMs, lock files, etc. +``` + +#### 5. Create BUILD Targets + +In your test workspace's `BUILD.bazel`, use the bazeldnf rules to set up the +scenario you want to test: + +```python +load("@bazeldnf//bazeldnf:defs.bzl", "bazeldnf", "rpmtree", "tar2files") + +bazeldnf(name = "bazeldnf") + +rpmtree( + name = "my_rpms", + rpms = ["@some-rpm//rpm"], +) +``` + +#### 6. Register the Test in `e2e/BUILD.bazel` + +Add the integration test definition to `e2e/BUILD.bazel`. Use the existing +`:test-runner` which runs `bazel --nohome_rc build //...` inside the workspace: + +```python +bazel_integration_tests( + name = "e2e_my_new_test", + timeout = DEFAULT_TIMEOUT, + bazel_binaries = bazel_binaries, + bazel_versions = BZLMOD_BAZEL_VERSIONS, + tags = DEFAULT_TEST_TAGS, + test_runner = ":test-runner", + workspace_files = glob_workspace_files("my-new-test") + [ + ".bazelrc", + "//:local_repository_files", + ], + workspace_path = "my-new-test", +) +``` + +If you're developing a new feature which isn't fully ready yet, but it doesn't +add regressions, then you can add `['allowed-to-fail']` to your tags, this will +allow your new feature to be merged incrementally and making the reviewing +process easier. + +If your test needs to run commands beyond `build //...` (e.g., running +`fetch` or `resolve` before building), define a custom test runner: + +```python +default_test_runner( + name = "my-test-runner", + bazel_cmds = [ + "run :bazeldnf -- fetch --cache-dir $(pwd)/.bazeldnf", + "build //...", + ], +) +``` + +#### 7. Add a Test Suite + +Add a test suite so the test can be run by name: + +```python +test_suite( + name = "my-new-test", + tags = DEFAULT_TEST_SUITE_TAGS, + tests = integration_test_utils.bazel_integration_test_names( + "e2e_my_new_test", + BZLMOD_BAZEL_VERSIONS, + ), +) +``` + +In the case you needed to add `allowed-to-fail` to the test tags also add it here. + +And include it in the top-level `e2e` test suite: + +```python +test_suite( + name = "e2e", + tags = DEFAULT_TEST_SUITE_TAGS, + tests = [ + # ... existing suites ... + ":my-new-test", + ], +) +``` + +#### 8. Expose Parent Files + +If your test workspace depends on parent files not already included in +`//:local_repository_files` (defined in the root `BUILD.bazel`), add them to +that filegroup. Each package that needs to be visible must have: + +```python +filegroup( + name = "all_files", + srcs = glob(["**"]), + visibility = ["//:__pkg__"], +) +``` + +#### 9. Verify Everything + +Run your new test to make sure it passes: + +```sh +bazel test e2e:my-new-test +``` + +In the case your tests are allowed to fail then you do + +```sh +bazel test e2e:my-new-test --test_tag_filters=allowed-to-fail +``` + +### Key Concepts for E2E Tests + +- **`local_path_override`**: each child workspace references the parent repo at + `../..`, so it always tests the local development version of bazeldnf. +- **`//:local_repository_files`**: a filegroup in the root `BUILD.bazel` that + aggregates all parent workspace files needed by e2e workspaces. The + integration test framework copies these into the test sandbox. +- **`glob_workspace_files`**: a helper in `e2e/helpers.bzl` that globs all + files in a workspace directory, excluding Bazel output directories + (`bazel-*`) and `MODULE.bazel.lock` files. +- **`--nohome_rc`**: all test runners automatically prepend this flag to + prevent the host's `~/.bazelrc` from interfering with tests. +- **Bazel versions**: bzlmod tests run against `BZLMOD_BAZEL_VERSIONS` (7.6.0, + 8.1.0). + +## Formatting and Linting + +All formatting checks run in CI. Make sure they pass before submitting: + +```sh +# Check Starlark/BUILD formatting (CI runs this) +bazel run //:buildifier.check + +# Check BUILD files are up-to-date (CI runs this) +bazel run //:gazelle.check + +# Auto-fix Starlark formatting +bazel run //:buildifier + +# Regenerate BUILD files +bazel run //:gazelle + +# Format Go code +bazel run @rules_go//go -- fmt ./... +``` + +## CI + +GitHub Actions runs on every push and PR to `main`: + +1. **Linter** (`linter.yaml`): checks buildifier and gazelle formatting. +2. **Main CI** (`action.yml`): builds everything, runs unit tests, then runs + all e2e test suites. +3. **Allowed-to-fail** (`allowed-to-fail.yml`): runs e2e tests tagged as + `allowed-to-fail` (currently the circular dependency tests) and posts a PR + comment if they fail, without blocking the PR. + +## Quick Reference + +| Task | Command | +|---|---| +| Build everything | `bazel build //...` | +| Run unit tests | `bazel test //...` | +| Run all e2e tests | `bazel test e2e` | +| Run specific e2e suite | `bazel test e2e:` | +| Format Go code | `bazel run @rules_go//go -- fmt ./...` | +| Add Go dependency | `bazel run @rules_go//go -- get github.com/...@latest` | +| Sync module repos | `bazel mod tidy` | +| Format Starlark/BUILD | `bazel run //:buildifier` | +| Regenerate BUILD files | `bazel run //:gazelle` | +| Check Starlark formatting | `bazel run //:buildifier.check` | +| Check BUILD files | `bazel run //:gazelle.check` | diff --git a/MODULE.bazel b/MODULE.bazel index 668ced83..f575ad6c 100644 --- a/MODULE.bazel +++ b/MODULE.bazel @@ -88,11 +88,31 @@ use_repo( "bazeldnf_internal_libvirt-libs", ) -bazel_dep(name = "protobuf", version = "33.5", dev_dependency = True) - # deps only needed for the repo internals +bazel_dep(name = "protobuf", version = "33.5", dev_dependency = True) bazel_dep(name = "bazel_skylib_gazelle_plugin", version = "1.9.0", dev_dependency = True) bazel_dep(name = "aspect_bazel_lib", version = "2.22.5", dev_dependency = True) bazel_dep(name = "buildifier_prebuilt", version = "8.2.1.2", dev_dependency = True) bazel_dep(name = "rules_pkg", version = "1.2.0", dev_dependency = True) bazel_dep(name = "rules_cc", version = "0.2.16", dev_dependency = True) + +# e2e / integration testing +bazel_dep(name = "rules_shell", version = "0.6.1", dev_dependency = True) +bazel_dep(name = "rules_bazel_integration_test", version = "0.37.1", dev_dependency = True) + +bazel_binaries = use_extension( + "@rules_bazel_integration_test//:extensions.bzl", + "bazel_binaries", + dev_dependency = True, +) +bazel_binaries.download(version = "6.5.0") +bazel_binaries.download(version = "7.6.0") +bazel_binaries.download(version = "8.1.0") +use_repo( + bazel_binaries, + "bazel_binaries", + "bazel_binaries_bazelisk", + "build_bazel_bazel_6_5_0", + "build_bazel_bazel_7_6_0", + "build_bazel_bazel_8_1_0", +) diff --git a/Makefile b/Makefile index 5904670d..df20d4a1 100644 --- a/Makefile +++ b/Makefile @@ -16,66 +16,25 @@ gofmt: gofmt -w pkg/.. cmd/.. e2e-workspace: - @for version in 6.x 7.x; do \ - ( \ - cd e2e/bazel-workspace && \ - echo "Testing $$version in workspace mode" > /dev/stderr && \ - USE_BAZEL_VERSION=$$version bazelisk --batch build //...\ - ) \ - done + bazel test e2e:workspace e2e-bzlmod: - @for version in 7.x 8.x; do \ - ( \ - cd e2e/bazel-bzlmod && \ - echo "Testing $$version with bzlmod" > /dev/stderr && \ - USE_BAZEL_VERSION=$$version bazelisk --batch build //...\ - ) \ - done + bazel test e2e:bzlmod e2e-bazel-bzlmod-lock-file: - @for version in 7.x 8.x; do \ - ( \ - cd e2e/bazel-bzlmod-lock-file && \ - echo "Testing $$version with bzlmod with lock file" > /dev/stderr && \ - USE_BAZEL_VERSION=$$version bazelisk --batch build //...\ - ) \ - done + bazel test e2e:bzlmod-lock-file e2e-bzlmod-build-toolchain: - @for version in 7.x 8.x; do \ - ( \ - cd e2e/bazel-bzlmod-toolchain-from-source && \ - echo "Testing $$version with bzlmod build toolchain" > /dev/stderr && \ - USE_BAZEL_VERSION=$$version bazelisk --batch build //... --incompatible_enable_proto_toolchain_resolution \ - ) \ - done + bazel test e2e:bzlmod-toolchain-from-source e2e-bazel-bzlmod-lock-file-from-args: - @for version in 7.x 8.x; do \ - ( \ - cd e2e/bazel-bzlmod-lock-file-from-args && \ - echo "Testing $$version bzlmod lock file from args" > /dev/stderr && \ - USE_BAZEL_VERSION=$$version bazelisk --batch build //... --incompatible_enable_proto_toolchain_resolution \ - ) \ - done + bazel test e2e:lock-file-from-args e2e-bzlmod-toolchain-circular-dependencies: - @for version in 7.x 8.x; do \ - ( \ - cd e2e/bzlmod-toolchain-circular-dependencies && \ - echo "Testing $$version bzlmod lock file from args" > /dev/stderr && \ - USE_BAZEL_VERSION=$$version bazelisk --batch build //... --incompatible_enable_proto_toolchain_resolution \ - ) \ - done + bazel test e2e:circular-deps - -e2e: e2e-workspace \ - e2e-bzlmod \ - e2e-bzlmod-build-toolchain \ - e2e-bazel-bzlmod-lock-file \ - e2e-bazel-bzlmod-lock-file-from-args \ - e2e-bzlmod-toolchain-circular-dependencies +e2e: + bazel test e2e fmt: gofmt buildifier diff --git a/REPO.bazel b/REPO.bazel new file mode 100644 index 00000000..5a2968d0 --- /dev/null +++ b/REPO.bazel @@ -0,0 +1,6 @@ +"list of directories the top level bazel shouldn't dive into" + +ignore_directories([ + ".git", + "e2e/*/bazel-*", +]) diff --git a/bazeldnf/BUILD.bazel b/bazeldnf/BUILD.bazel index 9095fd50..cdc0950f 100644 --- a/bazeldnf/BUILD.bazel +++ b/bazeldnf/BUILD.bazel @@ -1,6 +1,12 @@ load("@bazel_lib//:bzl_library.bzl", "bzl_library") load("//bazeldnf/private:resolved_bazeldnf_toolchain.bzl", "resolved_bazeldnf_toolchain") +filegroup( + name = "all_files", + srcs = glob(["**"]), + visibility = ["//:__pkg__"], +) + # this directory contains the public API from bazeldnf, anything on this directory # should be buildable withtout dev dependencies # diff --git a/bazeldnf/alias_macros.bzl b/bazeldnf/alias_macros.bzl index 03f955fc..34de1f5a 100644 --- a/bazeldnf/alias_macros.bzl +++ b/bazeldnf/alias_macros.bzl @@ -26,10 +26,7 @@ def default(name, rpms, visibility = ["//visibility:public"]): visibility = visibility, ) - if len(rpms) > 1: - fail("Package resolved multiple times, not implemented.") - - if len(rpms) == 1: + if len(rpms): rpm = rpms[0] alias( name = name, diff --git a/bazeldnf/extensions.bzl b/bazeldnf/extensions.bzl index 152fc98d..dd6128a2 100644 --- a/bazeldnf/extensions.bzl +++ b/bazeldnf/extensions.bzl @@ -156,17 +156,72 @@ _alias_repository = repository_rule( }, ) -def _to_rpm_repo_name(prefix, rpm_name): - name = rpm_name.replace("+", "plus") - return "{}{}".format(prefix, name) - def _get_architectures(architecture, architectures): """ Create effective list of architectures based on user input """ if architecture and architectures: fail("Can't combine `architecture` and `architectures`") return architectures or [(architecture or "x86_64")] -def _handle_lock_file(config, module_ctx, registered_rpms = {}): +def _build_rpm_lookup(rpms_list): + """Build a dictionary for efficient RPM lookup by name/id. + + Returns a dict mapping RPM name/id to RPM data. + """ + rpm_lookup = {} + for rpm in rpms_list: + # Determine the RPM identifier + rpm_id = rpm.get("id", rpm.get("name", None)) + if not rpm_id: + # Fallback to URL-based name + urls = rpm.get("urls", []) + if len(urls) > 0: + rpm_id = urls[0].rsplit("/", 1)[-1] + if rpm_id: + rpm_lookup[rpm_id] = rpm + return rpm_lookup + +def _build_transitive_deps(rpm_lookup, target_name): + """Build transitive dependency closure for a target. + + Returns a dict mapping RPM name to RPM data for all transitive dependencies. + Uses iterative passes to avoid recursion (not supported in Starlark). + """ + visited = {} + to_process = {target_name: True} + + # Iterate up to max depth to resolve all transitive dependencies + # This is a safety limit to prevent infinite loops in case of circular deps + for _ in range(1000): + if len(to_process) == 0: + break + + # Process all current items + current_batch = list(to_process.keys()) + to_process = {} + + for current in current_batch: + # Skip if already processed + if current in visited: + continue + + # Find the RPM in the lookup dict + rpm = rpm_lookup.get(current) + if not rpm: + continue + + # Make a copy to avoid mutating the original + rpm_copy = dict(rpm) + visited[current] = rpm_copy + + # Add dependencies to next batch + deps = rpm_copy.get("dependencies", []) + for dep in deps: + if dep not in visited: + to_process[dep] = True + + return visited + +def _handle_lock_file(config, module_ctx, registered_rpms = {}, registered_blobs = {}): if not config.lock_file: fail("No lock file provided for %s" % config.name) @@ -189,17 +244,46 @@ def _handle_lock_file(config, module_ctx, registered_rpms = {}): # Data for generating alias repository # Keyed with a Bazel package name in the root of the alias repository (usually just a RPM package name), # Values are a list of resolved RPMs in a form of a dict, containing: - # - package – just an RPM package name (optional – lock file may be missing it) - # - id – some unique identifier for the config - # - repo_name – apparent repo name where the .rpm file is downloaded to + # - package - just an RPM package name (optional - lock file may be missing it) + # - id - some unique identifier for the config + # - repo_name - apparent repo name where the .rpm file is downloaded to packages_metadata = {} if module_ctx.path(config.lock_file).exists: content = module_ctx.read(config.lock_file) lock_file_json = json.decode(content) + # Build lookup dictionary for efficient RPM access + rpm_lookup = _build_rpm_lookup(lock_file_json.get("rpms", [])) + + # Create a blob repository for each available rpm in the lock file for rpm in lock_file_json.get("rpms", []): - repo_info = _add_rpm_repository(config, rpm, lock_file_json, registered_rpms) + _add_blob_rpm_repository(config, rpm, lock_file_json, registered_blobs) + + # Create repositories for each top-level target with suffixed dependencies + for target in config.rpms: + if target not in rpm_lookup: + fail("requested rpm %s is not known to the lock file %s" % (target, config.lock_file)) + + # Build transitive dependency closure for this target + target_deps = _build_transitive_deps(rpm_lookup, target) + repo_info = _add_rpm_repository(config, rpm_lookup[target], registered_rpms, dependencies = target_deps) + + packages_metadata.setdefault(repo_info.get("package", repo_info["id"]), []).append(repo_info) + + if not config.rpms: + # if the user didn't ask for a list of RPMs then make all of the RPMs available with no dependencies + for rpm in rpm_lookup.values(): + blob_name, _, _ = _normalize_repository_name(rpm, config.rpm_repository_prefix, config.lock_file) + repo_info = _add_rpm_repository(config, rpm, registered_rpms, [blob_name]) + packages_metadata.setdefault(repo_info.get("package", repo_info["id"]), []).append(repo_info) + + for rpm in rpm_lookup.values(): + # for RPMs with no id or name then we will make then available with only a dependency to it's blob + if rpm.get("id", None) or rpm.get("name"): + continue + blob_name, _, _ = _normalize_repository_name(rpm, config.rpm_repository_prefix, config.lock_file) + repo_info = _add_rpm_repository(config, rpm, registered_rpms, [blob_name]) packages_metadata.setdefault(repo_info.get("package", repo_info["id"]), []).append(repo_info) # if there's targets without matching RPMs we need to create a null target @@ -219,54 +303,101 @@ def _handle_lock_file(config, module_ctx, registered_rpms = {}): return config.name -def _add_rpm_repository(config, rpm, lock_file_json, registered_rpms): - dependencies = rpm.pop("dependencies", []) - if config.ignore_deps: - dependencies = [] - else: - dependencies = [x.replace("+", "plus") for x in dependencies] - dependencies = ["@{}{}//rpm".format(config.rpm_repository_prefix, x) for x in dependencies] - +def _normalize_repository_name(rpm, rpm_repository_prefix, lock_file): # Older lockfiles may not have `id` field. # Name was the equivalent. We need to pop both. - package = rpm.pop("name", None) - id = rpm.pop("id", package) + package = rpm.get("name", None) + id = rpm.get("id", package) if not id: urls = rpm.get("urls", []) if len(urls) < 1: - fail("invalid entry in %s: %s" % (config.lock_file, rpm)) + fail("invalid entry in %s: %s" % (lock_file, rpm)) id = urls[0].rsplit("/", 1)[-1] - name = _to_rpm_repo_name(config.rpm_repository_prefix, id) - if name in registered_rpms: - return registered_rpms[name] + name = id.replace("+", "plus") + if rpm_repository_prefix: + name = "{}{}".format(rpm_repository_prefix, name) + + return name, id, package + +def _get_blob_prefix(rpm_repository_prefix): + if not rpm_repository_prefix: + return "blob-" + return "blob-{}-".format(rpm_repository_prefix) + +def _add_blob_rpm_repository(config, rpm, lock_file_json, registered_blobs): + name, _, _ = _normalize_repository_name(rpm, _get_blob_prefix(config.rpm_repository_prefix), config.lock_file) + + # prevent the same blob to be registered more than once, needed for multiple lock files + if name in registered_blobs: + return + + registered_blobs[name] = 1 + + repository = rpm.get("repository") - repository = rpm.pop("repository") mirrors = lock_file_json.get("repositories", {}).get(repository, None) + if mirrors == None: fail("couldn't resolve %s in %s" % (repository, lock_file_json["repositories"])) - href = rpm.pop("urls")[0] + + href = rpm.get("urls")[0] urls = ["%s/%s" % (x, href) for x in mirrors] + rpm_repository( name = name, - dependencies = dependencies, urls = urls, - **rpm + create_blob = True, + blob_mode = True, + ) + + return + +def _add_rpm_repository(config, rpm, registered_rpms, dependencies = []): + # fix for cases like c++ + dependencies = [x.replace("+", "plus") for x in dependencies] + + # point to the actual blob + dependencies = ["@{}{}//blob".format(_get_blob_prefix(config.rpm_repository_prefix), x) for x in dependencies] + + repo_prefix = config.rpm_repository_prefix + if repo_prefix: + repo_prefix = "{}-".format(repo_prefix) + + name, id, package = _normalize_repository_name(rpm, repo_prefix, config.lock_file) + + # the same rpm may be in the transitive closure of an already explored rpm, but it may be + # a requested target, in which case we need to override the previously defined case + if name in registered_rpms: + return registered_rpms[name] + + rpm_repository( + name = name, + dependencies = dependencies, + create_blob = False, + blob_mode = True, ) metadata = { "repo_name": name, "id": id, } + if package: metadata["package"] = package + registered_rpms[name] = metadata + return metadata def _bazeldnf_extension(module_ctx): # make sure all our dependencies are registered as those may be needed when those - # dependening in this repo build the toolchain from sources + # depending in this repo build the toolchain from sources repos = [] + + # blobs are unique for the entire bazel workspace + registered_blobs = dict() + for mod in module_ctx.modules: registered_rpms = dict() for config in mod.tags.config: @@ -275,6 +406,7 @@ def _bazeldnf_extension(module_ctx): config, module_ctx, registered_rpms, + registered_blobs, ), ) @@ -409,7 +541,7 @@ The lock file content is as: "architectures": attr.string_list( doc = """Custom list of architectures (can't be used with `architecture`). - Can use more than one. The list defines architectures priority – + Can use more than one. The list defines architectures priority - with the first one having the highest priority. `noarch` is implicitly added at the end (if not present on the list).""", ), diff --git a/bazeldnf/private/BUILD.bazel b/bazeldnf/private/BUILD.bazel index c7026ace..d6011e9b 100644 --- a/bazeldnf/private/BUILD.bazel +++ b/bazeldnf/private/BUILD.bazel @@ -1,5 +1,11 @@ load("@bazel_lib//:bzl_library.bzl", "bzl_library") +filegroup( + name = "all_files", + srcs = glob(["**"]), + visibility = ["//:__pkg__"], +) + bzl_library( name = "toolchains_repo", srcs = ["toolchains_repo.bzl"], diff --git a/e2e/.bazelrc b/e2e/.bazelrc new file mode 100644 index 00000000..f17acd97 --- /dev/null +++ b/e2e/.bazelrc @@ -0,0 +1,12 @@ +# if running in GitHub actions with setup-bazel then we need to ignore output_base +# our workflow creates this clean bazelrc file for us +try-import ~/.bazelrc.clean + +# make sure all our tests use the prebuilt toolchain +common --extra_toolchains=@bazeldnf//tools/e2e/output:toolchain + +# Include most of the suggested flags from aspect +import %workspace%/../../.aspect/bazelrc/convenience.bazelrc +import %workspace%/../../.aspect/bazelrc/correctness.bazelrc +import %workspace%/../../.aspect/bazelrc/debug.bazelrc +import %workspace%/../../.aspect/bazelrc/performance.bazelrc diff --git a/e2e/BUILD.bazel b/e2e/BUILD.bazel new file mode 100644 index 00000000..f2c94904 --- /dev/null +++ b/e2e/BUILD.bazel @@ -0,0 +1,278 @@ +load("@bazel_binaries//:defs.bzl", "bazel_binaries") +load( + "@rules_bazel_integration_test//bazel_integration_test:defs.bzl", + "bazel_integration_tests", + "integration_test_utils", +) +load("helpers.bzl", "default_test_runner", "glob_workspace_files") + +WORKSPACE_BAZEL_VERSIONS = [ + "6.5.0", + "7.6.0", +] + +BZLMOD_BAZEL_VERSIONS = [ + "7.6.0", + "8.1.0", +] + +DEFAULT_TIMEOUT = "moderate" + +default_test_runner( + name = "test-runner", + bazel_cmds = ["build //..."], +) + +DEFAULT_TEST_TAGS = [ + "manual", + "requires-network", +] + +# bazel-workspace: legacy WORKSPACE mode (Bazel 6.x, 7.x) +bazel_integration_tests( + name = "e2e_workspace", + timeout = DEFAULT_TIMEOUT, + bazel_binaries = bazel_binaries, + bazel_versions = WORKSPACE_BAZEL_VERSIONS, + tags = DEFAULT_TEST_TAGS, + test_runner = ":test-runner", + workspace_files = glob_workspace_files( + "bazel-workspace", + extra_excludes = ["*/*.json"], + ) + [ + ".bazelrc", + "//:local_repository_files", + ], + workspace_path = "bazel-workspace", +) + +# bazel-bzlmod: basic bzlmod with prebuilt toolchain +bazel_integration_tests( + name = "e2e_bzlmod", + timeout = DEFAULT_TIMEOUT, + bazel_binaries = bazel_binaries, + bazel_versions = BZLMOD_BAZEL_VERSIONS, + tags = DEFAULT_TEST_TAGS, + test_runner = ":test-runner", + workspace_files = glob_workspace_files( + "bazel-bzlmod", + extra_excludes = ["*/*.json"], + ) + [ + ".bazelrc", + "//:local_repository_files", + ], + workspace_path = "bazel-bzlmod", +) + +# bazel-bzlmod-lock-file: bzlmod with lock files +bazel_integration_tests( + name = "e2e_bzlmod_lock_file", + timeout = DEFAULT_TIMEOUT, + bazel_binaries = bazel_binaries, + bazel_versions = BZLMOD_BAZEL_VERSIONS, + tags = DEFAULT_TEST_TAGS, + test_runner = ":test-runner", + workspace_files = glob_workspace_files("bazel-bzlmod-lock-file") + [ + ".bazelrc", + "//:local_repository_files", + ], + workspace_path = "bazel-bzlmod-lock-file", +) + +# bazel-bzlmod-toolchain-from-source: toolchain built from source +bazel_integration_tests( + name = "e2e_bzlmod_toolchain_from_source", + timeout = DEFAULT_TIMEOUT, + bazel_binaries = bazel_binaries, + bazel_versions = BZLMOD_BAZEL_VERSIONS, + tags = DEFAULT_TEST_TAGS, + test_runner = ":test-runner", + workspace_files = glob_workspace_files( + "bazel-bzlmod-toolchain-from-source", + extra_excludes = ["*/*.json"], + ) + [ + ".bazelrc", + "//:local_repository_files", + ], + workspace_path = "bazel-bzlmod-toolchain-from-source", +) + +# bazel-bzlmod-toolchain-from-source-lock-file: toolchain from source with lock file +bazel_integration_tests( + name = "e2e_bzlmod_toolchain_from_source_lock_file", + timeout = DEFAULT_TIMEOUT, + bazel_binaries = bazel_binaries, + bazel_versions = BZLMOD_BAZEL_VERSIONS, + tags = DEFAULT_TEST_TAGS, + test_runner = ":test-runner", + workspace_files = glob_workspace_files( + "bazel-bzlmod-toolchain-from-source-lock-file", + extra_excludes = ["*/*.json"], + ) + [ + ".bazelrc", + "//:local_repository_files", + ], + workspace_path = "bazel-bzlmod-toolchain-from-source-lock-file", +) + +default_test_runner( + name = "lock-file-from-args-runner", + bazel_cmds = [ + "run :bazeldnf -- fetch --cache-dir $(pwd)/.bazeldnf", + "run @bazeldnf_rpms//:update-lock-file -- --cache-dir $(pwd)/.bazeldnf", + "build //...", + ], +) + +bazel_integration_tests( + name = "e2e_lock_file_from_args", + timeout = DEFAULT_TIMEOUT, + bazel_binaries = bazel_binaries, + bazel_versions = BZLMOD_BAZEL_VERSIONS, + tags = DEFAULT_TEST_TAGS, + test_runner = ":lock-file-from-args-runner", + workspace_files = glob_workspace_files( + "bazel-bzlmod-lock-file-from-args", + extra_excludes = ["*/*.json"], + ) + [ + ".bazelrc", + "//:local_repository_files", + ], + workspace_path = "bazel-bzlmod-lock-file-from-args", +) + +default_test_runner( + name = "test-runner-circular-deps", + bazel_cmds = [ + "run @bazeldnf_rpms//:fetch-repo -- --cache-dir $(pwd)/.bazeldnf", + "run @bazeldnf_rpms//:update-lock-file -- --cache-dir $(pwd)/.bazeldnf", + "run @bazeldnf_bash//:fetch-repo -- --cache-dir $(pwd)/.bazeldnf", + "run @bazeldnf_bash//:update-lock-file -- --cache-dir $(pwd)/.bazeldnf", + "build //...", + ], +) + +bazel_integration_tests( + name = "e2e_circular_deps", + timeout = DEFAULT_TIMEOUT, + bazel_binaries = bazel_binaries, + bazel_versions = BZLMOD_BAZEL_VERSIONS, + tags = DEFAULT_TEST_TAGS + [ + "allowed-to-fail", # TODO: drop once the circular dependencies passes + ], + test_runner = ":test-runner-circular-deps", + workspace_files = glob_workspace_files( + "bzlmod-toolchain-circular-dependencies", + extra_excludes = ["*/*.json"], + ) + [ + ".bazelrc", + "//:local_repository_files", + ], + workspace_path = "bzlmod-toolchain-circular-dependencies", +) + +default_test_runner( + name = "test-runner-repo-yaml", + bazel_cmds = [ + "run :bazeldnf -- init --fc 44 --output $(pwd)/repo.yaml", + "run :bazeldnf -- fetch --repofile $(pwd)/repo.yaml --cache-dir $(pwd)/.bazeldnf", + "run :bazeldnf -- resolve --repofile $(pwd)/repo.yaml --cache-dir $(pwd)/.bazeldnf bash", + ], +) + +bazel_integration_tests( + name = "e2e_repo_yaml", + timeout = DEFAULT_TIMEOUT, + bazel_binaries = bazel_binaries, + bazel_versions = BZLMOD_BAZEL_VERSIONS, + tags = DEFAULT_TEST_TAGS, + test_runner = ":test-runner-repo-yaml", + workspace_files = glob_workspace_files("repo-yaml") + [ + ".bazelrc", + "//:local_repository_files", + ], + workspace_path = "repo-yaml", +) + +DEFAULT_TEST_SUITE_TAGS = ["manual"] + +test_suite( + name = "workspace", + tags = DEFAULT_TEST_SUITE_TAGS, + tests = integration_test_utils.bazel_integration_test_names( + "e2e_workspace", + WORKSPACE_BAZEL_VERSIONS, + ), +) + +test_suite( + name = "bzlmod", + tags = DEFAULT_TEST_SUITE_TAGS, + tests = integration_test_utils.bazel_integration_test_names( + "e2e_bzlmod", + BZLMOD_BAZEL_VERSIONS, + ), +) + +test_suite( + name = "bzlmod-lock-file", + tags = DEFAULT_TEST_SUITE_TAGS, + tests = integration_test_utils.bazel_integration_test_names( + "e2e_bzlmod_lock_file", + BZLMOD_BAZEL_VERSIONS, + ), +) + +test_suite( + name = "bzlmod-toolchain-from-source", + tags = DEFAULT_TEST_SUITE_TAGS, + tests = integration_test_utils.bazel_integration_test_names( + "e2e_bzlmod_toolchain_from_source", + BZLMOD_BAZEL_VERSIONS, + ), +) + +test_suite( + name = "circular-deps", + tags = DEFAULT_TEST_SUITE_TAGS + [ + "allowed-to-fail", # TODO: drop once the circular dependencies passes + ], + tests = integration_test_utils.bazel_integration_test_names( + "e2e_circular_deps", + BZLMOD_BAZEL_VERSIONS, + ), +) + +test_suite( + name = "lock-file-from-args", + tags = DEFAULT_TEST_SUITE_TAGS, + tests = integration_test_utils.bazel_integration_test_names( + "e2e_lock_file_from_args", + BZLMOD_BAZEL_VERSIONS, + ), +) + +test_suite( + name = "repo-yaml", + tags = DEFAULT_TEST_SUITE_TAGS, + tests = integration_test_utils.bazel_integration_test_names( + "e2e_repo_yaml", + BZLMOD_BAZEL_VERSIONS, + ), +) + +test_suite( + name = "e2e", + tags = DEFAULT_TEST_SUITE_TAGS, + tests = [ + ":bzlmod", + ":bzlmod-lock-file", + ":bzlmod-toolchain-from-source", + ":circular-deps", + ":lock-file-from-args", + ":repo-yaml", + ":workspace", + ], +) + +# gazelle:exclude helpers.bzl diff --git a/e2e/bazel-bzlmod-lock-file-from-args/.bazelrc b/e2e/bazel-bzlmod-lock-file-from-args/.bazelrc index 6b6c94e8..f9d74810 100644 --- a/e2e/bazel-bzlmod-lock-file-from-args/.bazelrc +++ b/e2e/bazel-bzlmod-lock-file-from-args/.bazelrc @@ -1,16 +1,11 @@ # Import Aspect bazelrc presets -try-import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc -import %workspace%/../../.aspect/bazelrc/convenience.bazelrc -import %workspace%/../../.aspect/bazelrc/correctness.bazelrc -import %workspace%/../../.aspect/bazelrc/debug.bazelrc -import %workspace%/../../.aspect/bazelrc/performance.bazelrc +import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc + +# Include our e2e shared config +try-import %workspace%/../.bazelrc # Specific project flags go here if we have some common --enable_bzlmod -common --extra_toolchains=@bazeldnf//cmd:bazeldnf-host-toolchain - -# prebuilt protoc -common --incompatible_enable_proto_toolchain_resolution # Load any settings & overrides specific to the current user from `.bazelrc.user`. # This file should appear in `.gitignore` so that settings are not shared with team members. This diff --git a/e2e/bazel-bzlmod-lock-file-from-args/MODULE.bazel b/e2e/bazel-bzlmod-lock-file-from-args/MODULE.bazel index e5b1f6ba..2c4e7cee 100644 --- a/e2e/bazel-bzlmod-lock-file-from-args/MODULE.bazel +++ b/e2e/bazel-bzlmod-lock-file-from-args/MODULE.bazel @@ -9,32 +9,6 @@ local_path_override( ) bazel_dep(name = "rules_pkg", version = "1.1.0") -bazel_dep(name = "rules_go", version = "0.59.0", repo_name = "rules_go") - -go_sdk = use_extension("@rules_go//go:extensions.bzl", "go_sdk") -go_sdk.download(version = "1.24.1") - -bazel_dep(name = "gazelle", version = "0.47.0") - -go_deps = use_extension("@gazelle//:extensions.bzl", "go_deps") -go_deps.from_file(go_mod = "@bazeldnf//:go.mod") -use_repo( - go_deps, - "com_github_adrg_xdg", - "com_github_bazelbuild_buildtools", - "com_github_crillab_gophersat", - "com_github_hashicorp_go_retryablehttp", - "com_github_jdx_go_netrc", - "com_github_klauspost_compress", - "com_github_onsi_gomega", - "com_github_sassoftware_go_rpmutils", - "com_github_sirupsen_logrus", - "com_github_spf13_cobra", - "com_github_ulikunitz_xz", - "io_k8s_sigs_yaml", - "org_golang_x_crypto", - "org_golang_x_exp", -) bazeldnf_toolchain = use_extension("@bazeldnf//bazeldnf:extensions.bzl", "bazeldnf_toolchain") bazeldnf_toolchain.register(disable = True) @@ -64,13 +38,3 @@ use_repo( bazeldnf, "bazeldnf_rpms", ) - -bazel_dep(name = "toolchains_protoc", version = "0.6.0", dev_dependency = True) - -protoc = use_extension("@toolchains_protoc//protoc:extensions.bzl", "protoc", dev_dependency = True) -use_repo(protoc, "toolchains_protoc_hub") - -register_toolchains( - "@toolchains_protoc_hub//:all", - dev_dependency = True, -) diff --git a/e2e/bazel-bzlmod-lock-file-from-args/repo.yaml b/e2e/bazel-bzlmod-lock-file-from-args/repo.yaml index 5948bff3..b5e68978 100644 --- a/e2e/bazel-bzlmod-lock-file-from-args/repo.yaml +++ b/e2e/bazel-bzlmod-lock-file-from-args/repo.yaml @@ -1,9 +1,9 @@ repositories: - arch: x86_64 - metalink: https://mirrors.fedoraproject.org/metalink?repo=fedora-40&arch=x86_64 - name: 40-x86_64-primary-repo + metalink: https://mirrors.fedoraproject.org/metalink?repo=fedora-44&arch=x86_64 + name: 44-x86_64-primary-repo - arch: x86_64 metalink: https://mirrors.fedoraproject.org/metalink?repo=updates-released-f40&arch=x86_64 name: 40-x86_64-update-repo exclude: - - ^libzstd \ No newline at end of file + - ^libzstd diff --git a/e2e/bazel-bzlmod-lock-file/.bazelrc b/e2e/bazel-bzlmod-lock-file/.bazelrc index 0b8b0486..154119a1 100644 --- a/e2e/bazel-bzlmod-lock-file/.bazelrc +++ b/e2e/bazel-bzlmod-lock-file/.bazelrc @@ -1,12 +1,10 @@ # Import Aspect bazelrc presets -try-import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc -import %workspace%/../../.aspect/bazelrc/convenience.bazelrc -import %workspace%/../../.aspect/bazelrc/correctness.bazelrc -import %workspace%/../../.aspect/bazelrc/debug.bazelrc -import %workspace%/../../.aspect/bazelrc/performance.bazelrc +import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc + +# Include our e2e shared config +try-import %workspace%/../.bazelrc common --enable_bzlmod -common --extra_toolchains=@bazeldnf//cmd:bazeldnf-host-toolchain # Specific project flags go here if we have some diff --git a/e2e/bazel-bzlmod-lock-file/MODULE.bazel b/e2e/bazel-bzlmod-lock-file/MODULE.bazel index 8774e88a..06888502 100644 --- a/e2e/bazel-bzlmod-lock-file/MODULE.bazel +++ b/e2e/bazel-bzlmod-lock-file/MODULE.bazel @@ -9,46 +9,9 @@ local_path_override( ) bazel_dep(name = "rules_pkg", version = "1.1.0") -bazel_dep(name = "rules_go", version = "0.59.0", repo_name = "rules_go") -go_sdk = use_extension("@rules_go//go:extensions.bzl", "go_sdk") -go_sdk.download(version = "1.24.1") - -bazel_dep(name = "gazelle", version = "0.47.0") - -go_deps = use_extension("@gazelle//:extensions.bzl", "go_deps") -go_deps.from_file(go_mod = "@bazeldnf//:go.mod") -use_repo( - go_deps, - "com_github_adrg_xdg", - "com_github_bazelbuild_buildtools", - "com_github_crillab_gophersat", - "com_github_hashicorp_go_retryablehttp", - "com_github_jdx_go_netrc", - "com_github_klauspost_compress", - "com_github_onsi_gomega", - "com_github_sassoftware_go_rpmutils", - "com_github_sirupsen_logrus", - "com_github_spf13_cobra", - "com_github_ulikunitz_xz", - "io_k8s_sigs_yaml", - "org_golang_x_crypto", - "org_golang_x_exp", -) - -bazel_dep(name = "toolchains_protoc", version = "0.6.0") - -protoc = use_extension("@toolchains_protoc//protoc:extensions.bzl", "protoc") -protoc.toolchain( - google_protobuf = "com_google_protobuf", - version = "v27.3", -) -use_repo(protoc, "com_google_protobuf", "toolchains_protoc_hub") - -register_toolchains( - "@toolchains_protoc_hub//:all", - dev_dependency = True, -) +bazeldnf_toolchain = use_extension("@bazeldnf//bazeldnf:extensions.bzl", "bazeldnf_toolchain") +bazeldnf_toolchain.register(disable = True) bazeldnf = use_extension("@bazeldnf//bazeldnf:extensions.bzl", "bazeldnf") bazeldnf.config( @@ -64,7 +27,7 @@ bazeldnf.config( nobest = True, repofile = "//:repo.yaml", rpms = [ - "libvirt-devel", + "libvirt-libs", ], ) bazeldnf.config( diff --git a/e2e/bazel-bzlmod-toolchain-from-source-lock-file/.bazelrc b/e2e/bazel-bzlmod-toolchain-from-source-lock-file/.bazelrc index b54eb05e..f9d74810 100644 --- a/e2e/bazel-bzlmod-toolchain-from-source-lock-file/.bazelrc +++ b/e2e/bazel-bzlmod-toolchain-from-source-lock-file/.bazelrc @@ -1,17 +1,11 @@ # Import Aspect bazelrc presets -try-import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc -import %workspace%/../../.aspect/bazelrc/bazel6.bazelrc -import %workspace%/../../.aspect/bazelrc/convenience.bazelrc -import %workspace%/../../.aspect/bazelrc/correctness.bazelrc -import %workspace%/../../.aspect/bazelrc/debug.bazelrc -import %workspace%/../../.aspect/bazelrc/performance.bazelrc +import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc + +# Include our e2e shared config +try-import %workspace%/../.bazelrc # Specific project flags go here if we have some common --enable_bzlmod -common --extra_toolchains=@bazeldnf//cmd:bazeldnf-host-toolchain - -# prebuilt protoc -common --incompatible_enable_proto_toolchain_resolution # Load any settings & overrides specific to the current user from `.bazelrc.user`. # This file should appear in `.gitignore` so that settings are not shared with team members. This diff --git a/e2e/bazel-bzlmod-toolchain-from-source-lock-file/MODULE.bazel b/e2e/bazel-bzlmod-toolchain-from-source-lock-file/MODULE.bazel index a474b152..feb786db 100644 --- a/e2e/bazel-bzlmod-toolchain-from-source-lock-file/MODULE.bazel +++ b/e2e/bazel-bzlmod-toolchain-from-source-lock-file/MODULE.bazel @@ -9,7 +9,6 @@ local_path_override( ) bazel_dep(name = "rules_pkg", version = "1.1.0") -bazel_dep(name = "toolchains_protoc", version = "0.6.0") bazeldnf = use_extension("@bazeldnf//bazeldnf:extensions.bzl", "bazeldnf") bazeldnf.toolchain(disable = True) diff --git a/e2e/bazel-bzlmod-toolchain-from-source/.bazelrc b/e2e/bazel-bzlmod-toolchain-from-source/.bazelrc index 449a334f..f9d74810 100644 --- a/e2e/bazel-bzlmod-toolchain-from-source/.bazelrc +++ b/e2e/bazel-bzlmod-toolchain-from-source/.bazelrc @@ -1,14 +1,11 @@ # Import Aspect bazelrc presets -try-import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc -import %workspace%/../../.aspect/bazelrc/convenience.bazelrc -import %workspace%/../../.aspect/bazelrc/correctness.bazelrc -import %workspace%/../../.aspect/bazelrc/debug.bazelrc -import %workspace%/../../.aspect/bazelrc/performance.bazelrc +import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc + +# Include our e2e shared config +try-import %workspace%/../.bazelrc # Specific project flags go here if we have some common --enable_bzlmod -common --extra_toolchains=@bazeldnf//cmd:bazeldnf-host-toolchain -common --incompatible_enable_proto_toolchain_resolution # Load any settings & overrides specific to the current user from `.bazelrc.user`. # This file should appear in `.gitignore` so that settings are not shared with team members. This diff --git a/e2e/bazel-bzlmod-toolchain-from-source/MODULE.bazel b/e2e/bazel-bzlmod-toolchain-from-source/MODULE.bazel index f2d58a37..79a366f7 100644 --- a/e2e/bazel-bzlmod-toolchain-from-source/MODULE.bazel +++ b/e2e/bazel-bzlmod-toolchain-from-source/MODULE.bazel @@ -9,45 +9,6 @@ local_path_override( ) bazel_dep(name = "rules_pkg", version = "1.1.0") -bazel_dep(name = "rules_go", version = "0.59.0", repo_name = "rules_go") - -go_sdk = use_extension("@rules_go//go:extensions.bzl", "go_sdk") -go_sdk.download(version = "1.24.1") - -bazel_dep(name = "gazelle", version = "0.47.0") -bazel_dep(name = "toolchains_protoc", version = "0.6.0") - -protoc = use_extension("@toolchains_protoc//protoc:extensions.bzl", "protoc") -protoc.toolchain( - google_protobuf = "com_google_protobuf", - version = "v27.3", -) -use_repo(protoc, "com_google_protobuf", "toolchains_protoc_hub") - -register_toolchains( - "@toolchains_protoc_hub//:all", - dev_dependency = True, -) - -go_deps = use_extension("@gazelle//:extensions.bzl", "go_deps") -go_deps.from_file(go_mod = "@bazeldnf//:go.mod") -use_repo( - go_deps, - "com_github_adrg_xdg", - "com_github_bazelbuild_buildtools", - "com_github_crillab_gophersat", - "com_github_hashicorp_go_retryablehttp", - "com_github_jdx_go_netrc", - "com_github_klauspost_compress", - "com_github_onsi_gomega", - "com_github_sassoftware_go_rpmutils", - "com_github_sirupsen_logrus", - "com_github_spf13_cobra", - "com_github_ulikunitz_xz", - "io_k8s_sigs_yaml", - "org_golang_x_crypto", - "org_golang_x_exp", -) bazeldnf_toolchain = use_extension("@bazeldnf//bazeldnf:extensions.bzl", "bazeldnf_toolchain") bazeldnf_toolchain.register(disable = True) diff --git a/e2e/bazel-bzlmod/.bazelrc b/e2e/bazel-bzlmod/.bazelrc index 6d22ade3..154119a1 100644 --- a/e2e/bazel-bzlmod/.bazelrc +++ b/e2e/bazel-bzlmod/.bazelrc @@ -1,9 +1,8 @@ # Import Aspect bazelrc presets -try-import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc -import %workspace%/../../.aspect/bazelrc/convenience.bazelrc -import %workspace%/../../.aspect/bazelrc/correctness.bazelrc -import %workspace%/../../.aspect/bazelrc/debug.bazelrc -import %workspace%/../../.aspect/bazelrc/performance.bazelrc +import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc + +# Include our e2e shared config +try-import %workspace%/../.bazelrc common --enable_bzlmod diff --git a/e2e/bazel-bzlmod/MODULE.bazel b/e2e/bazel-bzlmod/MODULE.bazel index 7fa1d898..ab2e8fae 100644 --- a/e2e/bazel-bzlmod/MODULE.bazel +++ b/e2e/bazel-bzlmod/MODULE.bazel @@ -8,6 +8,9 @@ local_path_override( path = "../..", ) +bazeldnf_toolchain = use_extension("@bazeldnf//bazeldnf:extensions.bzl", "bazeldnf_toolchain") +bazeldnf_toolchain.register(disable = True) + bazel_dep(name = "rules_pkg", version = "1.1.0") bazeldnf = use_extension("@bazeldnf//bazeldnf:extensions.bzl", "bazeldnf") diff --git a/e2e/bazel-workspace/.bazelrc b/e2e/bazel-workspace/.bazelrc index 33dee036..a85f3c8a 100644 --- a/e2e/bazel-workspace/.bazelrc +++ b/e2e/bazel-workspace/.bazelrc @@ -1,8 +1,5 @@ -# Import Aspect bazelrc presets -import %workspace%/../../.aspect/bazelrc/convenience.bazelrc -import %workspace%/../../.aspect/bazelrc/correctness.bazelrc -import %workspace%/../../.aspect/bazelrc/debug.bazelrc -import %workspace%/../../.aspect/bazelrc/performance.bazelrc +# Include our e2e shared config +try-import %workspace%/../.bazelrc # Specific project flags go here if we have some diff --git a/e2e/bazel-workspace/WORKSPACE b/e2e/bazel-workspace/WORKSPACE index 2a61e67f..cafc994f 100644 --- a/e2e/bazel-workspace/WORKSPACE +++ b/e2e/bazel-workspace/WORKSPACE @@ -22,15 +22,10 @@ load("@bazeldnf//bazeldnf:defs.bzl", "rpm") load( "@bazeldnf//bazeldnf:repositories.bzl", "bazeldnf_dependencies", - "bazeldnf_register_toolchains", ) bazeldnf_dependencies() -bazeldnf_register_toolchains( - name = "bazeldnf_prebuilt", -) - rpm( name = "libvirt-devel-11.0.0-1.fc42.x86_64.rpm", sha256 = "dba37bbe57903afe49b5666f1781eb50001baa81af4584b355db0b6a2afad9fa", diff --git a/e2e/bzlmod-toolchain-circular-dependencies/.bazelrc b/e2e/bzlmod-toolchain-circular-dependencies/.bazelrc index 6b6c94e8..f9d74810 100644 --- a/e2e/bzlmod-toolchain-circular-dependencies/.bazelrc +++ b/e2e/bzlmod-toolchain-circular-dependencies/.bazelrc @@ -1,16 +1,11 @@ # Import Aspect bazelrc presets -try-import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc -import %workspace%/../../.aspect/bazelrc/convenience.bazelrc -import %workspace%/../../.aspect/bazelrc/correctness.bazelrc -import %workspace%/../../.aspect/bazelrc/debug.bazelrc -import %workspace%/../../.aspect/bazelrc/performance.bazelrc +import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc + +# Include our e2e shared config +try-import %workspace%/../.bazelrc # Specific project flags go here if we have some common --enable_bzlmod -common --extra_toolchains=@bazeldnf//cmd:bazeldnf-host-toolchain - -# prebuilt protoc -common --incompatible_enable_proto_toolchain_resolution # Load any settings & overrides specific to the current user from `.bazelrc.user`. # This file should appear in `.gitignore` so that settings are not shared with team members. This diff --git a/e2e/bzlmod-toolchain-circular-dependencies/.bazelversion b/e2e/bzlmod-toolchain-circular-dependencies/.bazelversion new file mode 120000 index 00000000..96cf9496 --- /dev/null +++ b/e2e/bzlmod-toolchain-circular-dependencies/.bazelversion @@ -0,0 +1 @@ +../../.bazelversion \ No newline at end of file diff --git a/e2e/bzlmod-toolchain-circular-dependencies/BUILD.bazel b/e2e/bzlmod-toolchain-circular-dependencies/BUILD.bazel index 173f53d4..24dddf50 100644 --- a/e2e/bzlmod-toolchain-circular-dependencies/BUILD.bazel +++ b/e2e/bzlmod-toolchain-circular-dependencies/BUILD.bazel @@ -8,7 +8,9 @@ bazeldnf( rpmtree( name = "something", rpms = [ - "@bazeldnf_rpms//bash", + "@bazeldnf_rpms//git", + "@bazeldnf_rpms//glibc", + "@bazeldnf_bash//bash", ], ) diff --git a/e2e/bzlmod-toolchain-circular-dependencies/MODULE.bazel b/e2e/bzlmod-toolchain-circular-dependencies/MODULE.bazel index 66d0a26a..8ce47038 100644 --- a/e2e/bzlmod-toolchain-circular-dependencies/MODULE.bazel +++ b/e2e/bzlmod-toolchain-circular-dependencies/MODULE.bazel @@ -9,45 +9,6 @@ local_path_override( ) bazel_dep(name = "rules_pkg", version = "1.1.0") -bazel_dep(name = "rules_go", version = "0.59.0", repo_name = "rules_go") - -go_sdk = use_extension("@rules_go//go:extensions.bzl", "go_sdk") -go_sdk.download(version = "1.24.1") - -bazel_dep(name = "gazelle", version = "0.47.0") -bazel_dep(name = "toolchains_protoc", version = "0.6.0") - -protoc = use_extension("@toolchains_protoc//protoc:extensions.bzl", "protoc") -protoc.toolchain( - google_protobuf = "com_google_protobuf", - version = "v27.3", -) -use_repo(protoc, "com_google_protobuf", "toolchains_protoc_hub") - -register_toolchains( - "@toolchains_protoc_hub//:all", - dev_dependency = True, -) - -go_deps = use_extension("@gazelle//:extensions.bzl", "go_deps") -go_deps.from_file(go_mod = "@bazeldnf//:go.mod") -use_repo( - go_deps, - "com_github_adrg_xdg", - "com_github_bazelbuild_buildtools", - "com_github_crillab_gophersat", - "com_github_hashicorp_go_retryablehttp", - "com_github_jdx_go_netrc", - "com_github_klauspost_compress", - "com_github_onsi_gomega", - "com_github_sassoftware_go_rpmutils", - "com_github_sirupsen_logrus", - "com_github_spf13_cobra", - "com_github_ulikunitz_xz", - "io_k8s_sigs_yaml", - "org_golang_x_crypto", - "org_golang_x_exp", -) bazeldnf_toolchain = use_extension("@bazeldnf//bazeldnf:extensions.bzl", "bazeldnf_toolchain") bazeldnf_toolchain.register(disable = True) @@ -63,12 +24,30 @@ bazeldnf.config( ignore_deps = False, lock_file = "//:bazeldnf-lock.json", repofile = "//:repos.yaml", + rpm_repository_prefix = "x86-64", rpms = [ + "bash", "git", "glibc", ], ) +bazeldnf.config( + name = "bazeldnf_bash", + cache_dir = "./.bazeldnf-test-issues-with-ignore-flag", + excludes = [ + "alternatives", + "basesystem", + ], + ignore_deps = False, + lock_file = "//:bazeldnf-lock-bash.json", + repofile = "//:repos.yaml", + rpm_repository_prefix = "x86-64", + rpms = [ + "bash", + ], +) use_repo( bazeldnf, + "bazeldnf_bash", "bazeldnf_rpms", ) diff --git a/e2e/bzlmod-toolchain-circular-dependencies/bazeldnf-lock.json b/e2e/bzlmod-toolchain-circular-dependencies/bazeldnf-lock.json index f2136b41..ac1e06ce 100644 --- a/e2e/bzlmod-toolchain-circular-dependencies/bazeldnf-lock.json +++ b/e2e/bzlmod-toolchain-circular-dependencies/bazeldnf-lock.json @@ -8,10 +8,13 @@ "alternatives", "--force-ignore-with-dependencies", "basesystem", + "bash", "git", "glibc", "--cache-dir", "./.bazeldnf-test-issues-with-ignore-flag", + "--arch", + "x86_64", "--ignore-missing" ], "name": "", @@ -25,10 +28,11 @@ }, "rpms": [ { + "id": "audit-libs", "name": "audit-libs", - "integrity": "sha256-0UgvZehOdh8CguniwqcRHwY43IidbzTkzeFg5GWFXR4=", + "integrity": "sha256-+XDOf8BYnAp7N3hMb8YCo1p3HbgR+AYbi4ry9Om0Y0k=", "urls": [ - "Packages/audit-libs-3.1.5-4.el9.x86_64.rpm" + "Packages/audit-libs-3.1.5-8.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -37,6 +41,7 @@ ] }, { + "id": "bash", "name": "bash", "integrity": "sha256-gjhZqej62DAE+g2faY/yI/b304/Y52KVCdmLW6Z2TAM=", "urls": [ @@ -50,6 +55,7 @@ ] }, { + "id": "bzip2-libs", "name": "bzip2-libs", "integrity": "sha256-hDkoFcwajwHGUe3Rf1cKpEnvbzl65I13PWVWBup7TJY=", "urls": [ @@ -61,34 +67,39 @@ ] }, { + "id": "ca-certificates", "name": "ca-certificates", - "integrity": "sha256-0Ywbl2PCLck9qAT5atPZKzFXGVye/26SPDPpAR3z4kY=", + "integrity": "sha256-SJ/fJYNEiSQS/y8Q0MHIScRdWhXEYoq9oz8yWkLdG7A=", "urls": [ - "Packages/ca-certificates-2024.2.69_v8.0.303-91.4.el9.noarch.rpm" + "Packages/ca-certificates-2025.2.80_v9.0.305-91.el9.noarch.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ "bash", "coreutils", + "findutils", "grep", + "libffi", "p11-kit-trust", "sed" ] }, { + "id": "centos-gpg-keys", "name": "centos-gpg-keys", - "integrity": "sha256-jWAdn5Y1aiAK1u2OXLSbusSqPEt2LRCiPhExHapXEco=", + "integrity": "sha256-TseGosvc0LaLEgRn/ozsaNDeomI5zG37KFJYKYxDpJg=", "urls": [ - "Packages/centos-gpg-keys-9.0-26.el9.noarch.rpm" + "Packages/centos-gpg-keys-9.0-34.el9.noarch.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [] }, { + "id": "centos-stream-release", "name": "centos-stream-release", - "integrity": "sha256-PWDcjthnF/aDlPx0aLgCRVfEOsKtl7jkCRHQVs1tZNM=", + "integrity": "sha256-gIpOokLb1PT69iMR+0i6dMr9s/yMP1Pf2XrKDhCZZQ8=", "urls": [ - "Packages/centos-stream-release-9.0-26.el9.noarch.rpm" + "Packages/centos-stream-release-9.0-34.el9.noarch.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -96,10 +107,11 @@ ] }, { + "id": "centos-stream-repos", "name": "centos-stream-repos", - "integrity": "sha256-6ztVpc8OGpOpHNLTkDW9F1S0b2n/PQYrMzHnZbI0UDU=", + "integrity": "sha256-7bwwU7BMWCbCA2mkT1h9VZmjFQas9suucNvWEI9V0EY=", "urls": [ - "Packages/centos-stream-repos-9.0-26.el9.noarch.rpm" + "Packages/centos-stream-repos-9.0-34.el9.noarch.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -107,6 +119,7 @@ ] }, { + "id": "coreutils", "name": "coreutils", "integrity": "sha256-Kv4+jvK4LnWtWnNZlNOod72hOsDsfvkvDsUgW3RR6Vw=", "urls": [ @@ -125,6 +138,7 @@ ] }, { + "id": "coreutils-common", "name": "coreutils-common", "integrity": "sha256-fgoq4mAcv+iBHmw8K8EN4wOkE4pIsEB7wh+SmHa1T7I=", "urls": [ @@ -134,10 +148,11 @@ "dependencies": [] }, { + "id": "cracklib", "name": "cracklib", - "integrity": "sha256-vp3rLv0GtLLBwTCsrpTGhxYdBIMBGeZamJ2QS6n9GGQ=", + "integrity": "sha256-qmWfxfwfQNkwGFBBHh5M+5NRF14YeaHUBCksvZCZgvA=", "urls": [ - "Packages/cracklib-2.9.6-27.el9.x86_64.rpm" + "Packages/cracklib-2.9.6-28.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -148,10 +163,11 @@ ] }, { + "id": "cracklib-dicts", "name": "cracklib-dicts", - "integrity": "sha256-Ad8qcvzfmIEy6CdkzhoipalRP6JTtU4X0jBYvbU8LYU=", + "integrity": "sha256-sONywJ5usB0t4TFrflnHkXjA6u5tcTAE1/5fvH5xhgM=", "urls": [ - "Packages/cracklib-dicts-2.9.6-27.el9.x86_64.rpm" + "Packages/cracklib-dicts-2.9.6-28.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -159,10 +175,11 @@ ] }, { + "id": "crypto-policies", "name": "crypto-policies", - "integrity": "sha256-+BHSyEj2+ToYjy101MzRcuHciPp5GejiA88d89k1ceE=", + "integrity": "sha256-OMHkC0d3lQF5ltsGg7cgBKSBDYijIK4FVOZzaxGMXJo=", "urls": [ - "Packages/crypto-policies-20250128-1.git5269e22.el9.noarch.rpm" + "Packages/crypto-policies-20251126-1.gite9c4db2.el9.noarch.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -170,19 +187,21 @@ ] }, { + "id": "emacs-filesystem", "name": "emacs-filesystem", - "integrity": "sha256-jJsTruBTK9i8zl8o+4GH0IXA2qPTBm485ts5OpDimdk=", + "integrity": "sha256-rTYxAUW3uHgUbwrx5HjMxDPxK6J8d0a1BlEwLrG6WoI=", "urls": [ - "Packages/emacs-filesystem-27.2-13.el9.noarch.rpm" + "Packages/emacs-filesystem-27.2-18.el9.noarch.rpm" ], "repository": "centos-stream-9-stable-appstream", "dependencies": [] }, { + "id": "expat", "name": "expat", - "integrity": "sha256-Ng7ZlOoq9bOn83aU398iSdl+Xl7CSSySI6Kuxy/49IA=", + "integrity": "sha256-Oc/8Wjp1zNBtQhT5nj06id15vuNTIXWuONN8FKrVKfw=", "urls": [ - "Packages/expat-2.5.0-4.el9.x86_64.rpm" + "Packages/expat-2.5.0-6.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -190,6 +209,7 @@ ] }, { + "id": "filesystem", "name": "filesystem", "integrity": "sha256-2ndQ/DEkjsxgYBY5HD9XDhq+dCL4ErKaSdgwxxiE5tw=", "urls": [ @@ -202,6 +222,33 @@ ] }, { + "id": "findutils", + "name": "findutils", + "integrity": "sha256-OT/GUd3bgmUh1SjXiBlRXAm5PlUXAcr7YrZywsRwHQQ=", + "urls": [ + "Packages/findutils-4.8.0-7.el9.x86_64.rpm" + ], + "repository": "centos-stream-9-stable-baseos", + "dependencies": [ + "glibc", + "libselinux" + ] + }, + { + "id": "fips-provider-next", + "name": "fips-provider-next", + "integrity": "sha256-H3jB1/iPJJSZTYc1Z2wq/VKWBsj1nCp7gw6ZODG2ziw=", + "urls": [ + "Packages/fips-provider-next-1.2.0-7.el9.x86_64.rpm" + ], + "repository": "centos-stream-9-stable-appstream", + "dependencies": [ + "glibc", + "libgcc" + ] + }, + { + "id": "gawk", "name": "gawk", "integrity": "sha256-bm13t2seif5vASzcFhEb6jXrTO7axQQOXYG1oGZCmvg=", "urls": [ @@ -218,10 +265,11 @@ ] }, { + "id": "git", "name": "git", - "integrity": "sha256-lzvPC/R1aPCxhx+u0KxKFeqvnuNU2jWw3f6MwI9AAEw=", + "integrity": "sha256-jHFET7z2q+3tRurmNex0wLyfKAF/IxbBKUD4LenKs4A=", "urls": [ - "Packages/git-2.47.1-1.el9.x86_64.rpm" + "Packages/git-2.47.3-1.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-appstream", "dependencies": [ @@ -242,10 +290,11 @@ ] }, { + "id": "git-core", "name": "git-core", - "integrity": "sha256-njnx3e9H2Ej5dZVwHQtGV/Pu+vpsrllT1QPRMso486E=", + "integrity": "sha256-xJAP/93i3lIK+QX06F1bxrtgYYGBgc/COeYFkf6zyNI=", "urls": [ - "Packages/git-core-2.47.1-1.el9.x86_64.rpm" + "Packages/git-core-2.47.3-1.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-appstream", "dependencies": [ @@ -261,10 +310,11 @@ ] }, { + "id": "git-core-doc", "name": "git-core-doc", - "integrity": "sha256-q5Fm9z8QLO7zGH9SqpQN7uSd1osVQw2+SImw3e3yQx4=", + "integrity": "sha256-ktoBM4w56DwgoezS4NNkgoJlNHlGRvbzWaWh3rWvu4c=", "urls": [ - "Packages/git-core-doc-2.47.1-1.el9.noarch.rpm" + "Packages/git-core-doc-2.47.3-1.el9.noarch.rpm" ], "repository": "centos-stream-9-stable-appstream", "dependencies": [ @@ -272,10 +322,11 @@ ] }, { + "id": "glibc", "name": "glibc", - "integrity": "sha256-4GISscrB2f2YV6AN3v7+n7n0BhmcuE/dEVNYnBXhYok=", + "integrity": "sha256-tKjJOijVmkBw7no/f1F9DOTpwRiGR35tG1cHcYiSgX4=", "urls": [ - "Packages/glibc-2.34-168.el9.x86_64.rpm" + "Packages/glibc-2.34-245.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -285,10 +336,11 @@ ] }, { + "id": "glibc-all-langpacks", "name": "glibc-all-langpacks", - "integrity": "sha256-oXFKt0wJcJSq2YCKSOIcV/OHb6PeXyR7EBl9fIot6Lg=", + "integrity": "sha256-sci91EYsoicdsf0QwqaZCdWfzhaO8DojJXXmnBqRkk0=", "urls": [ - "Packages/glibc-all-langpacks-2.34-168.el9.x86_64.rpm" + "Packages/glibc-all-langpacks-2.34-245.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -297,10 +349,11 @@ ] }, { + "id": "glibc-common", "name": "glibc-common", - "integrity": "sha256-UxZQdEkJ79AoS/bBakXbr0VbIUwMrEGXz21D6MfYOvg=", + "integrity": "sha256-dH6j282+mzuMJqxw6o4RennmL1DfC4dUpkXC72jgW+I=", "urls": [ - "Packages/glibc-common-2.34-168.el9.x86_64.rpm" + "Packages/glibc-common-2.34-245.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -310,6 +363,7 @@ ] }, { + "id": "gmp", "name": "gmp", "integrity": "sha256-ttWSiVzMD8rWEGzUGADNnWjlOExBjlOiw/8qyMixWjM=", "urls": [ @@ -321,6 +375,7 @@ ] }, { + "id": "grep", "name": "grep", "integrity": "sha256-EKQbZrH71usFUXjiLDcZnltJtIUud8gG969yEQRKSlU=", "urls": [ @@ -335,6 +390,7 @@ ] }, { + "id": "groff-base", "name": "groff-base", "integrity": "sha256-+PAnJXZr7w/fPbEk14YoSOaSUYzgSRn7Glg/ATu7q/s=", "urls": [ @@ -349,6 +405,7 @@ ] }, { + "id": "gzip", "name": "gzip", "integrity": "sha256-6Nd4PGZqWKuHAkawTrDqIpZRI/4oRpfSwOHm2/EOqGE=", "urls": [ @@ -362,6 +419,7 @@ ] }, { + "id": "keyutils-libs", "name": "keyutils-libs", "integrity": "sha256-rvmCUBaUSGonQRxoaYiG127HDFzRC/5hlQHn5MNvUKk=", "urls": [ @@ -373,10 +431,11 @@ ] }, { + "id": "krb5-libs", "name": "krb5-libs", - "integrity": "sha256-UO30CJ0EgASK66K/1za5Oqidwlc1zQLoC61X5WLh4AE=", + "integrity": "sha256-1dNHNjfTRTwyFrHxT+9QDhC9gVjJm7rbSLeIuI2SeG8=", "urls": [ - "Packages/krb5-libs-1.21.1-6.el9.x86_64.rpm" + "Packages/krb5-libs-1.21.1-8.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -395,10 +454,11 @@ ] }, { + "id": "less", "name": "less", - "integrity": "sha256-RuEd+st1qNAwR9gvRK5GsR2V2jHg7Bs6jMN6EyscfK4=", + "integrity": "sha256-xtRNlNSHRstqkJxakp9pyG24Ou9ZY1y6v8WkoXajiKA=", "urls": [ - "Packages/less-590-5.el9.x86_64.rpm" + "Packages/less-590-6.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -408,6 +468,7 @@ ] }, { + "id": "libacl", "name": "libacl", "integrity": "sha256-YKOv+qHDh/1vct1lqnrWGaGDCUeCOrtLKee5/LTJ0nw=", "urls": [ @@ -420,6 +481,7 @@ ] }, { + "id": "libattr", "name": "libattr", "integrity": "sha256-1NsJWgFehAZfJ6ZC7ngpzRaQBBuoxRUB+QjMNHYMlAk=", "urls": [ @@ -431,6 +493,7 @@ ] }, { + "id": "libblkid", "name": "libblkid", "integrity": "sha256-JDP4gp+JTHxboGOes3oYqSYy1Pk4NVHJAUNLQ1P5b8Q=", "urls": [ @@ -445,10 +508,11 @@ ] }, { + "id": "libcap", "name": "libcap", - "integrity": "sha256-fQfsimoJddhMZq3yHIhcQaVXHstjEFWVkmXGD9oxQRE=", + "integrity": "sha256-vaXZgSSawWYDIopPVEoVoUDh7tEFqxIG2mvvlwXN3uc=", "urls": [ - "Packages/libcap-2.48-9.el9.x86_64.rpm" + "Packages/libcap-2.48-10.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -457,6 +521,7 @@ ] }, { + "id": "libcap-ng", "name": "libcap-ng", "integrity": "sha256-YkKbeIrPtA28namVFpDBHpB+Iwh5x5DROfc9DoXddvQ=", "urls": [ @@ -468,6 +533,7 @@ ] }, { + "id": "libcbor", "name": "libcbor", "integrity": "sha256-7Lth35PmgWJ2cS0CowE8WRqLWKjvUOzpjYFFZFZZgKs=", "urls": [ @@ -479,10 +545,11 @@ ] }, { + "id": "libcom_err", "name": "libcom_err", - "integrity": "sha256-0R4Y2/3dVlOMR2hR2YvZZ5XzQEXhTr57MoXyJcS0sYk=", + "integrity": "sha256-70N5TznUm2nhJQZyLkMqSX5/lgOOJsqyw0R2qtSz1BM=", "urls": [ - "Packages/libcom_err-1.46.5-7.el9.x86_64.rpm" + "Packages/libcom_err-1.46.5-8.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -490,10 +557,11 @@ ] }, { + "id": "libcurl-minimal", "name": "libcurl-minimal", - "integrity": "sha256-ZDhIXjhGXulE4lq+3PShdhVk/lIC8FoCxx5MiAJVtTk=", + "integrity": "sha256-FaNy2x4BlA4jXrEQngDEnjgqraxGdCXcNhYQ3h5X7xs=", "urls": [ - "Packages/libcurl-minimal-7.76.1-31.el9.x86_64.rpm" + "Packages/libcurl-minimal-7.76.1-38.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -506,10 +574,11 @@ ] }, { + "id": "libdb", "name": "libdb", - "integrity": "sha256-4oYI216qPuOOi8DWvhgxBI2h5jiSCm8WqAhOcuLr9sk=", + "integrity": "sha256-F/f9jBVDaCbaWsnQQo7Lg/7sGMAbbFBXq5uFq5cxTJY=", "urls": [ - "Packages/libdb-5.3.28-55.el9.x86_64.rpm" + "Packages/libdb-5.3.28-57.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -517,10 +586,11 @@ ] }, { + "id": "libeconf", "name": "libeconf", - "integrity": "sha256-7VGcwukDHivwMnWyjHzKZSCukW0Kftu8afMnwbcO1sw=", + "integrity": "sha256-q6JHTldynzleGRhjgnDnqnz43o8/wxuB+UEoiDIEWeg=", "urls": [ - "Packages/libeconf-0.4.1-4.el9.x86_64.rpm" + "Packages/libeconf-0.4.1-5.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -528,6 +598,7 @@ ] }, { + "id": "libedit", "name": "libedit", "integrity": "sha256-v6kf+W8xKyhKFqkbLqvNrp5Dwvm2mP7m7slAQOrvj34=", "urls": [ @@ -540,6 +611,7 @@ ] }, { + "id": "libfdisk", "name": "libfdisk", "integrity": "sha256-mllMUeO/CctQFkhe4vFD3m25YP8cfhNcAJf1n6UbLts=", "urls": [ @@ -553,6 +625,7 @@ ] }, { + "id": "libffi", "name": "libffi", "integrity": "sha256-EQ1QCDZKZbOLgylJlwiG/cy5d2KwzbJXVxzAyEGC19A=", "urls": [ @@ -564,6 +637,7 @@ ] }, { + "id": "libfido2", "name": "libfido2", "integrity": "sha256-hcOoQzXYMwafV1izT0Y2MT/8DVyn9z0k4F/VZnNcXNY=", "urls": [ @@ -579,15 +653,19 @@ ] }, { + "id": "libgcc", "name": "libgcc", - "integrity": "sha256-RCwGWoFSEqwhdg/58L2T6fXVlykl2emHpCHL9uu6QdI=", + "integrity": "sha256-jpsvYRRm4CcDNIv9f73EADWJjIBNzEF7kg1q13vwd+k=", "urls": [ - "Packages/libgcc-11.5.0-5.el9.x86_64.rpm" + "Packages/libgcc-11.5.0-14.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", - "dependencies": [] + "dependencies": [ + "glibc" + ] }, { + "id": "libgcrypt", "name": "libgcrypt", "integrity": "sha256-AyOnSlrSe8PcSsTpVlgl833FiypIAK2/M/dn+nomfDU=", "urls": [ @@ -600,6 +678,7 @@ ] }, { + "id": "libgpg-error", "name": "libgpg-error", "integrity": "sha256-oYg4BMN29zcQn03/Bgd9GRK5AVCnMtEb57xbO2flEv4=", "urls": [ @@ -611,6 +690,7 @@ ] }, { + "id": "libmount", "name": "libmount", "integrity": "sha256-2L/HDRqaWUVpyMlb2mgoBKILtO5gLbPvp7bnbSiezGY=", "urls": [ @@ -625,6 +705,7 @@ ] }, { + "id": "libnghttp2", "name": "libnghttp2", "integrity": "sha256-/BytvGzzfL6mARK3rm+S+r/Vp/dvpSa7Wh6oJ0ZFXsc=", "urls": [ @@ -636,6 +717,7 @@ ] }, { + "id": "libpwquality", "name": "libpwquality", "integrity": "sha256-k/AOXvrB4/HsvA1qTAaHcssSkSzSDJ6lhxbWwM0ASIY=", "urls": [ @@ -650,6 +732,7 @@ ] }, { + "id": "libselinux", "name": "libselinux", "integrity": "sha256-eavnLqjcy0E0KG/RqueYJ/EL3gzBw1IkiG6TspPSgtE=", "urls": [ @@ -663,6 +746,7 @@ ] }, { + "id": "libsemanage", "name": "libsemanage", "integrity": "sha256-Pc9ufyd5Q02dx67wBlw6KXd5IXAmSmDUMk9mJbuc1po=", "urls": [ @@ -678,10 +762,11 @@ ] }, { + "id": "libsepol", "name": "libsepol", - "integrity": "sha256-ehwQpFEmJN/Bt22kW3oNFfjs3d8gyXOLEMoS339IiuE=", + "integrity": "sha256-bT0WwxIcz5ifihI4EuUkyx/AmPsB7J8cYydUToWq+E0=", "urls": [ - "Packages/libsepol-3.6-2.el9.x86_64.rpm" + "Packages/libsepol-3.6-3.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -689,6 +774,7 @@ ] }, { + "id": "libsigsegv", "name": "libsigsegv", "integrity": "sha256-kxvQ7HBQ6MOzepv7SJ4wrzJIajx3ID8ekRPuzqo7Cjo=", "urls": [ @@ -700,6 +786,7 @@ ] }, { + "id": "libsmartcols", "name": "libsmartcols", "integrity": "sha256-MOKgca1vGTnxT8icgn1hzLKKbL9uRD2znoAZoYx+GNQ=", "urls": [ @@ -711,10 +798,11 @@ ] }, { + "id": "libstdc++", "name": "libstdc++", - "integrity": "sha256-ZiigAnoRPIaH0M1S7Vcl7myx7ioCiXNJKJ1oP8ZFMiM=", + "integrity": "sha256-W5EZ2TN10ZuKsUDDWfliPeD94Uh/wekwv6KfVJYuxEg=", "urls": [ - "Packages/libstdc++-11.5.0-5.el9.x86_64.rpm" + "Packages/libstdc++-11.5.0-14.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -723,6 +811,7 @@ ] }, { + "id": "libtasn1", "name": "libtasn1", "integrity": "sha256-rd0VXUq8QVKdfoWI9ELlCofbOhMUvSFi+7SVDYmKLig=", "urls": [ @@ -734,6 +823,7 @@ ] }, { + "id": "libutempter", "name": "libutempter", "integrity": "sha256-+rNhqcugRJD9i1ZkBJmD0eV+v3wQgIBHJrpgBwhSQSU=", "urls": [ @@ -747,6 +837,7 @@ ] }, { + "id": "libuuid", "name": "libuuid", "integrity": "sha256-vkeTvlrxF3Igar4CN0bsQCGot7wST9x+fNuStXxG0SU=", "urls": [ @@ -758,6 +849,7 @@ ] }, { + "id": "libverto", "name": "libverto", "integrity": "sha256-xVV4uE8WnE7Xmy1Q6gP9GBcAfjUGLJ/npY5srQJfOyQ=", "urls": [ @@ -769,6 +861,7 @@ ] }, { + "id": "libxcrypt", "name": "libxcrypt", "integrity": "sha256-l+iGeLQg9hmkRgj/8wBiCGqh3Wkx7L1U8hu6AF/x3ho=", "urls": [ @@ -780,6 +873,7 @@ ] }, { + "id": "libzstd", "name": "libzstd", "integrity": "sha256-NDmnQ3pLR+9LbvvNjFhiGA+ygd2VbXCk/+N2T9jZl90=", "urls": [ @@ -791,6 +885,7 @@ ] }, { + "id": "lz4-libs", "name": "lz4-libs", "integrity": "sha256-y6amMFTQcJVqGC4zJp7iRbz76H4+YFwngWUZ23YqZq0=", "urls": [ @@ -802,10 +897,11 @@ ] }, { + "id": "mpfr", "name": "mpfr", - "integrity": "sha256-F5dgEEqloxykY8WG0PIfOAuk0O7SEu7pG9HKUT5deo0=", + "integrity": "sha256-GUTg7nHn5esM0HcrePeOBPXFsdW5rs08qsPUDCReCAw=", "urls": [ - "Packages/mpfr-4.1.0-7.el9.x86_64.rpm" + "Packages/mpfr-4.1.0-8.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -814,10 +910,11 @@ ] }, { + "id": "ncurses", "name": "ncurses", - "integrity": "sha256-RddD3Npb4jC64S7z+IP3XocpWZPuSg8nfDH2kQIurDA=", + "integrity": "sha256-fyOnxbV9Olv1i6MGpYYwcwJq6qRozjnEF6NN0/15oBM=", "urls": [ - "Packages/ncurses-6.2-10.20210508.el9.x86_64.rpm" + "Packages/ncurses-6.2-12.20210508.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -826,19 +923,21 @@ ] }, { + "id": "ncurses-base", "name": "ncurses-base", - "integrity": "sha256-ALpWsoo6hcPAM4e7er7Kkll8il+sf1PUhBDKKiD9gGU=", + "integrity": "sha256-SfZHD6fdGzuoHM3QVHsplTryg14GfekV7so8RdX6ozk=", "urls": [ - "Packages/ncurses-base-6.2-10.20210508.el9.noarch.rpm" + "Packages/ncurses-base-6.2-12.20210508.el9.noarch.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [] }, { + "id": "ncurses-libs", "name": "ncurses-libs", - "integrity": "sha256-9OrXClCAUe0zhJmzVgW1srW8zeGcnoP35LlI8XG1Qv8=", + "integrity": "sha256-ezlogyMhWNT5ppd7zXK15vf6a8NKUQMDeYM9TA0kq28=", "urls": [ - "Packages/ncurses-libs-6.2-10.20210508.el9.x86_64.rpm" + "Packages/ncurses-libs-6.2-12.20210508.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -847,10 +946,11 @@ ] }, { + "id": "openssh", "name": "openssh", - "integrity": "sha256-TywaYpCzwK0q/LR9RLHW4lI4EP0L+8S3VGgqJ9vytqM=", + "integrity": "sha256-kq465XTNO4BRfbnWab15mpMIOHBNrIaOOYMn/sQ42Us=", "urls": [ - "Packages/openssh-8.7p1-45.el9.x86_64.rpm" + "Packages/openssh-9.9p1-3.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -858,17 +958,17 @@ "bash", "glibc", "libselinux", - "libxcrypt", "openssl-libs", "util-linux", "zlib" ] }, { + "id": "openssh-clients", "name": "openssh-clients", - "integrity": "sha256-TpPqQxM8nBC7zMyOVbTLqOSwCzx2WX1kw7HlS002U8o=", + "integrity": "sha256-H4jmmSiTd/NSHV3uQsD/PuU36sao6U2E9k3vSCcVb2Q=", "urls": [ - "Packages/openssh-clients-8.7p1-45.el9.x86_64.rpm" + "Packages/openssh-clients-9.9p1-3.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -879,17 +979,17 @@ "libedit", "libfido2", "libselinux", - "libxcrypt", "openssh", "openssl-libs", "zlib" ] }, { + "id": "openssl", "name": "openssl", - "integrity": "sha256-MBjF0pASE7a9vmIwHviUAI7FKxEi4nAZDqu2KtKCpGo=", + "integrity": "sha256-5K9eROoaEYC+yftG/BD6bueeZxmlam+Hm2HZT+sn5rg=", "urls": [ - "Packages/openssl-3.2.2-6.el9.x86_64.rpm" + "Packages/openssl-3.5.1-6.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -900,24 +1000,27 @@ ] }, { + "id": "openssl-libs", "name": "openssl-libs", - "integrity": "sha256-Sgopown3K6ZaLQstS1FjclNSD2oKG9RkDwoJ99dVVzg=", + "integrity": "sha256-U8Iga6JQOuJWsmgVzS6e2A7bT5Aw9UQHJ2Xcswuyxjs=", "urls": [ - "Packages/openssl-libs-3.2.2-6.el9.x86_64.rpm" + "Packages/openssl-libs-3.5.1-6.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ "ca-certificates", "crypto-policies", + "fips-provider-next", "glibc", "zlib" ] }, { + "id": "p11-kit", "name": "p11-kit", - "integrity": "sha256-LQLzLNti+sMlY8cPrUTHJS8Bc1UsyrxY0rUWEgfCkaM=", + "integrity": "sha256-dMk/ON/lgOIwwX5v9MN1D33tW7IVbnVbKIBjfgvYJvs=", "urls": [ - "Packages/p11-kit-0.25.3-3.el9.x86_64.rpm" + "Packages/p11-kit-0.25.10-1.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -927,10 +1030,11 @@ ] }, { + "id": "p11-kit-trust", "name": "p11-kit-trust", - "integrity": "sha256-87GMxp15iZ4X18dRSk41C91hZqN+l5/uXc+9x5IaAvo=", + "integrity": "sha256-nDrhmrncsfLsc+ZvNtj+VidUAosyVot0xOlqSi8FK6w=", "urls": [ - "Packages/p11-kit-trust-0.25.3-3.el9.x86_64.rpm" + "Packages/p11-kit-trust-0.25.10-1.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -941,10 +1045,11 @@ ] }, { + "id": "pam", "name": "pam", - "integrity": "sha256-+6OSCWy/WSBFSbyiPUBgzfiqqpzjWt6BlMER9RkDPhA=", + "integrity": "sha256-PJL9E0fXj8NiHNWuYvehWViNhqigwiukp1Tc1Rkmtrc=", "urls": [ - "Packages/pam-1.5.1-23.el9.x86_64.rpm" + "Packages/pam-1.5.1-28.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -961,6 +1066,7 @@ ] }, { + "id": "pcre", "name": "pcre", "integrity": "sha256-fWvh1By00LFZp2S/x8jv7MA1MiS0blKGy76nCStwBpA=", "urls": [ @@ -972,6 +1078,7 @@ ] }, { + "id": "pcre2", "name": "pcre2", "integrity": "sha256-vBAS9UF6q4OTg214rIxUcrGi2Eovn6KwD/9fitOl7CY=", "urls": [ @@ -984,6 +1091,7 @@ ] }, { + "id": "pcre2-syntax", "name": "pcre2-syntax", "integrity": "sha256-vjaoT24xGlkZBmTWGkZkcTkasB+3e9HSNI6adkFK3tQ=", "urls": [ @@ -993,24 +1101,26 @@ "dependencies": [] }, { + "id": "perl-AutoLoader", "name": "perl-AutoLoader", - "integrity": "sha256-8Lz0oEpisWPGyAAG1gQRfPWoJXVs457xvQgYroSKos8=", + "integrity": "sha256-H9DDw2OAS+Mll8Jn1285aWpWLQ4e5o4vDxHcjcv5xOM=", "urls": [ - "Packages/perl-AutoLoader-5.74-481.el9.noarch.rpm" + "Packages/perl-AutoLoader-5.74-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-libs" ] }, { + "id": "perl-B", "name": "perl-B", - "integrity": "sha256-33sMMEj/vgXQ/22vxF8K99oYlXkgTDvo0ocqBKZ5Tf8=", + "integrity": "sha256-ID2ZeZtzNborkU8WKstDeAiSZdoQG8HFWv23G78FhgA=", "urls": [ - "Packages/perl-B-1.80-481.el9.x86_64.rpm" + "Packages/perl-B-1.80-483.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-Carp", @@ -1021,24 +1131,26 @@ ] }, { + "id": "perl-Carp", "name": "perl-Carp", "integrity": "sha256-8cpqqkfvlta0fyDzot8s5TAih5DywDMOzlZ8x33dUGM=", "urls": [ "Packages/perl-Carp-1.50-460.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Exporter", "perl-libs" ] }, { + "id": "perl-Class-Struct", "name": "perl-Class-Struct", - "integrity": "sha256-dBGb2QRQP5xXy8LCVLFOCEBhFaBMElPiIHNyyrWb4e4=", + "integrity": "sha256-HfZcu821m2glLtWp+va5I+TyhklnflOIaTUl/bfyuoM=", "urls": [ - "Packages/perl-Class-Struct-0.66-481.el9.noarch.rpm" + "Packages/perl-Class-Struct-0.66-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Exporter", @@ -1046,12 +1158,13 @@ ] }, { + "id": "perl-Data-Dumper", "name": "perl-Data-Dumper", "integrity": "sha256-+XnS7+0TYAH+DVRjK2JrU4QsKB+TVECOD3x1vPxAj2c=", "urls": [ "Packages/perl-Data-Dumper-2.174-462.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-B", @@ -1063,12 +1176,13 @@ ] }, { + "id": "perl-Digest", "name": "perl-Digest", "integrity": "sha256-3ktxwc+BjUiUDKD2j108UgoyGv/p4zta/Xl2yBHx10E=", "urls": [ "Packages/perl-Digest-1.19-4.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Exporter", @@ -1077,12 +1191,13 @@ ] }, { + "id": "perl-Digest-MD5", "name": "perl-Digest-MD5", "integrity": "sha256-7H44wpEF4VAqE+jhP5vBsbwCohur8C6VppZrQKjYy6o=", "urls": [ "Packages/perl-Digest-MD5-2.58-4.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-Digest", @@ -1091,10 +1206,11 @@ ] }, { + "id": "perl-DynaLoader", "name": "perl-DynaLoader", - "integrity": "sha256-7XQjjJmo9p15nzHGC7T68H+mJQgNvHM1liEEq2MVmnk=", + "integrity": "sha256-s1mMlhXR/U83YgxfD9sW8Cm8oQX7mK/EtFHtdXd2fBE=", "urls": [ - "Packages/perl-DynaLoader-1.47-481.el9.x86_64.rpm" + "Packages/perl-DynaLoader-1.47-483.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-appstream", "dependencies": [ @@ -1103,12 +1219,13 @@ ] }, { + "id": "perl-Encode", "name": "perl-Encode", "integrity": "sha256-hdt4WXEbMPJoMFrQs82raMgHL99rpgclpJZX1q4AG+o=", "urls": [ "Packages/perl-Encode-3.08-462.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-Carp", @@ -1127,12 +1244,13 @@ ] }, { + "id": "perl-Errno", "name": "perl-Errno", - "integrity": "sha256-incNGcSFN2Bt2K5QzSTJpI8+vpmf+baqI/CGAgMcXuM=", + "integrity": "sha256-ABU6/aUE/xtw5Cc+xVx9cb+BywvX9WWhUI4jMvnuLiM=", "urls": [ - "Packages/perl-Errno-1.30-481.el9.x86_64.rpm" + "Packages/perl-Errno-1.30-483.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Exporter", @@ -1140,6 +1258,7 @@ ] }, { + "id": "perl-Error", "name": "perl-Error", "integrity": "sha256-SoFheuTjcY/tmvdnEdDUq0w86nxfELJrcE3SoV1sotU=", "urls": [ @@ -1156,24 +1275,26 @@ ] }, { + "id": "perl-Exporter", "name": "perl-Exporter", "integrity": "sha256-H+/Fp7yM0xqFPAkM2qB1g0TKzFZWFTLf7yCrcL0wvKs=", "urls": [ "Packages/perl-Exporter-5.74-461.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-libs" ] }, { + "id": "perl-Fcntl", "name": "perl-Fcntl", - "integrity": "sha256-0qhmfrQxnZxErKhJPI/IQUjustXiOqIilyEMHeH9eEY=", + "integrity": "sha256-92r93f1PeXuFdBlGtv2EK1EI8rAh6djJMDq35TeHqrc=", "urls": [ - "Packages/perl-Fcntl-1.13-481.el9.x86_64.rpm" + "Packages/perl-Fcntl-1.13-483.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-Exporter", @@ -1181,12 +1302,13 @@ ] }, { + "id": "perl-File-Basename", "name": "perl-File-Basename", - "integrity": "sha256-x4rAbU9uuCUJHT49rkSKQpy0cRsd32x1/fAJRuwJ/X0=", + "integrity": "sha256-gWtCYcaGfvRv7aO/8iwJoXffMMCTqSRmqrmj4znlx0w=", "urls": [ - "Packages/perl-File-Basename-2.85-481.el9.noarch.rpm" + "Packages/perl-File-Basename-2.85-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Exporter", @@ -1194,10 +1316,11 @@ ] }, { + "id": "perl-File-Find", "name": "perl-File-Find", - "integrity": "sha256-fuTgxIF7glvhZeZjvAPxyO5F6HK4+2uJaDVbrhYi5h4=", + "integrity": "sha256-h8GiIer8p5fUQnWA0PTGbTvhinYoDpYdAG+RMRBhUeY=", "urls": [ - "Packages/perl-File-Find-1.37-481.el9.noarch.rpm" + "Packages/perl-File-Find-1.37-483.el9.noarch.rpm" ], "repository": "centos-stream-9-stable-appstream", "dependencies": [ @@ -1208,12 +1331,13 @@ ] }, { + "id": "perl-File-Path", "name": "perl-File-Path", "integrity": "sha256-dLf3XPPIv3GRqObYhonXrKGx9g1WyJDq19VYpwSkpMw=", "urls": [ "Packages/perl-File-Path-2.18-4.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Exporter", @@ -1224,12 +1348,13 @@ ] }, { + "id": "perl-File-Temp", "name": "perl-File-Temp", "integrity": "sha256-oUFmcMBR/ffqXn/6wFnYjhexSmHPdalb5uPG0ucwEBs=", "urls": [ "Packages/perl-File-Temp-0.231.100-4.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Errno", @@ -1247,12 +1372,13 @@ ] }, { + "id": "perl-File-stat", "name": "perl-File-stat", - "integrity": "sha256-k+PgO9i9999AZX5ZHaqUZx/zV2zYiVTgVOR63CcDLI4=", + "integrity": "sha256-vaFzF3ZufqP+EHP3UCnfNfZkjU0037n2KuymwxYpfGQ=", "urls": [ - "Packages/perl-File-stat-1.09-481.el9.noarch.rpm" + "Packages/perl-File-stat-1.09-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Class-Struct", @@ -1265,12 +1391,13 @@ ] }, { + "id": "perl-FileHandle", "name": "perl-FileHandle", - "integrity": "sha256-hCS3zsBkKM++iI2dmminUt/XhGbby06GEURp+wNFhNA=", + "integrity": "sha256-XmxrYLcGPBKkIXN9YUHhJ9JDYU1tOnXuClTrpx7FWhk=", "urls": [ - "Packages/perl-FileHandle-2.03-481.el9.noarch.rpm" + "Packages/perl-FileHandle-2.03-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Exporter", "perl-IO", @@ -1278,12 +1405,13 @@ ] }, { + "id": "perl-Getopt-Long", "name": "perl-Getopt-Long", "integrity": "sha256-AFPWOl6wvDmeLlaiWZoaCdyiDFvKw29xOlb+xGq6w5E=", "urls": [ "Packages/perl-Getopt-Long-2.52-4.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Exporter", "perl-Pod-Usage", @@ -1295,22 +1423,24 @@ ] }, { + "id": "perl-Getopt-Std", "name": "perl-Getopt-Std", - "integrity": "sha256-ZpQ5jDLeSm8nkEviXEt2U27Z8Ml4HJRq1IpB058GegU=", + "integrity": "sha256-lrQVB+ZQRAm0tvEMiNyo0HLWHHmZjNGNYofkewhX2Hc=", "urls": [ - "Packages/perl-Getopt-Std-1.12-481.el9.noarch.rpm" + "Packages/perl-Getopt-Std-1.12-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Exporter", "perl-libs" ] }, { + "id": "perl-Git", "name": "perl-Git", - "integrity": "sha256-zBhd0Vpbd4fLGl+TRWs+vicfkob2Z1efM9dvE7wX+II=", + "integrity": "sha256-GddTFmX28FH4o1ocrNe2OtBx1VOyI+/idt9UUtuoQGw=", "urls": [ - "Packages/perl-Git-2.47.1-1.el9.noarch.rpm" + "Packages/perl-Git-2.47.3-1.el9.noarch.rpm" ], "repository": "centos-stream-9-stable-appstream", "dependencies": [ @@ -1322,12 +1452,13 @@ ] }, { + "id": "perl-HTTP-Tiny", "name": "perl-HTTP-Tiny", "integrity": "sha256-hXm81BErlzw70HLbgy4mxNBOuYSVKJLAHvcRmxjMv1A=", "urls": [ "Packages/perl-HTTP-Tiny-0.076-462.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Errno", @@ -1343,12 +1474,13 @@ ] }, { + "id": "perl-IO", "name": "perl-IO", - "integrity": "sha256-EnxT+MAF7jCY5S4ZeuHH/7/Gw1Nz3n1DwcBCky8UjZs=", + "integrity": "sha256-CR+WSRr2OPTzV9NkFgVarO2gU60kytWG0La7sUn1gFA=", "urls": [ - "Packages/perl-IO-1.43-481.el9.x86_64.rpm" + "Packages/perl-IO-1.43-483.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-Carp", @@ -1364,12 +1496,13 @@ ] }, { + "id": "perl-IO-Socket-IP", "name": "perl-IO-Socket-IP", "integrity": "sha256-lbq+HZby39hfFh0/grs7pK1KJZHQ2QkZEy8TWDd/U78=", "urls": [ "Packages/perl-IO-Socket-IP-0.41-5.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Errno", @@ -1382,12 +1515,13 @@ ] }, { + "id": "perl-IO-Socket-SSL", "name": "perl-IO-Socket-SSL", "integrity": "sha256-5S3lOPExZGEi3MxJhbY9RI7xxkFUP6wt8GazF5jhYTE=", "urls": [ "Packages/perl-IO-Socket-SSL-2.073-2.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "openssl-libs", "perl-Carp", @@ -1405,12 +1539,13 @@ ] }, { + "id": "perl-IPC-Open3", "name": "perl-IPC-Open3", - "integrity": "sha256-VvnMQ4lRFAoaomYlVsElnZorTYDY4R51YWXnLinWHLM=", + "integrity": "sha256-OKSjiKmWPtXQ2R5rS/XbOm/xCx4RQhDIpRNRUpch09c=", "urls": [ - "Packages/perl-IPC-Open3-1.21-481.el9.noarch.rpm" + "Packages/perl-IPC-Open3-1.21-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Exporter", @@ -1423,12 +1558,13 @@ ] }, { + "id": "perl-MIME-Base64", "name": "perl-MIME-Base64", "integrity": "sha256-zk1O645FJCEkN6yWTZ8La6VixwZKe/l2vsWDbofiDNI=", "urls": [ "Packages/perl-MIME-Base64-3.16-4.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-Exporter", @@ -1436,12 +1572,13 @@ ] }, { + "id": "perl-Mozilla-CA", "name": "perl-Mozilla-CA", "integrity": "sha256-J9/HL2BFBmVMZx0WSFJmgJTaXoF+hLgZLyHilCmlmDg=", "urls": [ "Packages/perl-Mozilla-CA-20200520-6.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "ca-certificates", "perl-PathTools", @@ -1449,12 +1586,13 @@ ] }, { + "id": "perl-Net-SSLeay", "name": "perl-Net-SSLeay", - "integrity": "sha256-2Abd5ePntrPKzfgcE/WQxGaxrQA7GOYuHAy7/dJ3GY8=", + "integrity": "sha256-T7M1ur1Ewx4lQg1MomFNJzI5FaQnbUsiFdTTfjIGEXs=", "urls": [ - "Packages/perl-Net-SSLeay-1.94-1.el9.x86_64.rpm" + "Packages/perl-Net-SSLeay-1.94-3.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "openssl-libs", @@ -1469,12 +1607,13 @@ ] }, { + "id": "perl-POSIX", "name": "perl-POSIX", - "integrity": "sha256-0uaOgsNNQF+F5IYJ3wfGrnLMZd8YHis+C8gTn+MqLDA=", + "integrity": "sha256-RXbsW/H78n3e3kFNLf+y9LUzilMKUlSTs9F9tq65Tak=", "urls": [ - "Packages/perl-POSIX-1.94-481.el9.x86_64.rpm" + "Packages/perl-POSIX-1.94-483.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-Carp", @@ -1484,12 +1623,13 @@ ] }, { + "id": "perl-PathTools", "name": "perl-PathTools", "integrity": "sha256-DvYTqP49niNVp7Bj8c1dAZdyyDfiQ1ye/NfqklrScCQ=", "urls": [ "Packages/perl-PathTools-3.78-461.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-Carp", @@ -1501,12 +1641,13 @@ ] }, { + "id": "perl-Pod-Escapes", "name": "perl-Pod-Escapes", "integrity": "sha256-wyrU8C7K0mTSM3g3hIcGzETwUC852XimwFUWb8+M6Rc=", "urls": [ "Packages/perl-Pod-Escapes-1.07-460.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Exporter", "perl-libs", @@ -1514,12 +1655,13 @@ ] }, { + "id": "perl-Pod-Perldoc", "name": "perl-Pod-Perldoc", "integrity": "sha256-+zhYN4bB2FH+Fg3g5DauK7My9g4HKm5Y2wKyr/uaq2w=", "urls": [ "Packages/perl-Pod-Perldoc-3.28.01-461.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "groff-base", "perl-Carp", @@ -1542,12 +1684,13 @@ ] }, { + "id": "perl-Pod-Simple", "name": "perl-Pod-Simple", "integrity": "sha256-S3BXWp8OvA8AJmgRElMiQ7BpnKfcXcsWXO+FatwewNg=", "urls": [ "Packages/perl-Pod-Simple-3.42-4.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Encode", @@ -1564,12 +1707,13 @@ ] }, { + "id": "perl-Pod-Usage", "name": "perl-Pod-Usage", "integrity": "sha256-Ld7R76JUEYxkav/VlhUjeCXwDja4apapj9Wci2AVYSo=", "urls": [ "Packages/perl-Pod-Usage-2.01-4.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Exporter", @@ -1582,12 +1726,13 @@ ] }, { + "id": "perl-Scalar-List-Utils", "name": "perl-Scalar-List-Utils", "integrity": "sha256-46VEZPGuuyWiqwRjB8PWoDK77WT0k+Ts5SHTgB0dtI4=", "urls": [ "Packages/perl-Scalar-List-Utils-1.56-462.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-Carp", @@ -1596,12 +1741,13 @@ ] }, { + "id": "perl-SelectSaver", "name": "perl-SelectSaver", - "integrity": "sha256-SYAta8ClBT8Db530tUPXPTGEhBMD14ZtgBh5YnqtMqQ=", + "integrity": "sha256-AuCQrdfAaCAYEU+IzwMXEdaG+RGNRGq2rc/Oia7GRkA=", "urls": [ - "Packages/perl-SelectSaver-1.02-481.el9.noarch.rpm" + "Packages/perl-SelectSaver-1.02-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Symbol", @@ -1609,12 +1755,13 @@ ] }, { + "id": "perl-Socket", "name": "perl-Socket", "integrity": "sha256-NWzBYii5emSviyVIZhq2knezKjBmPaKXJ+5iolA8POw=", "urls": [ "Packages/perl-Socket-2.031-4.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-Carp", @@ -1623,12 +1770,13 @@ ] }, { + "id": "perl-Storable", "name": "perl-Storable", "integrity": "sha256-AnwEITes9m3tDeUoWWEL42NzzNVV3DCoZaMSZ8IsVXk=", "urls": [ "Packages/perl-Storable-3.21-460.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-Carp", @@ -1639,36 +1787,39 @@ ] }, { + "id": "perl-Symbol", "name": "perl-Symbol", - "integrity": "sha256-rgm9etwtSQxtCd3C7MSgEuXnQPHXeFOQrx6BDMLQ5Bw=", + "integrity": "sha256-EBgBPM2HhreHt35QOrN3QXDr4coRrlNce8LYQGFGMu4=", "urls": [ - "Packages/perl-Symbol-1.08-481.el9.noarch.rpm" + "Packages/perl-Symbol-1.08-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Exporter", "perl-libs" ] }, { + "id": "perl-Term-ANSIColor", "name": "perl-Term-ANSIColor", "integrity": "sha256-1Oh8eVeA+hkLq6UpHDkOmvME5PE05KpPLQP8m5HKXWA=", "urls": [ "Packages/perl-Term-ANSIColor-5.01-461.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Exporter", "perl-libs" ] }, { + "id": "perl-Term-Cap", "name": "perl-Term-Cap", "integrity": "sha256-XDjFPlYvJMvbOVsRNY76r2rugszThQVcX/zxhDWT2No=", "urls": [ "Packages/perl-Term-Cap-1.17-460.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "ncurses", "perl-Carp", @@ -1677,6 +1828,7 @@ ] }, { + "id": "perl-TermReadKey", "name": "perl-TermReadKey", "integrity": "sha256-GH95ZysRaS9c0f3d0HcIhWRCgYrM+hIL7kC+PltrPP8=", "urls": [ @@ -1692,12 +1844,13 @@ ] }, { + "id": "perl-Text-ParseWords", "name": "perl-Text-ParseWords", "integrity": "sha256-EmTdNdXe2lG0QxlVsoOM0Y4AEtwn8ODLZQYTJCFv8iw=", "urls": [ "Packages/perl-Text-ParseWords-3.30-460.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Exporter", @@ -1705,12 +1858,13 @@ ] }, { + "id": "perl-Text-Tabs+Wrap", "name": "perl-Text-Tabs+Wrap", "integrity": "sha256-EZZiMdKDSyqcLAvyryMeElfOAw2hz+zdFtCKaiMiKyQ=", "urls": [ "Packages/perl-Text-Tabs+Wrap-2013.0523-460.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Exporter", "perl-libs", @@ -1718,12 +1872,13 @@ ] }, { + "id": "perl-Time-Local", "name": "perl-Time-Local", "integrity": "sha256-U/lhb5xgyPt77+/4f1t2xh7nVoamwonzlMR5PTaS3js=", "urls": [ "Packages/perl-Time-Local-1.300-7.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Exporter", @@ -1733,12 +1888,13 @@ ] }, { + "id": "perl-URI", "name": "perl-URI", "integrity": "sha256-dF+E/HgchHY8rYABhBcR1hQusT9Q5V3pKNPQUaBDXvI=", "urls": [ "Packages/perl-URI-5.09-3.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Data-Dumper", @@ -1755,57 +1911,62 @@ ] }, { + "id": "perl-base", "name": "perl-base", - "integrity": "sha256-fp32QcUCK4JH2F232t3EWBLRv3DbDHxdLojYPuL9Faw=", + "integrity": "sha256-DkFboErWnif6jmxTii57vZ2nGa3QJgn/e5by8PLb3n4=", "urls": [ - "Packages/perl-base-2.27-481.el9.noarch.rpm" + "Packages/perl-base-2.27-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-libs" ] }, { + "id": "perl-constant", "name": "perl-constant", "integrity": "sha256-aiXPudg8ab12e+DjDeJtvJ7OkCyehIllwzeO8UBc624=", "urls": [ "Packages/perl-constant-1.33-461.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-libs" ] }, { + "id": "perl-if", "name": "perl-if", - "integrity": "sha256-XdXELs1awn4qFlJZjLkVN4g1PPt1VB9YU4olkCae5/w=", + "integrity": "sha256-Mm7kpqUWPE6P+/obCr97QFjrJv785ikNO8YBxWrvVks=", "urls": [ - "Packages/perl-if-0.60.800-481.el9.noarch.rpm" + "Packages/perl-if-0.60.800-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-libs" ] }, { + "id": "perl-interpreter", "name": "perl-interpreter", - "integrity": "sha256-tAmZwcoatbX2Q3D6Y34R+xb4Eoqouic+T2GEfkuDsr0=", + "integrity": "sha256-1f7fpVOsCPMAAM4jBdGRYgppV+ClkkR5ftzEkrfB650=", "urls": [ - "Packages/perl-interpreter-5.32.1-481.el9.x86_64.rpm" + "Packages/perl-interpreter-5.32.1-483.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-libs" ] }, { + "id": "perl-lib", "name": "perl-lib", - "integrity": "sha256-Ua0KySESn/EJx+5Ha61sUv7bgybuO+eMPx26e18u1rs=", + "integrity": "sha256-IlFO6a8tzD2Suro9RBFWJsP9PdRumT3o9NziHWxIO3Y=", "urls": [ - "Packages/perl-lib-0.65-481.el9.x86_64.rpm" + "Packages/perl-lib-0.65-483.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-appstream", "dependencies": [ @@ -1814,12 +1975,13 @@ ] }, { + "id": "perl-libnet", "name": "perl-libnet", "integrity": "sha256-uILIdCQm0njTh0MqZSIL1j/9FnBzeupDCEmU0rY45dQ=", "urls": [ "Packages/perl-libnet-3.13-4.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Digest-MD5", @@ -1839,12 +2001,13 @@ ] }, { + "id": "perl-libs", "name": "perl-libs", - "integrity": "sha256-lNvlBIMnBI0nF+yiQOt0C46hky44Athlrh3OjEKXqTg=", + "integrity": "sha256-VUKeiVQpKBiHtETZKkUUmWajDBzLES4aT0vW3EdSwlo=", "urls": [ - "Packages/perl-libs-5.32.1-481.el9.x86_64.rpm" + "Packages/perl-libs-5.32.1-483.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "libxcrypt", @@ -1855,24 +2018,26 @@ ] }, { + "id": "perl-mro", "name": "perl-mro", - "integrity": "sha256-Wm9HoG4XRi6JUO8Fi1cKy6Z589Kv2j8Io+g/yGuf9sY=", + "integrity": "sha256-gVWh9ZHm8RQo0exyxJ2iQY+SB7yueA7DjSrppqOUM9w=", "urls": [ - "Packages/perl-mro-1.23-481.el9.x86_64.rpm" + "Packages/perl-mro-1.23-483.el9.x86_64.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "glibc", "perl-libs" ] }, { + "id": "perl-overload", "name": "perl-overload", - "integrity": "sha256-mDFhHkwRf0quko7KR09nfzJTAOMt1PeT0hi7s2wPjcU=", + "integrity": "sha256-85Huq17gZZxEwYK9g+efUZeiBHQT3exGmnDch930Kls=", "urls": [ - "Packages/perl-overload-1.31-481.el9.noarch.rpm" + "Packages/perl-overload-1.31-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Scalar-List-Utils", "perl-libs", @@ -1881,35 +2046,38 @@ ] }, { + "id": "perl-overloading", "name": "perl-overloading", - "integrity": "sha256-UKYnxXb/GbbdppLJK0IcrXqFFXzXHTk3UqzGI/f4lYA=", + "integrity": "sha256-5oZQcw8Su89VzmG/cAJbNw3z/9fqQkCiSluLlVSLg0k=", "urls": [ - "Packages/perl-overloading-0.02-481.el9.noarch.rpm" + "Packages/perl-overloading-0.02-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-libs" ] }, { + "id": "perl-parent", "name": "perl-parent", "integrity": "sha256-NCp7hKRM1ZvqBF9nkwnvYUWiNYl97bipr9LQFbwX9yo=", "urls": [ "Packages/perl-parent-0.238-460.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-libs" ] }, { + "id": "perl-podlators", "name": "perl-podlators", "integrity": "sha256-qsm0wczZQq+uwZKZiA64nhiJtFMefKt1HDvmpm+cX6Y=", "urls": [ "Packages/perl-podlators-4.14-460.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-Encode", @@ -1929,29 +2097,32 @@ ] }, { + "id": "perl-subs", "name": "perl-subs", - "integrity": "sha256-1/xb/SOXFEmesuSS7u4utj5hc4Ru/KOcL0L4XS8/ptc=", + "integrity": "sha256-1EYMvmVnp3464oUec7XPGN67dKyHxwkIJjhz0D9NCRU=", "urls": [ - "Packages/perl-subs-1.03-481.el9.noarch.rpm" + "Packages/perl-subs-1.03-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-libs" ] }, { + "id": "perl-vars", "name": "perl-vars", - "integrity": "sha256-NuV3H7U0I+/dGHXwNKTX4IQ0pXgKt75F+24ykl5osa0=", + "integrity": "sha256-nQu9ALoqVdxxOQhYUpmMqlsK8TQQb85z+7Y2ayAmZjY=", "urls": [ - "Packages/perl-vars-1.05-481.el9.noarch.rpm" + "Packages/perl-vars-1.05-483.el9.noarch.rpm" ], - "repository": "centos-stream-9-stable-baseos", + "repository": "centos-stream-9-stable-appstream", "dependencies": [ "perl-Carp", "perl-libs" ] }, { + "id": "readline", "name": "readline", "integrity": "sha256-SZRUcpJShq2JsFdWV7Q/kiR3fja0QvDIjfZ/C2Hiau4=", "urls": [ @@ -1964,6 +2135,7 @@ ] }, { + "id": "sed", "name": "sed", "integrity": "sha256-osXZp/Vpq7Wlkt8cOq/wRBv4J8nQ4t8KtCtsRD28R18=", "urls": [ @@ -1977,6 +2149,7 @@ ] }, { + "id": "setup", "name": "setup", "integrity": "sha256-QqHFpBXETjtVVR9JWVwIfiulXw/Z7OgFa3kZg2AbdtI=", "urls": [ @@ -1988,10 +2161,11 @@ ] }, { + "id": "shadow-utils", "name": "shadow-utils", - "integrity": "sha256-I/FBQ6GIz5v4oDFfkw++6wrTTFg1cAelLREsX4tgKeA=", + "integrity": "sha256-+C3PZrqZKH6uvjIlywHSUu6kAgKwsmOismGfh9mJGP0=", "urls": [ - "Packages/shadow-utils-4.9-12.el9.x86_64.rpm" + "Packages/shadow-utils-4.9-16.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -2006,10 +2180,11 @@ ] }, { + "id": "systemd-libs", "name": "systemd-libs", - "integrity": "sha256-qdAqFrvHeK06K0a4dA+oId8GXNrNa6hXDDMB2srXnw8=", + "integrity": "sha256-34QsylZ2FL8giRI031ZrPePwCEUKJabktgMawYPn0X0=", "urls": [ - "Packages/systemd-libs-252-51.el9.x86_64.rpm" + "Packages/systemd-libs-252-64.el9.x86_64.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [ @@ -2032,15 +2207,17 @@ ] }, { + "id": "tzdata", "name": "tzdata", - "integrity": "sha256-ZVlF5qDpW5YKQigovByzusIjL+m3ZZDjWtAAaQl/CHo=", + "integrity": "sha256-p6cPToqhRzFTI1kAp2dTrvj0Okwh64aQEr9LBlzIuTI=", "urls": [ - "Packages/tzdata-2025a-1.el9.noarch.rpm" + "Packages/tzdata-2025c-1.el9.noarch.rpm" ], "repository": "centos-stream-9-stable-baseos", "dependencies": [] }, { + "id": "util-linux", "name": "util-linux", "integrity": "sha256-d/WqWchcEjG95/ZKfjSLt7RnWgTjheIZJ1q710gDcHU=", "urls": [ @@ -2070,6 +2247,7 @@ ] }, { + "id": "util-linux-core", "name": "util-linux-core", "integrity": "sha256-GFj76mV6ntzkFP2YuCYLN+9SF2nwaDD8zHgxCU7AQVQ=", "urls": [ @@ -2089,6 +2267,7 @@ ] }, { + "id": "xz-libs", "name": "xz-libs", "integrity": "sha256-/zyIKX11xRpfjp0tafitHq+DR+IJILQzWj4PxTJprSg=", "urls": [ @@ -2100,6 +2279,7 @@ ] }, { + "id": "zlib", "name": "zlib", "integrity": "sha256-NwlR6mNbwWMT8hrCgj7IFRR+0RJLdIZaNMVOlOTblgI=", "urls": [ @@ -2112,6 +2292,7 @@ } ], "targets": [ + "bash", "git", "glibc" ], diff --git a/e2e/helpers.bzl b/e2e/helpers.bzl new file mode 100644 index 00000000..16a38bf5 --- /dev/null +++ b/e2e/helpers.bzl @@ -0,0 +1,44 @@ +"A series of helpers for our e2e infrastructure" + +load("@bazel_skylib//lib:paths.bzl", "paths") +load( + "@rules_bazel_integration_test//bazel_integration_test:defs.bzl", + _default_test_runner = "default_test_runner", +) + +def glob_workspace_files(workspace_path, extra_excludes = []): + """Recursively globs the Bazel workspace files at the specified path. + + Improved from integration_test_utils.glob_workspace_files + + Args: + workspace_path: A `string` representing the path to glob. + extra_excludes: Other glob patterns to ignore + + Returns: + A `list` of the files under the specified path ignoring certain Bazel + artifacts (e.g. `bazel-*`). + """ + return native.glob( + [paths.join(workspace_path, "**", "*")], + exclude = [ + paths.join(workspace_path, "bazel-*", "**"), + paths.join(workspace_path, "MODULE.bazel.lock"), + ] + extra_excludes, + ) + +def default_test_runner(name, bazel_cmds = [], **kwargs): + """GitHub bazel-contrib/setup-bazel action compatible runner + + Args: + name: name of the target + bazel_cmds: list of commands to execute + **kwargs: other arguments to pass to upstream default_test_runner + """ + + bazel_cmds = [ + "--nohome_rc {}".format(x) + for x in bazel_cmds + ] + + _default_test_runner(name = name, bazel_cmds = bazel_cmds, **kwargs) diff --git a/e2e/repo-yaml/.bazelrc b/e2e/repo-yaml/.bazelrc new file mode 100644 index 00000000..f9d74810 --- /dev/null +++ b/e2e/repo-yaml/.bazelrc @@ -0,0 +1,14 @@ +# Import Aspect bazelrc presets +import %workspace%/../../.aspect/bazelrc/bazel7.bazelrc + +# Include our e2e shared config +try-import %workspace%/../.bazelrc + +# Specific project flags go here if we have some +common --enable_bzlmod + +# Load any settings & overrides specific to the current user from `.bazelrc.user`. +# This file should appear in `.gitignore` so that settings are not shared with team members. This +# should be last statement in this config so the user configuration is able to overwrite flags from +# this file. See https://bazel.build/configure/best-practices#bazelrc-file. +try-import %workspace%/../../.bazelrc.user diff --git a/e2e/repo-yaml/BUILD.bazel b/e2e/repo-yaml/BUILD.bazel new file mode 100644 index 00000000..7be258c3 --- /dev/null +++ b/e2e/repo-yaml/BUILD.bazel @@ -0,0 +1,5 @@ +load("@bazeldnf//bazeldnf:defs.bzl", "bazeldnf") + +bazeldnf( + name = "bazeldnf", +) diff --git a/e2e/repo-yaml/MODULE.bazel b/e2e/repo-yaml/MODULE.bazel new file mode 100644 index 00000000..1fc34e95 --- /dev/null +++ b/e2e/repo-yaml/MODULE.bazel @@ -0,0 +1,9 @@ +"example MODULE.bazel to test repo.yaml initialization" + +module(name = "repo-yaml") + +bazel_dep(name = "bazeldnf") +local_path_override( + module_name = "bazeldnf", + path = "../..", +) diff --git a/go.mod b/go.mod index 9c417d7e..4e0ee8a7 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/rmohr/bazeldnf -go 1.23.0 +go 1.24.0 toolchain go1.24.1 @@ -12,12 +12,12 @@ require ( github.com/sassoftware/go-rpmutils v0.2.0 github.com/sirupsen/logrus v1.9.3 github.com/spf13/cobra v1.9.1 - golang.org/x/crypto v0.36.0 + golang.org/x/crypto v0.39.0 sigs.k8s.io/yaml v1.4.0 ) require ( - github.com/bazelbuild/rules_go v0.59.0 + github.com/bazelbuild/rules_go v0.60.0 github.com/jdx/go-netrc v1.0.0 ) @@ -30,29 +30,30 @@ require ( github.com/gogo/protobuf v1.3.2 // indirect github.com/golang/mock v1.7.0-rc.1 // indirect github.com/segmentio/fasthash v1.0.3 // indirect - golang.org/x/mod v0.24.0 // indirect - golang.org/x/sync v0.12.0 // indirect - golang.org/x/tools v0.31.0 // indirect + golang.org/x/mod v0.25.0 // indirect + golang.org/x/sync v0.15.0 // indirect + golang.org/x/tools v0.34.0 // indirect google.golang.org/genproto v0.0.0-20250115164207-1a7da9e5054f // indirect - google.golang.org/genproto/googleapis/rpc v0.0.0-20250106144421-5f5ef82da422 // indirect - google.golang.org/grpc v1.67.3 // indirect + google.golang.org/genproto/googleapis/bytestream v0.0.0-20251124214823-79d6a2a48846 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20250313205543-e70fdf4c4cb4 // indirect + google.golang.org/grpc v1.71.0 // indirect google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.5.1 // indirect ) require ( github.com/adrg/xdg v0.5.3 github.com/golang/protobuf v1.5.4 // indirect - github.com/google/go-cmp v0.6.0 // indirect + github.com/google/go-cmp v0.7.0 // indirect github.com/hashicorp/go-cleanhttp v0.5.2 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/klauspost/compress v1.18.0 github.com/spf13/pflag v1.0.6 // indirect github.com/xi2/xz v0.0.0-20171230120015-48954b6210f8 // indirect golang.org/x/exp v0.0.0-20250305212735-054e65f0b394 - golang.org/x/net v0.37.0 // indirect - golang.org/x/sys v0.31.0 // indirect - golang.org/x/text v0.23.0 // indirect - google.golang.org/protobuf v1.36.3 // indirect + golang.org/x/net v0.41.0 // indirect + golang.org/x/sys v0.33.0 // indirect + golang.org/x/text v0.26.0 // indirect + google.golang.org/protobuf v1.36.10 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect ) diff --git a/go.sum b/go.sum index c16a642c..44514b2c 100644 --- a/go.sum +++ b/go.sum @@ -8,6 +8,8 @@ github.com/bazelbuild/rules_go v0.53.0 h1:u160DT+RRb+Xb2aSO4piN8xhs4aZvWz2UDXCq4 github.com/bazelbuild/rules_go v0.53.0/go.mod h1:xB1jfsYHWlnZyPPxzlOSst4q2ZAwS251Mp9Iw6TPuBc= github.com/bazelbuild/rules_go v0.59.0 h1:RLhOwYIqeMgBpKelHEWTfIPjA37so3oa/rX+/qqq/P4= github.com/bazelbuild/rules_go v0.59.0/go.mod h1:Pn30cb4M513fe2rQ6GiJ3q8QyrRsgC7zhuDvi50Lw4Y= +github.com/bazelbuild/rules_go v0.60.0 h1:apGSxTTrFUyLNvX9NQmF4CbntWAO0/S5eALeVgB/6Qk= +github.com/bazelbuild/rules_go v0.60.0/go.mod h1:CYcohJVxs4n7eftbC39GCqaEJm3E1EME+6QAkGguKoI= github.com/cpuguy83/go-md2man/v2 v2.0.6/go.mod h1:oOW0eioCTA6cOiMLiUPZOpcVxMig6NIQQ7OS05n1F4g= github.com/crillab/gophersat v1.4.0 h1:irf9ajKmNnEURjgPU4oz+ouqIXXLQ59ZNd3NC+hULMc= github.com/crillab/gophersat v1.4.0/go.mod h1:gDzeMEBrqJR20IL9JW25tFHNGLU5+GDeJzr0zpi3mxs= @@ -29,6 +31,7 @@ github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6 github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +github.com/google/go-cmp v0.7.0/go.mod h1:pXiqmnSA92OHEEa9HXL2W4E7lf9JzCmGVUdgjX3N/iU= github.com/google/pprof v0.0.0-20241210010833-40e02aabc2ad h1:a6HEuzUHeKH6hwfN/ZoQgRgVIWFJljSWa/zetS2WTvg= github.com/google/pprof v0.0.0-20241210010833-40e02aabc2ad/go.mod h1:vavhavw2zAxS5dIdcRluK6cSGGPlZynqzFM8NdvU144= github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9neXJWAZQ= @@ -90,6 +93,8 @@ golang.org/x/crypto v0.0.0-20200604202706-70a84ac30bf9/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.36.0 h1:AnAEvhDddvBdpY+uR+MyHmuZzzNqXSe/GvuDeob5L34= golang.org/x/crypto v0.36.0/go.mod h1:Y4J0ReaxCR1IMaabaSMugxJES1EpwhBHhv2bDHklZvc= +golang.org/x/crypto v0.39.0 h1:SHs+kF4LP+f+p14esP5jAoDpHU8Gu/v9lFRK6IT5imM= +golang.org/x/crypto v0.39.0/go.mod h1:L+Xg3Wf6HoL4Bn4238Z6ft6KfEpN0tJGo53AAPC632U= golang.org/x/exp v0.0.0-20250305212735-054e65f0b394 h1:nDVHiLt8aIbd/VzvPWN6kSOPE7+F/fNFDSXLVYkE/Iw= golang.org/x/exp v0.0.0-20250305212735-054e65f0b394/go.mod h1:sIifuuw/Yco/y6yb6+bDNfyeQ/MdPUy/hKEMYQV17cM= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= @@ -97,6 +102,8 @@ golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.5.1/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro= golang.org/x/mod v0.24.0 h1:ZfthKaKaT4NrhGVZHO1/WDTwGES4De8KtWO0SIbNJMU= golang.org/x/mod v0.24.0/go.mod h1:IXM97Txy2VM4PJ3gI61r1YEk/gAj6zAHN3AdZt6S9Ww= +golang.org/x/mod v0.25.0 h1:n7a+ZbQKQA/Ysbyb0/6IbB1H/X41mKgbhfv7AfG/44w= +golang.org/x/mod v0.25.0/go.mod h1:IXM97Txy2VM4PJ3gI61r1YEk/gAj6zAHN3AdZt6S9Ww= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -104,12 +111,16 @@ golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwY golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.37.0 h1:1zLorHbz+LYj7MQlSf1+2tPIIgibq2eL5xkrGk6f+2c= golang.org/x/net v0.37.0/go.mod h1:ivrbrMbzFq5J41QOQh0siUuly180yBYtLp+CKbEaFx8= +golang.org/x/net v0.41.0 h1:vBTly1HeNPEn3wtREYfy4GZ/NECgw2Cnl+nK6Nz3uvw= +golang.org/x/net v0.41.0/go.mod h1:B/K4NNqkfmg07DQYrbwvSluqCJOOXwUjeb/5lOisjbA= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.12.0 h1:MHc5BpPuC30uJk597Ri8TV3CNZcTLu6B6z4lJy+g6Jw= golang.org/x/sync v0.12.0/go.mod h1:1dzgHSNfp02xaA81J2MS99Qcpr2w7fw1gpm99rleRqA= +golang.org/x/sync v0.15.0 h1:KWH3jNZsfyT6xfAfKiz6MRNmd46ByHDYaZ7KSkCtdW8= +golang.org/x/sync v0.15.0/go.mod h1:1dzgHSNfp02xaA81J2MS99Qcpr2w7fw1gpm99rleRqA= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -119,6 +130,8 @@ golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.31.0 h1:ioabZlmFYtWhL+TRYpcnNlLwhyxaM9kWTDEmfnprqik= golang.org/x/sys v0.31.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k= +golang.org/x/sys v0.33.0 h1:q3i8TbbEz+JRD9ywIRlyRAQbM0qF7hu24q3teo2hbuw= +golang.org/x/sys v0.33.0/go.mod h1:BJP2sWEmIv4KK5OTEluFJCKSidICx8ciO85XgH3Ak8k= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= @@ -126,6 +139,8 @@ golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= golang.org/x/text v0.23.0 h1:D71I7dUrlY+VX0gQShAThNGHFxZ13dGLBHQLVl1mJlY= golang.org/x/text v0.23.0/go.mod h1:/BLNzu4aZCJ1+kcD0DNRotWKage4q2rGVAg4o22unh4= +golang.org/x/text v0.26.0 h1:P42AVeLghgTYr4+xUnTRKDMqpar+PtX7KWuNQL21L8M= +golang.org/x/text v0.26.0/go.mod h1:QK15LZJUUQVJxhz7wXgxSy/CJaTFjd0G+YLonydOVQA= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= @@ -133,20 +148,30 @@ golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4f golang.org/x/tools v0.1.8/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU= golang.org/x/tools v0.31.0 h1:0EedkvKDbh+qistFTd0Bcwe/YLh4vHwWEkiI0toFIBU= golang.org/x/tools v0.31.0/go.mod h1:naFTU+Cev749tSJRXJlna0T3WxKvb1kWEx15xA4SdmQ= +golang.org/x/tools v0.34.0 h1:qIpSLOxeCYGg9TrcJokLBG4KFA6d795g0xkBkiESGlo= +golang.org/x/tools v0.34.0/go.mod h1:pAP9OwEaY1CAW3HOmg3hLZC5Z0CCmzjAF2UQMSqNARg= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= google.golang.org/genproto v0.0.0-20250115164207-1a7da9e5054f h1:387Y+JbxF52bmesc8kq1NyYIp33dnxCw6eiA7JMsTmw= google.golang.org/genproto v0.0.0-20250115164207-1a7da9e5054f/go.mod h1:0joYwWwLQh18AOj8zMYeZLjzuqcYTU3/nC5JdCvC3JI= +google.golang.org/genproto/googleapis/bytestream v0.0.0-20251124214823-79d6a2a48846 h1:7FlucM2tFADtEDnIlDrR12KdRqV48B1GSTU1U6uKSiY= +google.golang.org/genproto/googleapis/bytestream v0.0.0-20251124214823-79d6a2a48846/go.mod h1:G3Q0qS3k/oFEmVMddPsSYcFnm2+Mq2XRmxujrtu5hr0= google.golang.org/genproto/googleapis/rpc v0.0.0-20250106144421-5f5ef82da422 h1:3UsHvIr4Wc2aW4brOaSCmcxh9ksica6fHEr8P1XhkYw= google.golang.org/genproto/googleapis/rpc v0.0.0-20250106144421-5f5ef82da422/go.mod h1:3ENsm/5D1mzDyhpzeRi1NR784I0BcofWBoSc5QqqMK4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20250313205543-e70fdf4c4cb4 h1:iK2jbkWL86DXjEx0qiHcRE9dE4/Ahua5k6V8OWFb//c= +google.golang.org/genproto/googleapis/rpc v0.0.0-20250313205543-e70fdf4c4cb4/go.mod h1:LuRYeWDFV6WOn90g357N17oMCaxpgCnbi/44qJvDn2I= google.golang.org/grpc v1.67.3 h1:OgPcDAFKHnH8X3O4WcO4XUc8GRDeKsKReqbQtiCj7N8= google.golang.org/grpc v1.67.3/go.mod h1:YGaHCc6Oap+FzBJTZLBzkGSYt/cvGPFTPxkn7QfSU8s= +google.golang.org/grpc v1.71.0 h1:kF77BGdPTQ4/JZWMlb9VpJ5pa25aqvVqogsxNHHdeBg= +google.golang.org/grpc v1.71.0/go.mod h1:H0GRtasmQOh9LkFoCPDu3ZrwUtD1YGE+b2vYBYd/8Ec= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.5.1 h1:F29+wU6Ee6qgu9TddPgooOdaqsxTMunOoj8KA5yuS5A= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.5.1/go.mod h1:5KF+wpkbTSbGcR9zteSqZV6fqFOWBl4Yde8En8MryZA= google.golang.org/protobuf v1.36.3 h1:82DV7MYdb8anAVi3qge1wSnMDrnKK7ebr+I0hHRN1BU= google.golang.org/protobuf v1.36.3/go.mod h1:9fA7Ob0pmnwhb644+1+CVWFRbNajQ6iRojtC/QF5bRE= +google.golang.org/protobuf v1.36.10 h1:AYd7cD/uASjIL6Q9LiTjz8JLcrh/88q5UObnmY3aOOE= +google.golang.org/protobuf v1.36.10/go.mod h1:HTf+CrKn2C3g5S8VImy6tdcUvCska2kB7j23XfzDpco= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= diff --git a/internal/BUILD.bazel b/internal/BUILD.bazel index 815a82a5..0908abbe 100644 --- a/internal/BUILD.bazel +++ b/internal/BUILD.bazel @@ -1,5 +1,11 @@ load("@bazel_lib//:bzl_library.bzl", "bzl_library") +filegroup( + name = "all_files", + srcs = glob(["**"]), + visibility = ["//:__pkg__"], +) + exports_files(["runner.bash.template"]) bzl_library( diff --git a/internal/rpm.bzl b/internal/rpm.bzl index 9ef4fe86..d22fca10 100644 --- a/internal/rpm.bzl +++ b/internal/rpm.bzl @@ -49,60 +49,105 @@ def _rpm_rule_impl(ctx): for dep in ctx.attr.deps: deps_list.append(dep[RpmInfo].deps) + files = [ctx.file.file] if ctx.file.file else [] + rpm_info = RpmInfo( file = ctx.file.file, - deps = depset(direct = [ctx.file.file], transitive = deps_list), + deps = depset(direct = files, transitive = deps_list), ) return [ rpm_info, DefaultInfo( - files = depset(direct = [ctx.file.file], transitive = deps_list), + files = depset(direct = files, transitive = deps_list), ), ] rpm_rule = rule( implementation = _rpm_rule_impl, attrs = { - "file": attr.label(allow_single_file = True, mandatory = True), + "file": attr.label(allow_single_file = True), "deps": attr.label_list(providers = [RpmInfo]), }, ) -_HTTP_FILE_BUILD = """ +_HTTP_FILE_LEGACY_MODE = """ load("@bazeldnf//internal:rpm.bzl", "rpm_rule") package(default_visibility = ["//visibility:public"]) rpm_rule( name = "rpm", + deps = [{deps}], file = "{downloaded_file_path}", +) + +""" + +_HTTP_FILE_BUILD_NO_BLOB = """ +load("@bazeldnf//internal:rpm.bzl", "rpm_rule") +package(default_visibility = ["//visibility:public"]) +rpm_rule( + name = "rpm", deps = [{deps}], ) """ +_HTTP_FILE_BUILD_WITH_BLOB = """ +load("@bazeldnf//internal:rpm.bzl", "rpm_rule") +package(default_visibility = ["//visibility:public"]) +rpm_rule( + name = "blob", + deps = [], + file = "{downloaded_file_path}", +) +""" + def _rpm_impl(ctx): + args = {} + if ctx.attr.urls: downloaded_file_path = ctx.attr.urls[0].split("/")[-1] - args = {} + + target_path = "blob/" if ctx.attr.blob_mode and ctx.attr.create_blob else "rpm/" + if ctx.attr.integrity: args["integrity"] = ctx.attr.integrity if ctx.attr.sha256: args["sha256"] = ctx.attr.sha256 ctx.download( url = ctx.attr.urls, - output = "rpm/" + downloaded_file_path, + output = target_path + downloaded_file_path, auth = _get_auth(ctx, ctx.attr.urls), **args ) - else: + if ctx.attr.blob_mode and ctx.attr.create_blob: # actual blob when in blob mode + ctx.file( + "blob/BUILD", + _HTTP_FILE_BUILD_WITH_BLOB.format( + downloaded_file_path = downloaded_file_path, + ), + ) + + elif not ctx.attr.blob_mode or ctx.attr.create_blob: fail("urls must be specified") + ctx.file("WORKSPACE", "workspace(name = \"{name}\")".format(name = ctx.name)) - ctx.file( - "rpm/BUILD", - _HTTP_FILE_BUILD.format( - downloaded_file_path = downloaded_file_path, - deps = ", ".join(["\"%s\"" % dep for dep in ctx.attr.dependencies]), - ), - ) + + if ctx.attr.blob_mode and not ctx.attr.create_blob: # publicly available rpm on new blob mode + ctx.file( + "rpm/BUILD", + _HTTP_FILE_BUILD_NO_BLOB.format( + deps = ", ".join(["\"%s\"" % dep for dep in ctx.attr.dependencies]), + ), + ) + elif not ctx.attr.blob_mode: # legacy mode + ctx.file( + "rpm/BUILD", + _HTTP_FILE_LEGACY_MODE.format( + deps = ", ".join(["\"%s\"" % dep for dep in ctx.attr.dependencies]), + downloaded_file_path = ctx.attr.urls[0].split("/")[-1], + ), + ) + return update_attrs(ctx.attr, _rpm_attrs.keys(), args) _rpm_attrs = { @@ -114,6 +159,8 @@ _rpm_attrs = { providers = [RpmInfo], ), "auth_patterns": attr.string_dict(), + "blob_mode": attr.bool(default = False), + "create_blob": attr.bool(), } rpm = repository_rule( diff --git a/tools/BUILD.bazel b/tools/BUILD.bazel index 7eadf2aa..d67c7fc4 100644 --- a/tools/BUILD.bazel +++ b/tools/BUILD.bazel @@ -1,5 +1,11 @@ load("@bazel_lib//:bzl_library.bzl", "bzl_library") +filegroup( + name = "all_files", + srcs = glob(["**"]), + visibility = ["//:__pkg__"], +) + bzl_library( name = "integrity", srcs = ["integrity.bzl"], diff --git a/tools/e2e/BUILD.bazel b/tools/e2e/BUILD.bazel new file mode 100644 index 00000000..89476332 --- /dev/null +++ b/tools/e2e/BUILD.bazel @@ -0,0 +1,44 @@ +"Create a toolchain tar archive we can pass as input to the e2e tests" + +load("@aspect_bazel_lib//lib:copy_file.bzl", "copy_file") + +# copy the binary into our target folder +copy_file( + name = "binary-non-win", + src = "//cmd", + out = "output/cmd", + is_executable = True, +) + +copy_file( + name = "binary-win", + src = "//cmd", + out = "output/cmd.exe", + is_executable = True, + target_compatible_with = [ + "@platforms//os:windows", + ], +) + +alias( + name = "binary", + actual = select({ + "@platforms//os:windows": ":binary-win", + "//conditions:default": "binary-non-win", + }), +) + +copy_file( + name = "toolchain-build", + src = "toolchain.BUILD.bazel", + out = "output/BUILD.bazel", +) + +filegroup( + name = "toolchain", + srcs = [ + ":binary", + ":toolchain-build", + ], + visibility = ["//:__pkg__"], +) diff --git a/tools/e2e/toolchain.BUILD.bazel b/tools/e2e/toolchain.BUILD.bazel new file mode 100644 index 00000000..a98ee460 --- /dev/null +++ b/tools/e2e/toolchain.BUILD.bazel @@ -0,0 +1,22 @@ +"Fake BUILD.bazel we will have in the prebuilt toolchain" + +load("@bazeldnf//bazeldnf:toolchain.bzl", "bazeldnf_toolchain") + +alias( + name = "cmd.binary", + actual = select({ + "@platforms//os:windows": "cmd.exe", + "//conditions:default": "cmd", + }), +) + +bazeldnf_toolchain( + name = "bazeldnf_toolchain", + tool = ":cmd.binary", +) + +toolchain( + name = "toolchain", + toolchain = ":bazeldnf_toolchain", + toolchain_type = "@bazeldnf//bazeldnf:toolchain_type", +)