Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

filter_breaks_to_range cannot filter temporal breaks, so out-of-domain ticks survive

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

まだ誰も着手していません。

評価

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

調査の方向性

src/plot/scale/breaks.rs の 292 行目あたりにある filter_breaks_to_range から始め、minor-breaks の経路での ArrayElement::to_f64() の使用と数値処理を比較してください。解決済みのドメイン外にある時間的な breaks が削除され、数値への射影を持たない値については現在の pass-through 動作が維持されれば完了です。issue の Date scale の再現で確認してください。

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

説明

bug plot building

This issue was surfaced during the Hephaestus writer work

Summary

filter_breaks_to_range (src/plot/scale/breaks.rs:292) returns the break list unchanged unless both range endpoints are ArrayElement::Number, and inside the predicate it explicitly keeps any break that is not a Number. A Date / DateTime / Time scale therefore never gets filtered: a calendar-aligned major computed outside the resolved domain survives, and both writers place a tick off-panel.

Reproduction
VISUALISE Date AS x, Temp AS y FROM ggsql:airquality
DRAW line
SCALE x SETTING breaks => '2 months'
domain: ['1973-04-23', '1973-10-07']
values: ['1973-04-01', '1973-06-01', '1973-08-01', '1973-10-01', '1973-12-01']

1973-04-01 and 1973-12-01 are both outside the resolved domain.

Suggested fix

Filter on ArrayElement::to_f64() for the range endpoints and the breaks alike — which is exactly what the minor breaks path already does — falling back to the current pass-through only when a value has no numeric projection.

主要言語
Rust
スター
554
フォーク
30
平均マージ
2日 5時間
マージ済み PR(30日)
15

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

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

posit-dev/ggsql のほかの issue

posit-dev/ggsql の issue をすべて見る

似ている issue

Rust の issue をもっと見る

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

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