Following system colour scheme Selected dark colour scheme Selected light colour scheme

Python Enhancement Proposals

Appendix: JSON Schema for Variant Metadata

Appendix: JSON Schema for Variant Metadata

  1{
  2  "$schema": "https://json-schema.org/draft/2020-12/schema",
  3  "$id": "https://variants-schema.wheelnext.dev/peps/825/v0.1.0.json",
  4  "title": "Variant metadata, v0.1.0",
  5  "description": "The format for variant metadata (variant.json) and index-level metadata ({name}-{version}-variants.json)",
  6  "type": "object",
  7  "properties": {
  8    "$schema": {
  9      "description": "JSON schema URL",
 10      "type": "string"
 11    },
 12    "default-priorities": {
 13      "description": "Default priorities for ordering variants",
 14      "type": "object",
 15      "properties": {
 16        "namespace": {
 17          "description": "Namespaces (in order of preference)",
 18          "type": "array",
 19          "items": {
 20            "type": "string",
 21            "pattern": "^[a-z0-9_]+$"
 22          },
 23          "minItems": 1,
 24          "uniqueItems": true
 25        },
 26        "feature": {
 27          "description": "Default feature priorities (by namespace)",
 28          "type": "object",
 29          "patternProperties": {
 30            "^[a-z0-9_]+$": {
 31              "description": "The most preferred features",
 32              "type": "array",
 33              "items": {
 34                "type": "string",
 35                "pattern": "^[a-z0-9_]+$"
 36              },
 37              "minItems": 0,
 38              "uniqueItems": true
 39            }
 40          },
 41          "additionalProperties": false,
 42          "uniqueItems": true
 43        },
 44        "property": {
 45          "description": "Default property priorities (by namespace)",
 46          "type": "object",
 47          "patternProperties": {
 48            "^[a-z0-9_]+$": {
 49              "description": "Default property priorities (by feature name)",
 50              "type": "object",
 51              "patternProperties": {
 52                "^[a-z0-9_]+$": {
 53                  "description": "The most preferred feature values",
 54                  "type": "array",
 55                  "items": {
 56                    "type": "string",
 57                    "pattern": "^[a-z0-9_.]+$"
 58                  },
 59                  "minItems": 0,
 60                  "uniqueItems": true
 61                }
 62              },
 63              "additionalProperties": false,
 64              "uniqueItems": true
 65            }
 66          },
 67          "additionalProperties": false,
 68          "uniqueItems": true
 69        }
 70      },
 71      "additionalProperties": false,
 72      "uniqueItems": true,
 73      "required": [
 74        "namespace"
 75      ]
 76    },
 77    "variants": {
 78      "description": "Mapping of variant labels to properties",
 79      "type": "object",
 80      "patternProperties": {
 81        "^[a-z0-9_.]{1,16}$": {
 82          "type": "object",
 83          "description": "Mapping of namespaces in a variant",
 84          "patternProperties": {
 85            "^[a-z0-9_.]+$": {
 86              "description": "Mapping of feature names in a namespace",
 87              "patternProperties": {
 88                "^[a-z0-9_.]+$": {
 89                  "description": "List of values for this variant feature",
 90                  "type": "array",
 91                  "items": {
 92                    "type": "string",
 93                    "pattern": "^[a-z0-9_.]+$"
 94                  },
 95                  "minItems": 1,
 96                  "uniqueItems": true
 97                }
 98              },
 99              "uniqueItems": true,
100              "additionalProperties": false
101            }
102          },
103          "uniqueItems": true,
104          "additionalProperties": false
105        }
106      },
107      "additionalProperties": false,
108      "uniqueItems": true
109    }
110  },
111  "required": [
112    "$schema",
113    "default-priorities",
114    "variants"
115  ],
116  "additionalProperties": false,
117  "uniqueItems": true
118}