Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Array input examples ignore global fill-request-fields-with-example setting #1003

Open
brunchboy opened this issue Mar 21, 2024 · 1 comment

Comments

@brunchboy
Copy link

We have configured fill-request-fields-with-example="false", and this works for most of our properties. However, any that are type array still get the examples filled in. I noticed there was a similar fix already merged for the per-property x-fill-example setting, see #776; hopefully fixing this is as simple as adding the global check to the same place?

@brunchboy
Copy link
Author

brunchboy commented Mar 22, 2024

Actually, this is a deeper problem. Looking at the code for that fix it is already trying to honor the global setting. And in fact, even when we set x-fill-example to "no" on a specific array property, it still gets filled in. So the fix does not work at all. Here is an example of such a property that is getting filled in inappropriately Rapidoc for our spec:

          "areaOfInterestIds": {
            "description": "The `id`s of the Areas of Interest to which notifications based on this template should be sent",
            "example": [
              "8145ebd1-7a8b-11ee-bc97-098b09a637c2"
            ],
            "items": {
              "format": "uuid",
              "type": "string"
            },
            "type": "array",
            "uniqueItems": true,
            "x-fill-example": "no"
          },

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant