Skip to content

feat(validation): add YAML parser conformance warning#353

Open
hdamker wants to merge 2 commits into
camaraproject:mainfrom
hdamker:feat/yaml-parser-conformance-check
Open

feat(validation): add YAML parser conformance warning#353
hdamker wants to merge 2 commits into
camaraproject:mainfrom
hdamker:feat/yaml-parser-conformance-check

Conversation

@hdamker

@hdamker hdamker commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

What type of PR is this?

enhancement/feature
tests
documentation

What this PR does / why we need it:

Adds an API-scoped Python Validation check that parses each OpenAPI YAML
definition with js-yaml@5. Parser failures are reported as advisory P-037
warnings with the first parser line and column, while helper execution failures
remain error-level infrastructure findings.

The PR also adds rule metadata, unit tests for the Node helper and Python
check, and FAQ guidance for maintainers who see P-037 even though yamllint or
Spectral accepted the same file.

Local validation with this branch reports P-037 warnings at the known
subscription YAML locations in:

  • ConnectedNetworkType
  • DeviceReachabilityStatus
  • DeviceRoamingStatus

Which issue(s) this PR fixes:

Fixes #352

Special notes for reviewers:

Local checks run:

  • python3 -m pytest validation/tests/test_yaml_parser_conformance.py -q
  • python3 -m pytest validation/tests/test_rule_metadata_integrity.py -q
  • python3 -m pytest validation/tests -q

Changelog input

release-note
Adds an advisory validation warning for OpenAPI YAML files rejected by stricter YAML parsers.

Additional documentation

docs
documentation/validation/faq.md adds guidance for P-037.

@hdamker hdamker requested review from Kevsy and rartych as code owners June 22, 2026 06:12
Kevsy
Kevsy previously approved these changes Jun 22, 2026

@Kevsy Kevsy 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.

LGTM

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.

Consider a narrow YAML parser-compatibility check for js-yaml 5 failures

2 participants