Deduplicate spark_ceil and spark_floor and port floor's decimal boundary tests to ceil
メンテナーはふだん 1 日以内に返信
@med9110 がすでに取り組んでいます。
2026年10月15日 から。
評価
調査の方向性
native/spark-expr/src/math_funcs/floor.rs の境界値テスト、test_floor_decimal128_i64_boundary_array と test_floor_decimal128_large_scale_array から始め、それらを ceil.rs と比較してください。ceil.rs にはこれらがありません。両方のテストを decimal_ceil_pow10 に対して ceil.rs へ移植し、期待値は ceil 固有のものを維持してください。移植したテストが native/spark-expr で cargo test を通過すれば完了です。2つ目のステップの共有モジュールのリファクタリングは設計作業のため、メンテナーに任せてください。
索引モデルが issue の本文から書いたものです。
説明
What is the problem the feature request solves?
native/spark-expr/src/math_funcs/ceil.rs and floor.rs are the same module with ceil/floor and div_ceil/div_floor swapped. The spark_* dispatch, decimal_*_f, decimal_*_pow10::<EXP> with its i64 fast path, and the cold *_wide fallback are identical, as are the first seven tests.
The copies have already diverged in their tests. floor.rs has test_floor_decimal128_i64_boundary_array and test_floor_decimal128_large_scale_array, which exercise the i64/i128 switch and the runtime fallback. ceil.rs has neither, even though decimal_ceil_pow10 has the same boundary logic. Any future fix to the fast path has to be made twice, and today only floor's version is tested at the boundary.
Describe the potential solution
- Port floor's boundary and large-scale tests to ceil. This is the quick win and could land on its own.
- Move the shared decimal rounding into
math_funcs/utils.rs, generic over a rounding mode (e.g. a trait withCeil/Floormarker types providing the i64 and i128 division), and makespark_ceil/spark_floorthin wrappers over one generic function. Parameterise the tests by mode.
Additional context
Line references are pinned to commit 7d8d9b1544b7.
- 主要言語
- Scala
- スター
- 1.3k
- フォーク
- 391
- 平均マージ
- 2日 10時間
- マージ済み PR(30日)
- 421
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
apache/datafusion-comet のほかの issue
-
requires-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
apache/datafusion-comet#7001 ·
メンテナーはふだん 1 日以内に返信
-
Extract shared list-array construction from the split_* functions in split.rs対応中かも @arminazimi が 1 日前に担当しました。 オープンarea:expressions enhancement good first issue help wanted requires-triage rust tech debt
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
apache/datafusion-comet#6983 ·
メンテナーはふだん 1 日以内に返信
-
Iceberg data tables whose names end with a metadata-table name fall back to Spark再び着手できるかも @aryan9948 が 10 日前に担当しましたが、オープン中のプルリクエストはありません。 オープンrequires-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
apache/datafusion-comet#6719 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Native from_json with a schema that repeats a field name fails with "ArrowArray struct has 2 children (expected 1)"対応中かも @Samearth17 が 11 日前に担当しました。 オープンarea:expressions area:ffi bug good first issue priority:medium
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
apache/datafusion-comet#6592 ·
メンテナーはふだん 1 日以内に返信
-
Casting to a struct type with repeated field names fails with "ArrowArray struct has 2 children (expected 1)"対応中かも @Samearth17 が 11 日前に担当しました。 オープンarea:expressions area:ffi bug good first issue priority:high
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
apache/datafusion-comet#6591 ·
メンテナーはふだん 1 日以内に返信
apache/datafusion-comet の issue をすべて見る
似ている issue
-
agent-ready area/dev-tooling kind/docs-only layer/docs size/XS
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
marola-dev/marola#855 ·
メンテナーはふだん 1 日以内に返信
-
llm4s-ollama: bind a base-URL variable for chat sections, and align the documented variable nameオープン
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
scylladb/scylla-migrator#413 ·
-
難易度 2/5 1時間未満 初心者へのやさしさ 70/100
-
dependencies
難易度 1/5 1時間未満 初心者へのやさしさ 78/100
apache/pekko-http#1354 ·
メンテナーはふだん 1 日以内に返信