[Feat] grass.temporal: share one id helper between maps and space-time datasets
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
調査の方向性
Start by reading AbstractMapDataset.build_id() and split_name(), then locate the 17 duplicated id expressions across the nine grass.temporal and t.* files mentioned in the issue. Move the helpers to grass.temporal.utils, retain the map class methods as wrappers, and update the copies. The issue leaves open whether _parse_id() belongs there, so clarify that design choice before considering the refactor complete.
索引モデルが issue の本文から書いたものです。
説明
Is your feature request related to a problem? Please describe.
@ninsbl suggested on #7739 a public helper for STDS ids, maybe in a temporal utils module. Looking into it, x if x.find("@") >= 0 else x + "@" + mapset is copied 17 times across 9 files in grass.temporal and the t.* tools. AbstractMapDataset.build_id(x, mapset) already does the same thing (I checked it gives the same id for name, name@mapset, name.label and name:layer), but it sits on the map class, and 14 of the 17 copies are for space-time datasets.
Describe the solution you'd like
Move split_name() and build_id() to a new grass.temporal.utils as plain functions, keep the AbstractMapDataset methods as wrappers, and switch the copies over.
Describe alternatives you've considered
Calling AbstractMapDataset.build_id() from the space-time dataset code as it is. That works, it just reads a bit odd.
Additional context
Does this match what you had in mind? And should _parse_id() from open_stds.py go there too, or stay where it is because of the semantic labels?
- 主要言語
- C
- スター
- 1.2k
- フォーク
- 447
- 平均マージ
- 2日 10時間
- マージ済み PR(30日)
- 86
環境構築
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
OSGeo/grass のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
メンテナーはふだん 1 日以内に返信
-
[Bug] v.db.addtable expands $MAP only when it is a directory対応中かも @alteralto が 35 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
[Bug] grass.pygrass: Cats.delete(0) deletes all layer categories instead of category 0対応中かも @Mohit-Ak が 40 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
[Bug] macOS: Startup crashes with StopIteration when ~/Documents is not readable (macOS privacy protection)対応中かも @NIne-WIngEd が 46 日前に担当しました。 オープンbug
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
[Bug] Specify the test project name対応中かも @Om23131212 が 39 日前に担当しました。 オープンbug
難易度 1/5 1時間未満 初心者へのやさしさ 65/100
メンテナーはふだん 1 日以内に返信
似ている issue
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
leanprover/lean4#16892 ·
メンテナーはふだん 1 日以内に返信
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
メンテナーはふだん 2 日以内に返信
-
難易度 1/5 1〜3時間 初心者へのやさしさ 68/100
Revivedx/SavageWindRecomp#1358 ·
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
389ds/389-ds-base#8196 ·
メンテナーはふだん 2 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 79/100
libsdl-org/SDL#16860 ·
メンテナーはふだん 1 日以内に返信