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

False positives when readOnly property using referenced enum

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

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

評価

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

調査の方向性

Azure/azure-rest-api-specs-pr#15631 で説明されている比較の調査から始め、Trial モデルと参照されている TrialStatus enum を再現ケースとして使用します。diff が以前の inline enum スキーマと新しい $ref スキーマおよび readOnly 値を比較している箇所を追跡します。この同等の変更が readOnly の breaking 変更として報告されなくなれば完了です。

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

説明

Describe the bug

I'm working on https://github.com/Azure/azure-rest-api-specs-pr/pull/15631 and there are a lot of false positives with a message of `The read only property has changed from 'true' to 'false'.

image

To Reproduce
As an example from that PR:

@doc("Subscription trial availability")
model Trial {
  @doc("Trial status")
  @visibility("read")
  status?: TrialStatus;

It does produce readOnly.

        "status": {
          "$ref": "#/definitions/TrialStatus",
          "description": "Trial status",
          "readOnly": true
        },

But before it was not a $ref, it was inline:

        "status": {
          "description": "Trial status",
          "type": "string",
          "enum": [
            "TrialAvailable",
            "TrialUsed",
            "TrialDisabled"
          ],
          "readOnly": true,
          "x-ms-enum": {
            "name": "TrialStatus",
            "modelAsString": true
          }
        },

Expected behavior
It is not marked as a breaking change.

主要言語
C#
スター
290
フォーク
50
平均マージ
2日 21時間
マージ済み PR(30日)
10

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

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

はじめの一歩

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

Azure/openapi-diff のほかの issue

Azure/openapi-diff の issue をすべて見る

似ている issue

C# の issue をもっと見る

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

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