Skip to content

Conversation

jasonjoh
Copy link
Member

The old validator orrosenblatt/validate-json-action hasn't been updated since 2019 and was using deprecated tech. For example, https://github.com/microsoftgraph/microsoft-graph-devx-content/actions/runs/17332688629:

The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/

Updating to dsanders11/json-schema-validate-action gives the following advantages:

  • It detected a syntax error in the schema itself that the old validator didn't catch: strict mode: "items" is 1-tuple, but minItems or maxItems/additionalItems are not specified or different at path "#/properties/SampleQueries/items/properties/headers"
  • It fails validation when properties are repeated, which fixes Investigate schema validation to prevent multiple entries of the same property.  #408
  • It is (at least for now) being actively maintained

@Copilot Copilot AI review requested due to automatic review settings August 29, 2025 19:54
@jasonjoh jasonjoh requested a review from a team as a code owner August 29, 2025 19:54
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates the JSON validation workflow by replacing the deprecated orrosenblatt/validate-json-action with dsanders11/json-schema-validate-action and fixes schema syntax issues that the new validator detected.

  • Replaced deprecated JSON validation action with actively maintained alternative
  • Fixed JSON schema syntax by converting tuple-based item definitions to object-based definitions
  • Updated GitHub Actions checkout versions and added workflow dispatch trigger

Reviewed Changes

Copilot reviewed 2 out of 3 changed files in this pull request and generated no comments.

File Description
.github/workflows/validate.yml Replaced deprecated JSON validator action and updated checkout versions
tests/samples.schema.json Fixed schema syntax by converting tuple-based items to object-based and added schema version

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

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

Successfully merging this pull request may close these issues.

Investigate schema validation to prevent multiple entries of the same property.

1 participant