[Feat]: Clarify nullability and optionality of the spec API
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
調査の方向性
spec モジュールの Task クラスと TaskStatus クラスを調査し、現在の nullability パターンを理解します。spec API の設計原則と一貫性ルールを確認します。どのフィールドを Optional にすべきか、どのコレクションをデフォルトで空にすべきかを判断します。クラスを更新し、後方互換性を確保して、Javadoc を適宜修正します。
索引モデルが issue の本文から書いたものです。
説明
Is your feature request related to a problem? Please describe.
The spec API is not consistent with this expectation for the nullability and optionality of objects.
For example, the Task class
will always instantiate its history and artifact with (potentially empty) collections while its metatada can be null.
The API should be consistent unless there is a good reason not to.
In that case, the metadata should also be an empty Map if the parameter is null.
For case where we want to record that a field can have a value or be null, we could also leverage Optional.
For example, in TaskStatus, the message is optional. We could make its type Optional<String> to constrain its contract.
Describe the solution you'd like
Update the spec API to:
- be consistent with the nullabitity of fields (especially collections)
- use the
Optionaltype for optional fields - update the javadoc when there is exception to this general rule
Describe alternatives you've considered
No response
Additional context
No response
Code of Conduct
- I agree to follow this project's Code of Conduct
- 主要言語
- Java
- スター
- 505
- フォーク
- 185
- 平均マージ
- 1日 9時間
- マージ済み PR(30日)
- 25
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
a2aproject/a2a-java のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
a2aproject/a2a-java#1012 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
a2aproject/a2a-java#464 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Create a sample that demonstrates how to use a shared contextId across multiple tasks再び着手できるかも @tanish111 が 356 日前に担当しましたが、オープン中のプルリクエストはありません。 オープンsample
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
a2aproject/a2a-java#375 · コメント 5 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 28/100
a2aproject/a2a-java#1211 ·
メンテナーはふだん 1 日以内に返信
-
難易度 3/5 1〜2日 初心者へのやさしさ 55/100
a2aproject/a2a-java#1207 ·
メンテナーはふだん 1 日以内に返信
a2aproject/a2a-java の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
-
Flight SQL JDBC parses boolean properties case-sensitively, silently disabling TLS for useEncryption=TRUE対応中かも @Arawoof06 が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 79/100
apache/arrow-java#1357 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 77/100
apache/rocketmq-dashboard#6610 ·
メンテナーはふだん 3 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
MetricsHub/metricshub-community#1396 ·
メンテナーはふだん 1 日以内に返信
-
L: java:gradle L: java:maven L: ruby:bundler T: bug 🐞
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
dependabot/dependabot-core#16547 ·
メンテナーはふだん 1 日以内に返信