api: the OpenAPI document allows null on_value and off_value for a flag, which the API refuses

オープン
#1,571 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

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

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
30/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
openapi, python
領域
api

調査の方向性

Start with the FeatureFlagCreate and FeatureFlagUpdate schemas in docs/api/openapi-v1.full.json and docs/api/openapi-v1.stable.json, where on_value and off_value lack a type. Check the API's Python validation that returns null_not_allowed, and follow the #954 stability row as the format for any new entry. Done means both properties exclude null in the served document, a test pins that, and both snapshots are regenerated. The fix needs serial merge ordering and a fuzz run before merge, so confirm with maintainers first.

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

説明

bug post-launch

The served OpenAPI document leaves on_value and off_value on FeatureFlagCreate and FeatureFlagUpdate without a type, so it allows any JSON value, null included. The API refuses null for them: in a measured run, 135 of 150 flag creates that the document allows answered 422 with null_not_allowed.

Both snapshots (docs/api/openapi-v1.full.json and docs/api/openapi-v1.stable.json) carry the untyped properties since #1514, which is not yet in a release. The next release would publish them in the stable document; fixing them after that needs a stability row (the #954 row is the shape), with no behaviour change.

Expected

The document describes exactly what the API accepts for on_value and off_value, and a test pins it.

Notes

The fix changes the request side of the served document, so it is its own pull request, regenerates both snapshots (merged serially with the other snapshot pull requests) and dispatches the API fuzz run before merge.

Priority

LOW.

主要言語
Python
スター
0
フォーク
4
平均マージ
5時間 19分
マージ済み PR(30日)
503

環境構築

はじめの一歩

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

Controlvar/controlvar のほかの issue

Controlvar/controlvar の issue をすべて見る

似ている issue

Python の issue をもっと見る

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

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