"is_default" is not unique per species
まだ誰も着手していません。
評価
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 初心者へのやさしさ
- 35/100
- issue の種類
- 機能追加
- 明瞭さ
- おおむね明確
- 活発さ
- 静か
- 技術スタック
- python
調査の方向性
まず PokemonForm のドキュメントと issue で参照されている pokemon.csv データを確認し、次に API が is_default と form_order をどのように公開しているかを追ってください。置換ルールを決める前に、既存のコメントを確認してください。現在のフィールドのセマンティクスを曖昧なままにせず、プライマリフォームの動作について合意し、実装し、ドキュメント化できれば完了です。
索引モデルが issue の本文から書いたものです。
説明
The PokemonForm documentation describes is_default as
True for exactly one form used as the default for each Pokémon.
Of the 249 Pokémon with more than one form in pokemon.csv, 222 of them have more than one form with is_default set to True.
While the easiest fix would just be to purge these secondary is_default forms, I think that field should just be deprecated and replaced with a different method of determining the primary form. I have to imagine this field is not widely used by API consumers, as it would not work for its documented purpose.
My preferred design would be to simply have the form of the species with the first form ID be the primary form. It looks like there isn't strictly a form_id field, but it roughly corresponds to the form_order field. So my suggestion would be to just define that the form of the Pokémon with the smallest value in form_order is considered the default form.
- 主要言語
- Python
- スター
- 5.4k
- フォーク
- 1.2k
- 平均マージ
- 2日 12時間
- マージ済み PR(30日)
- 18
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
PokeAPI/pokeapi のほかの issue
-
難易度 2/5 1〜2日 初心者へのやさしさ 76/100
-
bug
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
-
難易度 3/5 1〜2日 初心者へのやさしさ 55/100
-
UV hardlink files オープン
難易度 3/5 1〜2日 初心者へのやさしさ 48/100
-
Ball legality オープン
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
PokeAPI/pokeapi の issue をすべて見る
似ている issue
-
bug priority:low
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
CyberAgent/psd2svg#436 ·
-
area/install-update comp/cli comp/desktop P3 sweeper:risk-compatibility type/bug
難易度 2/5 1〜3時間 初心者へのやさしさ 86/100
NousResearch/hermes-agent#122386 · コメント 1 件 ·
-
ai-generated
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
vllm-project/production-stack#1105 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 88/100