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

Add a `crossplane xrd lint` command

オープン
#69 コメント 9 件 リアクション 8 件 担当者 0 名 GitHub で見る

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

  • #6385 @undefinedhuman による — マージされずにクローズ

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
25/100
issue の種類
機能追加
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
go, kubernetes, openapi

調査の方向性

crossplane xrd lint コマンドから始め、その想定範囲を crossplane beta validate と比較します。リンクされている API 設計のベストプラクティスに関するドキュメントを確認し、status の要件、配列名、ブール型 enum、merge 拡張、フィールドの説明を含め、どの XRD チェックを対象範囲とするかを判断します。合意したチェックについて、コマンドが対応可能な lint 指摘を報告すれば完了です。

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

説明

enhancement
What problem are you facing?

https://github.com/crossplane/docs/issues/564 tracks documenting best practices for API design. Put otherwise, best practices for writing XRDs. It occurred to me today that we could probably write a linter for a lot of these.

It could make sense for this to be part of crossplane beta validate too, but I think validation and linting are slightly different things. An XRD could have a valid OpenAPI schema, but one that we wouldn't recommend.

How could Crossplane help solve your problem?

Add a linter for XRDs. Some things to look for:

  • Overly restrictive status fields. Status fields aren't written by users, so they typically shouldn't be required, or generally validated beyond their type (e.g maximum integers, etc).
  • Arrays of objects missing a name field.
  • Boolean fields, which Kubernetes API conventions would typically recommend be enums.
  • Missing server-side apply merge OpenAPI extensions where we'd expect them.
  • General OpenAPI hygiene - fields missing descriptions etc
主要言語
Go
スター
19
フォーク
31
平均マージ
2日 15時間
マージ済み PR(30日)
53

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

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

はじめの一歩

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

crossplane/cli のほかの issue

crossplane/cli の issue をすべて見る

似ている issue

Go の issue をもっと見る

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

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