Skip to content

fix(deployment): fix schema docs annotations and guard them in CI - #7035

Open
corneliusroemer wants to merge 1 commit into
mainfrom
helm-schema-annotation-lint
Open

fix(deployment): fix schema docs annotations and guard them in CI#7035
corneliusroemer wants to merge 1 commit into
mainfrom
helm-schema-annotation-lint

Conversation

@corneliusroemer

@corneliusroemer corneliusroemer commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

The values.schema.json annotations that drive the Helm chart config reference are
custom keywords, so JSON Schema silently ignores mistakes in them. Fixes eight
group typos (the docs only read groups), the referenceGenomes group name
that no docs section renders, the doubly-nested public.properties.properties
that meant its four URL keys were never validated, and a stray
additionalProperties inside a properties map. Adds
kubernetes/utils/check_schema_annotations.py, wired into helm-schema-lint and
pre-commit, which catches all of the above.

Screenshot

Before:

Missing schema entries due to typos

Google Chrome 2026-08-05 15 12 02

🚀 Preview: Add preview label to enable

The values.schema.json annotations that drive the Helm chart config reference are
custom keywords, so JSON Schema silently ignores mistakes in them. Fixes eight
`group` typos (the docs only read `groups`), the `referenceGenomes` group name
that no docs section renders, the doubly-nested `public.properties.properties`
that meant its four URL keys were never validated, and a stray
`additionalProperties` inside a properties map. Adds
kubernetes/utils/check_schema_annotations.py, wired into helm-schema-lint and
pre-commit, which catches all of the above.
Copilot AI review requested due to automatic review settings August 5, 2026 13:16
@claude claude Bot added the deployment Code changes targetting the deployment infrastructure label Aug 5, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

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 hardens the Helm chart configuration documentation pipeline by fixing custom annotation mistakes in values.schema.json and adding a dedicated linter to fail CI/pre-commit when schema annotations or schema structure drift in ways that would silently break the rendered docs.

Changes:

  • Fixes schema annotation issues in kubernetes/loculus/values.schema.json (e.g., groupgroups, corrects docs group name, and repairs schema structure so keys are validated/rendered as intended).
  • Adds kubernetes/utils/check_schema_annotations.py to lint custom schema annotations and detect likely unintended schema nesting mistakes.
  • Wires the new checker into both pre-commit and the helm-schema-lint GitHub Actions workflow.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.

File Description
kubernetes/utils/check_schema_annotations.py New linter to validate custom values.schema.json annotations and catch structural schema slips.
kubernetes/loculus/values.schema.json Fixes docs annotation typos/group names and corrects schema structure so docs + validation behave as expected.
.pre-commit-config.yaml Runs the schema-annotation checker locally on relevant schema/docs changes.
.github/workflows/helm-schema-lint.yaml Runs the schema-annotation checker in CI when kubernetes/docs schema reference inputs change.
Suppressed comments (1)

kubernetes/loculus/values.schema.json:1378

  • Spelling/capitalization: GitHub is a proper noun and should be capitalized consistently in the schema descriptions.
              "description": "A github repository belonging to the given organization."

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread .pre-commit-config.yaml
entry: python3 kubernetes/utils/check_schema_annotations.py
language: system
pass_filenames: false
files: ^(kubernetes/loculus/values.schema.json|docs/src/content/docs/reference/helm-chart-config.mdx)$
"group": ["general"],
"groups": ["general"],
"type": "string",
"description": "A github organization or username."
Comment on lines +59 to +62
SINGLE_SCHEMA = {"not", "if", "then", "else", "items", "contains", "propertyNames",
"additionalProperties", "additionalItems"}
SCHEMA_LIST = {"allOf", "anyOf", "oneOf", "prefixItems"}
NAMED_SCHEMAS = {"properties", "patternProperties", "definitions", "$defs", "dependencies"}
"group": ["general"],
"groups": ["general"],
"type": "string",
"description": "An optional issuetemplate to use."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

deployment Code changes targetting the deployment infrastructure

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants