[PATCH v3 03/10] bitbake-setup.schema.json: Use anyOf for non-disjoint subschemas
Rob Woolley <[email protected]> Mon, 15 Jun 2026 10:37:45 -0700
| Newsgroups | org.openembedded.lists.bitbake-devel |
|---|---|
| Message-ID | <[email protected]> |
The oneOf keyword is for matching exactly one subschema. However, the 2 possible BitBake configuration fragments are not disjoint. Since a simple example with type and description would match both. For this reason, we should use anyOf instead. This resolves the following jsonschema linting error: A `oneOf` where all branches have disjoint types can be safely converted to `anyOf` (oneof_to_anyof_disjoint_types) Reviewed-by: Yoann Congal <[email protected]> Signed-off-by: Rob Woolley <[email protected]> --- setup-schema/bitbake-setup.schema.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup-schema/bitbake-setup.schema.json b/setup-schema/bitbake-setup.schema.json index 1830d16df..314b5f78e 100644 --- a/setup-schema/bitbake-setup.schema.json +++ b/setup-schema/bitbake-setup.schema.json @@ -112,7 +112,7 @@ "type": "array", "description": "List of BitBake configuration fragments to enable", "items": { - "oneOf": [ + "anyOf": [ { "type": "string", "description": "Configuration fragment name" -- 2.49.0