`verify-release-candidate.sh` version check doesn't catch `-dev` versions and is skipped on macOS

オープン 初心者向け
#27,563 コメント 1 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

@vinycalves がすでに取り組んでいます。

2026年11月18日 から。

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
78/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
rust, shell

調査の方向性

既存の Cargo.toml バージョンチェックの周辺にある dev/release/verify-release-candidate.sh を読み、次に GNU と BSD/macOS で issue の再現コマンドを実行します。指定された -dev と -SNAPSHOT のサフィックスを検出し、両方の find 実装で動作するようにチェックを更新します。両方のプラットフォームでプレリリース版がチェックに失敗し、リリース版が成功すれば完了です。

索引モデルが issue の本文から書いたものです。

説明

Describe the bug

verify-release-candidate.sh rejects a release whose Cargo.toml contains SNAPSHOT:

https://github.com/apache/datafusion/blob/13efc9c27d59b7fbc6503025042f14064c5fa0f7/dev/release/verify-release-candidate.sh#L153-L156

The check misses a pre-release version in two ways.

First, #26845 changed main to -dev versions (57.0.0-dev today), but the check still greps for SNAPSHOT, which no Cargo.toml has used since #1350. An RC cut with a leftover -dev version passes on every platform.

Second, the check calls find without a starting path. GNU find defaults the path to ., but BSD find on macOS requires one and exits with find: illegal option -- i. That failure happens inside the if ( ... ) condition, so set -e doesn't stop the script and the condition is false. On macOS the check passes without reading any Cargo.toml.

To Reproduce

On macOS:

$ if ( /usr/bin/find -iname 'Cargo.toml' | xargs grep SNAPSHOT ); then echo found; else echo "check passed"; fi
/usr/bin/find: illegal option -- i
check passed

On any platform, from a main checkout:

$ if ( find . -iname 'Cargo.toml' | xargs grep SNAPSHOT ); then echo found; else echo "check passed"; fi
check passed
$ grep -m1 '^version' Cargo.toml
version = "57.0.0-dev"

I found this while verifying 56.0.0-rc2. A manual grep for -dev and -SNAPSHOT versions found none in that release.

Expected behavior

The check fails for any pre-release version suffix, on both GNU and BSD find. For example:

if ( find . -name 'Cargo.toml' -print0 | xargs -0 grep -nE '^version *= *"[^"]*-(dev|SNAPSHOT)' ); then
  echo "Cargo.toml version should not have a -dev or -SNAPSHOT suffix for releases"
  exit 1
fi
主要言語
Rust
スター
9.6k
フォーク
2.6k
平均マージ
3日 5時間
マージ済み PR(30日)
352

環境構築

Codespaces で開く

このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

apache/datafusion のほかの issue

apache/datafusion の issue をすべて見る

似ている issue

Rust の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。