Skip to content

Add input validation rules to the app manifest - #391

Draft
merschformann wants to merge 2 commits into
developfrom
merschformann/manifest-input-validation
Draft

merschformann wants to merge 2 commits into
developfrom
merschformann/manifest-input-validation

Conversation

@merschformann

Copy link
Copy Markdown
Member

Description

Adds configuration.content.validation to the app manifest. It declares rules that the run input data is checked against before a run is created. On push, the rules are sent as io_configuration.input_validation.

configuration:
  content:
    format: multi-file
    validation:
      enforce: block   # none | warn | block
      sources:
        stops: { file: input.xlsx, sheet: stops }
      rules:
        - name: lon-range
          in: stops
          column: lon
          range: [-180, 180]

Scope of this change:

  • New model: ManifestInputValidation, plus ManifestInputValidationEnforce. Both are exported from nextmv.
  • What gets checked: only the top-level structure. enforce must be one of none, warn or block; max_findings must be positive; every rule needs a non-empty, unique name. nextmv manifest validate reports these errors.
  • What passes through unchanged: the rule and source bodies, plus any unknown keys. New checks don't need an SDK release.
  • Not in this PR: evaluating the rules locally.

Testing

  • New unit tests in tests/test_manifest_input_validation.py: YAML load and round trip, structure errors, and the push payload.
  • The full unit test suite passes.

🤖 Generated with Claude Code

merschformann and others added 2 commits November 25, 2026 13:10
Support `configuration.content.validation` in app.yaml and send it as
`io_configuration.input_validation` when pushing an app. Only the top-level
structure is checked (enforce value, positive max_findings, unique rule
names); rule bodies are passed through unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

This branch has not been deployed

No deployments
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.

1 participant