OpenAPITools / OpenAPITools/openapi-diff

allOf : `type` of property contained in multiple subschemas is not correctly determined.

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

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

主要言語
Java
スター
1.1k
フォーク
190
PR マージ指標
30日以内にマージされた PR はありません

説明

Given the following schema V1:

Foo:
  allOf:
    - properties:
        propA:
          type: string
    - properties:
        propA:
          example: "YEEHAA"

is changed to the following schema V2:

Foo:  
  properties:
    propA:
      type: string

openapi-diff incorrectly detects the following incompatible change:
Changed property type (object -> string)

It seems to me that the type of a property that is contained in multiple subschemas of an allOf is not correctly determined. Openapi-diff recognized the type of propA in schema V1 as an object, but this is not correct.

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

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

はじめの一歩

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

調査の方向性

まず、提供された V1 と V2 のスキーマ間の比較を再現し、Foo、allOf、繰り返されている propA の定義に焦点を当てます。diff がすべての allOf サブスキーマにわたって propA の型をどのように決定しているかを調べます。このケースについて、比較結果で object から string への互換性のない型変更が報告されなくなれば完了です。

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

評価

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

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

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