Liturgical-Calendar / LiturgicalCalendarAPI

A PHP script / API endpoint that will generate the Roman Catholic liturgical calendar for any given year, calculating the mobile festivities and the precedence of solemnities, feasts, memorials...
Apache License 2.0
35 stars 9 forks source link

The redocly linter in VSCode doesn't like the LitCalAllFestivities example #213

Closed JohnRDOrazio closed 3 weeks ago

JohnRDOrazio commented 1 month ago

What happened?

Seeing that the 42Crunch vscode extension doesn't support OpenAPI 3.1 while the Redocly extension does seem to have support, I decided to try out the Redocly extension. This linter pointed out that Assertions was not defined as an array but as an object, so I caught that. However it still doesn't like the example for the LitCalTestsIndex endpoint. The objects in the response array can be one of three different types and we define this with an anyOf; also the Assertions can have two different flavors accordingly, so this array has an anyOf for the two possible objects that the items can correspond to. But the linter is complaining that the fields required are missing. This doesn't really make sense, because they are required differently according to the different anyOf possible objects. I'm guessing this is a bug in Redoc, and we should probably create an issue on their repo...

Version

dev (Edge)

Which browser or browsers are you seeing the problem on? (can select more than one, or N/A if not applicable)

No response

Relevant error messages

No response

JohnRDOrazio commented 3 weeks ago

this was fixed in commit fde4535921fb054ea3d147bceea715efc729a07f