Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .asf.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ github:
- "cargo test (macos-aarch64)"
- "Verify Vendored Code"
- "Check cargo fmt"
- "Check GitHub Actions install tooling"
- "clippy"
- "check Cargo.toml formatting"
- "check configs.md and ***_functions.md is up-to-date"
Expand Down Expand Up @@ -114,4 +115,3 @@ github:
# https://datafusion.apache.org/
publish:
whoami: asf-site

4 changes: 3 additions & 1 deletion .github/workflows/dependencies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ jobs:
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Install cargo-machete
run: cargo install cargo-machete --version ^0.9 --locked
uses: taiki-e/install-action@50414676f9f5d50a65992c6dd2ed02641263226c # v2.82.10
with:
tool: cargo-machete@0.9
- name: Detect unused dependencies
run: cargo machete --with-metadata
11 changes: 7 additions & 4 deletions .github/workflows/dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,9 @@ jobs:
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Install HawkEye
# This CI job is bound by installation time, use `--profile dev` to speed it up
run: cargo install hawkeye --version 6.2.0 --locked --profile dev
uses: taiki-e/install-action@50414676f9f5d50a65992c6dd2ed02641263226c # v2.82.10
with:
tool: hawkeye@6.2.0
- name: Run license header check
run: ci/scripts/license_header.sh

Expand Down Expand Up @@ -89,7 +90,9 @@ jobs:
# Version fixed on purpose. It uses heuristics to detect typos, so upgrading
# it may cause checks to fail more often.
# We can upgrade it manually once a while.
- name: Install typos-cli
run: cargo install typos-cli --locked --version 1.37.0
- name: Install typos
uses: taiki-e/install-action@50414676f9f5d50a65992c6dd2ed02641263226c # v2.82.10
with:
tool: typos@1.37.0
- name: Run typos check
run: ci/scripts/typos_check.sh
7 changes: 5 additions & 2 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,15 @@ jobs:

- name: Install dependencies
run: uv sync --package datafusion-docs
- name: Install dependency graph tooling
- name: Install Graphviz
run: |
set -x
sudo apt-get update
sudo apt-get install -y graphviz
cargo install cargo-depgraph --version ^1.6 --locked
- name: Install cargo-depgraph
uses: taiki-e/install-action@50414676f9f5d50a65992c6dd2ed02641263226c # v2.82.10
with:
tool: cargo-depgraph@1.6

- name: Build docs
run: |
Expand Down
7 changes: 5 additions & 2 deletions .github/workflows/docs_pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -53,12 +53,15 @@ jobs:
uses: astral-sh/setup-uv@f98e06938123ccabd21905ea5d0069192241f9f1 # v8.3.1
- name: Install doc dependencies
run: uv sync --package datafusion-docs
- name: Install dependency graph tooling
- name: Install Graphviz
run: |
set -x
sudo apt-get update
sudo apt-get install -y graphviz
cargo install cargo-depgraph --version ^1.6 --locked
- name: Install cargo-depgraph
uses: taiki-e/install-action@50414676f9f5d50a65992c6dd2ed02641263226c # v2.82.10
with:
tool: cargo-depgraph@1.6
- name: Build docs html and check for warnings
run: |
set -x
Expand Down
13 changes: 12 additions & 1 deletion .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -628,6 +628,14 @@ jobs:
run: |
ci/scripts/rust_fmt.sh
check-workflow-tool-installs:
name: Check GitHub Actions install tooling
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
- name: Check workflow tool installs
run: ci/scripts/check_no_cargo_install_in_workflows.sh

# Coverage job disabled due to
# https://github.com/apache/datafusion/issues/3678

Expand Down Expand Up @@ -659,12 +667,15 @@ jobs:
# path: /home/runner/.cargo
# # this key is not equal because the user is different than on a container (runner vs github)
# key: cargo-coverage-cache3-
# - name: Install cargo-tarpaulin
# uses: taiki-e/install-action@50414676f9f5d50a65992c6dd2ed02641263226c # v2.82.10
# with:
# tool: cargo-tarpaulin@0.20.1
# - name: Run coverage
# run: |
# export PATH=$PATH:$HOME/d/protoc/bin
# rustup toolchain install stable
# rustup default stable
# cargo install --version 0.20.1 cargo-tarpaulin
# cargo tarpaulin --all --out Xml
# - name: Report coverage
# continue-on-error: true
Expand Down
30 changes: 30 additions & 0 deletions ci/scripts/check_no_cargo_install_in_workflows.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
#!/usr/bin/env bash
#
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.

set -euo pipefail

SCRIPT_NAME="$(basename "${BASH_SOURCE[0]}")"
WORKFLOWS_DIR=".github/workflows"

if grep -R -n --include='*.yml' --include='*.yaml' -- 'cargo install' "${WORKFLOWS_DIR}"; then
echo "[${SCRIPT_NAME}] Found workflow Rust tool installs that should use taiki-e/install-action instead." >&2
exit 1
fi

echo "[${SCRIPT_NAME}] GitHub Actions workflow tool installs look good."
1 change: 1 addition & 0 deletions dev/rust_lint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ declare -a WRITE_STEPS=(
)

declare -a READONLY_STEPS=(
"ci/scripts/check_no_cargo_install_in_workflows.sh|false"
"ci/scripts/rust_docs.sh|false"
)

Expand Down
Loading