Some schemas erroneously pass strict validation checks

Open
#5,991 4 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
55/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
javascript
Domain
build-system

Research direction

Start at the build server's strict-validation path and compare the current host-meta.json revision with the schemas listed in ajvNotStrictMode. Reproduce the exceptional pass and identify other affected schemas; done means schemas outside that exception list fail with the stated strictTypes union error.

Written by the indexing model from the issue text.

Description

Area with issue?

Build server

✔️ Expected Behavior

If a schema isn't included in ajvNotStrictMode, it should be subject to strict validation in its entirety. That means that the use of type unions in schemas should result in strict validation failing with the following error message:

Error: strict mode: use allowUnionTypes to allow union type keyword at "..." (strictTypes)

❌ Actual Behavior

Strict validation passes in exceptional circumstances.

JSON, YAML, or TOML file that does not work.

The current revision of host-meta.json, whose issues have since been fixed in #5990. Other such cases exist.

IDE or code editor.

None

Are you making a PR for this?

No, someone else must create the PR.

Dominant language
JavaScript
Stars
3.9k
Forks
2.4k
Avg merge
12h 34m
Merged PRs (30d)
134

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from SchemaStore/schemastore

All issues in SchemaStore/schemastore

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.