@hypequery/protocol-conformance 0.9.1 → 0.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +43 -27
- package/dist/adapters/generators.d.ts.map +1 -1
- package/dist/adapters/generators.js +14 -0
- package/dist/adapters/reference.d.ts +10 -1
- package/dist/adapters/reference.d.ts.map +1 -1
- package/dist/adapters/reference.js +52 -1
- package/dist/adapters/stdio.d.ts +3 -1
- package/dist/adapters/stdio.d.ts.map +1 -1
- package/dist/adapters/stdio.js +3 -0
- package/dist/bin/reference-adapter.js +2 -1
- package/dist/compare.js +10 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/report.d.ts.map +1 -1
- package/dist/report.js +4 -0
- package/dist/runner.d.ts.map +1 -1
- package/dist/runner.js +74 -8
- package/dist/types.d.ts +14 -0
- package/dist/types.d.ts.map +1 -1
- package/fixtures/cache-keys-v1/README.md +59 -0
- package/fixtures/cache-keys-v1/rejections.json +172 -0
- package/fixtures/cache-keys-v1/success.json +134 -0
- package/fixtures/deployment-bundles-v1/README.md +5 -57
- package/fixtures/deployment-releases-v1/README.md +6 -33
- package/fixtures/deployments-v1/README.md +5 -73
- package/fixtures/expressions-v1/README.md +4 -22
- package/fixtures/fuzz-seeds-v1/README.md +6 -26
- package/fixtures/identifiers-v1/README.md +4 -12
- package/fixtures/identifiers-v1/rejections.json +38 -0
- package/fixtures/identifiers-v1/success.json +18 -0
- package/fixtures/manifest.json +161 -39
- package/fixtures/query-diagnostics-v1/README.md +4 -45
- package/fixtures/query-events-v1/README.md +4 -56
- package/fixtures/query-implementations-v1/README.md +4 -30
- package/fixtures/query-schemas-v1/README.md +4 -22
- package/fixtures/sql-portability-v1/README.md +3 -12
- package/fixtures/tagged-values-v1/README.md +12 -1
- package/fixtures/tagged-values-v1/rejections.json +89 -0
- package/fixtures/tagged-values-v1/success.json +127 -0
- package/package.json +13 -5
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"id": "secret-missing",
|
|
4
|
+
"secretHex": "",
|
|
5
|
+
"namespace": {
|
|
6
|
+
"project": "acme",
|
|
7
|
+
"environment": "production"
|
|
8
|
+
},
|
|
9
|
+
"keyVersion": 1,
|
|
10
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
11
|
+
"error": "HQ_CACHE_KEY_SECRET_MISSING"
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
"id": "secret-31-bytes",
|
|
15
|
+
"secretHex": "11111111111111111111111111111111111111111111111111111111111111",
|
|
16
|
+
"namespace": {
|
|
17
|
+
"project": "acme",
|
|
18
|
+
"environment": "production"
|
|
19
|
+
},
|
|
20
|
+
"keyVersion": 1,
|
|
21
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
22
|
+
"error": "HQ_CACHE_KEY_SECRET_TOO_SHORT"
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
"id": "project-with-space",
|
|
26
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
27
|
+
"namespace": {
|
|
28
|
+
"project": "has space",
|
|
29
|
+
"environment": "production"
|
|
30
|
+
},
|
|
31
|
+
"keyVersion": 1,
|
|
32
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
33
|
+
"error": "HQ_CACHE_KEY_INVALID_NAMESPACE"
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
"id": "project-leading-underscore",
|
|
37
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
38
|
+
"namespace": {
|
|
39
|
+
"project": "_acme",
|
|
40
|
+
"environment": "production"
|
|
41
|
+
},
|
|
42
|
+
"keyVersion": 1,
|
|
43
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
44
|
+
"error": "HQ_CACHE_KEY_INVALID_NAMESPACE"
|
|
45
|
+
},
|
|
46
|
+
{
|
|
47
|
+
"id": "environment-leading-underscore",
|
|
48
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
49
|
+
"namespace": {
|
|
50
|
+
"project": "acme",
|
|
51
|
+
"environment": "__hypequery_env"
|
|
52
|
+
},
|
|
53
|
+
"keyVersion": 1,
|
|
54
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
55
|
+
"error": "HQ_CACHE_KEY_INVALID_NAMESPACE"
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
"id": "environment-empty",
|
|
59
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
60
|
+
"namespace": {
|
|
61
|
+
"project": "acme",
|
|
62
|
+
"environment": ""
|
|
63
|
+
},
|
|
64
|
+
"keyVersion": 1,
|
|
65
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
66
|
+
"error": "HQ_CACHE_KEY_INVALID_NAMESPACE"
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
"id": "key-version-zero",
|
|
70
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
71
|
+
"namespace": {
|
|
72
|
+
"project": "acme",
|
|
73
|
+
"environment": "production"
|
|
74
|
+
},
|
|
75
|
+
"keyVersion": 0,
|
|
76
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
77
|
+
"error": "HQ_CACHE_KEY_INVALID_VERSION"
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
"id": "key-version-negative",
|
|
81
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
82
|
+
"namespace": {
|
|
83
|
+
"project": "acme",
|
|
84
|
+
"environment": "production"
|
|
85
|
+
},
|
|
86
|
+
"keyVersion": -1,
|
|
87
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
88
|
+
"error": "HQ_CACHE_KEY_INVALID_VERSION"
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
"id": "key-version-fractional",
|
|
92
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
93
|
+
"namespace": {
|
|
94
|
+
"project": "acme",
|
|
95
|
+
"environment": "production"
|
|
96
|
+
},
|
|
97
|
+
"keyVersion": 1.5,
|
|
98
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
99
|
+
"error": "HQ_CACHE_KEY_INVALID_VERSION"
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
"id": "key-version-above-max",
|
|
103
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
104
|
+
"namespace": {
|
|
105
|
+
"project": "acme",
|
|
106
|
+
"environment": "production"
|
|
107
|
+
},
|
|
108
|
+
"keyVersion": 2147483648,
|
|
109
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
110
|
+
"error": "HQ_CACHE_KEY_INVALID_VERSION"
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
"id": "preimage-too-large",
|
|
114
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
115
|
+
"namespace": {
|
|
116
|
+
"project": "acme",
|
|
117
|
+
"environment": "production"
|
|
118
|
+
},
|
|
119
|
+
"keyVersion": 1,
|
|
120
|
+
"generator": {
|
|
121
|
+
"type": "repeat-string",
|
|
122
|
+
"utf8": "a",
|
|
123
|
+
"count": 1048577
|
|
124
|
+
},
|
|
125
|
+
"error": "HQ_CACHE_KEY_PREIMAGE_TOO_LARGE"
|
|
126
|
+
},
|
|
127
|
+
{
|
|
128
|
+
"id": "precedence-secret-before-namespace",
|
|
129
|
+
"secretHex": "",
|
|
130
|
+
"namespace": {
|
|
131
|
+
"project": "has space",
|
|
132
|
+
"environment": ""
|
|
133
|
+
},
|
|
134
|
+
"keyVersion": 0,
|
|
135
|
+
"generator": {
|
|
136
|
+
"type": "repeat-string",
|
|
137
|
+
"utf8": "a",
|
|
138
|
+
"count": 1048577
|
|
139
|
+
},
|
|
140
|
+
"error": "HQ_CACHE_KEY_SECRET_MISSING"
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
"id": "precedence-namespace-before-version",
|
|
144
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
145
|
+
"namespace": {
|
|
146
|
+
"project": "has space",
|
|
147
|
+
"environment": "production"
|
|
148
|
+
},
|
|
149
|
+
"keyVersion": 0,
|
|
150
|
+
"generator": {
|
|
151
|
+
"type": "repeat-string",
|
|
152
|
+
"utf8": "a",
|
|
153
|
+
"count": 1048577
|
|
154
|
+
},
|
|
155
|
+
"error": "HQ_CACHE_KEY_INVALID_NAMESPACE"
|
|
156
|
+
},
|
|
157
|
+
{
|
|
158
|
+
"id": "precedence-version-before-preimage",
|
|
159
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
160
|
+
"namespace": {
|
|
161
|
+
"project": "acme",
|
|
162
|
+
"environment": "production"
|
|
163
|
+
},
|
|
164
|
+
"keyVersion": 0,
|
|
165
|
+
"generator": {
|
|
166
|
+
"type": "repeat-string",
|
|
167
|
+
"utf8": "a",
|
|
168
|
+
"count": 1048577
|
|
169
|
+
},
|
|
170
|
+
"error": "HQ_CACHE_KEY_INVALID_VERSION"
|
|
171
|
+
}
|
|
172
|
+
]
|
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
[
|
|
2
|
+
{
|
|
3
|
+
"id": "basic",
|
|
4
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
5
|
+
"namespace": {
|
|
6
|
+
"project": "acme",
|
|
7
|
+
"environment": "production"
|
|
8
|
+
},
|
|
9
|
+
"keyVersion": 1,
|
|
10
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
11
|
+
"namespaceToken": "QZmJzTyhPUpRooLespx4XQ",
|
|
12
|
+
"key": "hq1.1.QZmJzTyhPUpRooLespx4XQ.uDrSq4MwQ-yttsrzdpCHbiGutMxHn2LM8sf2T0boN3k"
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"id": "namespace-separates-environment",
|
|
16
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
17
|
+
"namespace": {
|
|
18
|
+
"project": "acme",
|
|
19
|
+
"environment": "staging"
|
|
20
|
+
},
|
|
21
|
+
"keyVersion": 1,
|
|
22
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
23
|
+
"namespaceToken": "Ze61MnuVhdrTfAaVhRQAlw",
|
|
24
|
+
"key": "hq1.1.Ze61MnuVhdrTfAaVhRQAlw.yOeRV5mUwtkZ2ElBExrNWtjpiO2VC7Ite2vLVtyua7U"
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
"id": "namespace-separates-project",
|
|
28
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
29
|
+
"namespace": {
|
|
30
|
+
"project": "globex",
|
|
31
|
+
"environment": "production"
|
|
32
|
+
},
|
|
33
|
+
"keyVersion": 1,
|
|
34
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
35
|
+
"namespaceToken": "VOSW_B4ow0Tv5VwAzLza9Q",
|
|
36
|
+
"key": "hq1.1.VOSW_B4ow0Tv5VwAzLza9Q.m3d9igKuFNjuJKT1K15y4H5VqnkqZ3YiYIrtZbeOhqI"
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"id": "rotation-changes-key",
|
|
40
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
41
|
+
"namespace": {
|
|
42
|
+
"project": "acme",
|
|
43
|
+
"environment": "production"
|
|
44
|
+
},
|
|
45
|
+
"keyVersion": 2,
|
|
46
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
47
|
+
"namespaceToken": "QZmJzTyhPUpRooLespx4XQ",
|
|
48
|
+
"key": "hq1.2.QZmJzTyhPUpRooLespx4XQ.uDrSq4MwQ-yttsrzdpCHbiGutMxHn2LM8sf2T0boN3k"
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
"id": "secret-separates-key",
|
|
52
|
+
"secretHex": "2222222222222222222222222222222222222222222222222222222222222222",
|
|
53
|
+
"namespace": {
|
|
54
|
+
"project": "acme",
|
|
55
|
+
"environment": "production"
|
|
56
|
+
},
|
|
57
|
+
"keyVersion": 1,
|
|
58
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
59
|
+
"namespaceToken": "IOwBfU4fGoFMYm-dzKMTxw",
|
|
60
|
+
"key": "hq1.1.IOwBfU4fGoFMYm-dzKMTxw.0bhDqv_vgmO_y7t6gSX64uIh4uWj8iZX5Z5HIthWTZc"
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
"id": "long-secret",
|
|
64
|
+
"secretHex": "33333333333333333333333333333333333333333333333333333333333333333333333333333333333333333333333333333333333333333333333333333333",
|
|
65
|
+
"namespace": {
|
|
66
|
+
"project": "acme",
|
|
67
|
+
"environment": "production"
|
|
68
|
+
},
|
|
69
|
+
"keyVersion": 1,
|
|
70
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
71
|
+
"namespaceToken": "ZIWp472wGrPSAa8KgOAQAg",
|
|
72
|
+
"key": "hq1.1.ZIWp472wGrPSAa8KgOAQAg.k3DrKZocGPEgjdpv4_Y7AYzDbFZGe-mZUxPyEakGHWM"
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
"id": "empty-preimage",
|
|
76
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
77
|
+
"namespace": {
|
|
78
|
+
"project": "acme",
|
|
79
|
+
"environment": "production"
|
|
80
|
+
},
|
|
81
|
+
"keyVersion": 1,
|
|
82
|
+
"preimageUtf8": "",
|
|
83
|
+
"namespaceToken": "QZmJzTyhPUpRooLespx4XQ",
|
|
84
|
+
"key": "hq1.1.QZmJzTyhPUpRooLespx4XQ.JyTBb3tVj3hk39GNDkQdfzzacOFM7Mi28KI2JFF3x0U"
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
"id": "sensitive-preimage-not-recoverable",
|
|
88
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
89
|
+
"namespace": {
|
|
90
|
+
"project": "acme",
|
|
91
|
+
"environment": "production"
|
|
92
|
+
},
|
|
93
|
+
"keyVersion": 1,
|
|
94
|
+
"preimageUtf8": "{\"filters\":[{\"field\":\"email\",\"operator\":\"eq\",\"value\":\"ana@example.com\"}],\"tenant\":{\"value\":\"acme_corp\"}}",
|
|
95
|
+
"namespaceToken": "QZmJzTyhPUpRooLespx4XQ",
|
|
96
|
+
"key": "hq1.1.QZmJzTyhPUpRooLespx4XQ.GYbj4VYnkB6WuxsF1qI0k1PmLQiyiE1harFHqlUvREk"
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
"id": "max-key-version",
|
|
100
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
101
|
+
"namespace": {
|
|
102
|
+
"project": "acme",
|
|
103
|
+
"environment": "production"
|
|
104
|
+
},
|
|
105
|
+
"keyVersion": 2147483647,
|
|
106
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
107
|
+
"namespaceToken": "QZmJzTyhPUpRooLespx4XQ",
|
|
108
|
+
"key": "hq1.2147483647.QZmJzTyhPUpRooLespx4XQ.uDrSq4MwQ-yttsrzdpCHbiGutMxHn2LM8sf2T0boN3k"
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
"id": "deployment-target-punctuation",
|
|
112
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
113
|
+
"namespace": {
|
|
114
|
+
"project": "project-1",
|
|
115
|
+
"environment": "preview.eu:1"
|
|
116
|
+
},
|
|
117
|
+
"keyVersion": 1,
|
|
118
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
119
|
+
"namespaceToken": "5K9R0USPhZZ80IwqwSQTpA",
|
|
120
|
+
"key": "hq1.1.5K9R0USPhZZ80IwqwSQTpA.IoVojW5ZVqSAIc1xOKExteLniKobmndoGRIQ1SulVu4"
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
"id": "deployment-target-leading-digit",
|
|
124
|
+
"secretHex": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
125
|
+
"namespace": {
|
|
126
|
+
"project": "1acme",
|
|
127
|
+
"environment": "production"
|
|
128
|
+
},
|
|
129
|
+
"keyVersion": 1,
|
|
130
|
+
"preimageUtf8": "{\"kind\":\"dataset\",\"target\":\"orders\",\"v\":1}",
|
|
131
|
+
"namespaceToken": "nCVELIgkASbf5L3bU9HY1Q",
|
|
132
|
+
"key": "hq1.1.nCVELIgkASbf5L3bU9HY1Q.0QiWBc1mnpiVmKm8nvYnTXoppJ7SEHtJNQgW-70eDMo"
|
|
133
|
+
}
|
|
134
|
+
]
|
|
@@ -1,61 +1,9 @@
|
|
|
1
1
|
# Deployment bundle manifest v1 fixtures
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
- `rejections.json` maps generated invalid inputs to stable failure codes.
|
|
5
|
-
- `identity.json` fixes the RFC 8785 canonical bytes and domain-separated
|
|
6
|
-
SHA-256 identity for matching success fixture ids.
|
|
3
|
+
These fixtures pin the closed bundle rules in RFC 0007.
|
|
7
4
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
5
|
+
- `success.json` contains accepted manifests.
|
|
6
|
+
- `rejections.json` describes invalid manifests and required failure codes.
|
|
7
|
+
- `identity.json` pins canonical bytes and domain-separated SHA-256 identities.
|
|
11
8
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
Every rejection is a deterministic transform of this pinned base manifest
|
|
15
|
-
(RFC 0012), where `artifact(index)` denotes (with `<sha256>` the 64-digit
|
|
16
|
-
lowercase hexadecimal form of `index`, zero-padded):
|
|
17
|
-
|
|
18
|
-
```json
|
|
19
|
-
{
|
|
20
|
-
"runtime": "node",
|
|
21
|
-
"path": "artifacts/<sha256>.mjs",
|
|
22
|
-
"sha256": "<sha256>",
|
|
23
|
-
"byteLength": 1
|
|
24
|
-
}
|
|
25
|
-
```
|
|
26
|
-
|
|
27
|
-
and the base is:
|
|
28
|
-
|
|
29
|
-
```json
|
|
30
|
-
{
|
|
31
|
-
"kind": "hypequery-deployment-bundle",
|
|
32
|
-
"version": 1,
|
|
33
|
-
"deployment": {
|
|
34
|
-
"path": "deployment.json",
|
|
35
|
-
"identity": "1111111111111111111111111111111111111111111111111111111111111111",
|
|
36
|
-
"sha256": "2222222222222222222222222222222222222222222222222222222222222222",
|
|
37
|
-
"byteLength": 1
|
|
38
|
-
},
|
|
39
|
-
"artifacts": [artifact(0)]
|
|
40
|
-
}
|
|
41
|
-
```
|
|
42
|
-
|
|
43
|
-
Generator types expand as follows:
|
|
44
|
-
|
|
45
|
-
- `wrong-root-type`: an empty array instead of an object;
|
|
46
|
-
- `unknown-root-field`: the base plus `"extra": true`;
|
|
47
|
-
- `unsupported-version`: the base with `"version": 2`;
|
|
48
|
-
- `malformed-digest`: the base with `deployment.identity` replaced by
|
|
49
|
-
`"bad"`;
|
|
50
|
-
- `traversal-path`: the base with `deployment.path` replaced by
|
|
51
|
-
`"../deployment.json"`;
|
|
52
|
-
- `duplicate-path`: the base with its only artifact's `path` replaced by
|
|
53
|
-
`"deployment.json"`, colliding with the deployment path;
|
|
54
|
-
- `too-many-artifacts`: the base with 101 artifacts `artifact(0)` through
|
|
55
|
-
`artifact(100)`;
|
|
56
|
-
- `deployment-too-large`: the base with `deployment.byteLength` replaced by
|
|
57
|
-
16777217 (16 MiB plus one byte);
|
|
58
|
-
- `unsafe-accessor`: the base with `kind` served by an enumerable computed
|
|
59
|
-
accessor returning `"hypequery-deployment-bundle"` instead of a plain
|
|
60
|
-
data property. Host-model conditional (RFC 0012): implementations whose
|
|
61
|
-
input model cannot express computed accessors skip this case.
|
|
9
|
+
Rejections cover root shape, unknown fields, versions, digests, traversal, duplicate paths, artifact and byte limits, and unsafe host-language accessors. Filesystem byte verification is tested by the deployment verifier because this family describes manifests, not directories.
|
|
@@ -1,36 +1,9 @@
|
|
|
1
|
-
# Deployment release
|
|
1
|
+
# Deployment release v1 fixtures
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
- `rejections.json` maps generated invalid inputs to stable failure codes.
|
|
5
|
-
- `identity.json` fixes the RFC 8785 canonical bytes and domain-separated
|
|
6
|
-
SHA-256 identity for matching success fixture ids.
|
|
3
|
+
These fixtures pin RFC 0008 release envelopes, which bind one verified bundle identity to an explicit project and environment.
|
|
7
4
|
|
|
8
|
-
|
|
9
|
-
|
|
5
|
+
- `success.json` contains accepted envelopes.
|
|
6
|
+
- `rejections.json` maps invalid or generated inputs to stable error codes.
|
|
7
|
+
- `identity.json` pins canonical bytes and release identities.
|
|
10
8
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
Every rejection is a deterministic transform of this pinned base envelope
|
|
14
|
-
(RFC 0012):
|
|
15
|
-
|
|
16
|
-
```json
|
|
17
|
-
{
|
|
18
|
-
"kind": "hypequery-deployment-release",
|
|
19
|
-
"version": 1,
|
|
20
|
-
"bundleIdentity": "0000000000000000000000000000000000000000000000000000000000000000",
|
|
21
|
-
"target": { "project": "project_1", "environment": "production" }
|
|
22
|
-
}
|
|
23
|
-
```
|
|
24
|
-
|
|
25
|
-
Generator types expand as follows:
|
|
26
|
-
|
|
27
|
-
- `wrong-root-type`: an empty array instead of an object;
|
|
28
|
-
- `unknown-root-field`: the base plus `"extra": true`;
|
|
29
|
-
- `unsupported-version`: the base with `"version": 2`;
|
|
30
|
-
- `malformed-bundle-identity`: the base with `"bundleIdentity": "bad"`;
|
|
31
|
-
- `target-too-large`: the base with `target.project` replaced by `p`
|
|
32
|
-
followed by 128 repetitions of `a` (129 bytes);
|
|
33
|
-
- `unsafe-accessor`: the base with `kind` served by an enumerable computed
|
|
34
|
-
accessor returning `"hypequery-deployment-release"` instead of a plain
|
|
35
|
-
data property. Host-model conditional (RFC 0012): implementations whose
|
|
36
|
-
input model cannot express computed accessors skip this case.
|
|
9
|
+
The family covers closed fields, version handling, bundle digests, target limits, and unsafe accessors. Bundle filesystem verification remains in the bundle contract.
|
|
@@ -1,77 +1,9 @@
|
|
|
1
1
|
# Deployment contract v1 fixtures
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
- `rejections.json` maps generated invalid inputs to stable failure codes.
|
|
5
|
-
- `identity.json` fixes the RFC 8785 canonical bytes and domain-separated
|
|
6
|
-
SHA-256 identity for matching success fixture ids.
|
|
3
|
+
These fixtures exercise RFC 0006 deployment envelopes containing datasets, named queries, endpoint policy, and runtime artifact references.
|
|
7
4
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
implementation must return.
|
|
5
|
+
- `success.json` contains accepted language-neutral deployments.
|
|
6
|
+
- `rejections.json` pins generated invalid inputs and stable error codes.
|
|
7
|
+
- `identity.json` pins canonical bytes and deployment identities.
|
|
12
8
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
Every rejection is a deterministic transform of this pinned base deployment
|
|
16
|
-
(RFC 0012), where `dataset(name)` denotes:
|
|
17
|
-
|
|
18
|
-
```json
|
|
19
|
-
{
|
|
20
|
-
"name": "<name>",
|
|
21
|
-
"source": "orders",
|
|
22
|
-
"tenant": { "kind": "not-required" },
|
|
23
|
-
"dimensions": [],
|
|
24
|
-
"measures": [],
|
|
25
|
-
"filters": [],
|
|
26
|
-
"metrics": [],
|
|
27
|
-
"relationships": []
|
|
28
|
-
}
|
|
29
|
-
```
|
|
30
|
-
|
|
31
|
-
and the base is:
|
|
32
|
-
|
|
33
|
-
```json
|
|
34
|
-
{
|
|
35
|
-
"kind": "hypequery-deployment",
|
|
36
|
-
"version": 1,
|
|
37
|
-
"datasets": [dataset("orders")],
|
|
38
|
-
"queries": [],
|
|
39
|
-
"artifacts": []
|
|
40
|
-
}
|
|
41
|
-
```
|
|
42
|
-
|
|
43
|
-
Generator types expand as follows:
|
|
44
|
-
|
|
45
|
-
- `wrong-root-type`: an empty array instead of an object;
|
|
46
|
-
- `unknown-root-field`: the base plus `"extra": true`;
|
|
47
|
-
- `unsupported-version`: the base with `"version": 2`;
|
|
48
|
-
- `invalid-dataset-identifier`: the base with its only dataset replaced by
|
|
49
|
-
`dataset("bad-name")` (hyphens are not valid identifier characters);
|
|
50
|
-
- `invalid-relationship-queryability`: the base with its only dataset given
|
|
51
|
-
one relationship
|
|
52
|
-
`{ "name": "items", "kind": "hasMany", "target": "orders", "from": "id",
|
|
53
|
-
"to": "order_id", "queryable": true }` (a `hasMany` relationship must not
|
|
54
|
-
be queryable);
|
|
55
|
-
- `missing-runtime-artifact`: the base plus one named query `health` with
|
|
56
|
-
input `{ "kind": "any" }`, output `{ "kind": "any" }`, implementation
|
|
57
|
-
`{ "kind": "runtime-reference", "runtime": "node", "artifactSha256":
|
|
58
|
-
<64 zeros>, "entrypoint": "queries.health" }`, endpoint
|
|
59
|
-
`{ "access": { "kind": "public" }, "tenant": { "kind": "not-required" },
|
|
60
|
-
"method": "GET", "path": "/health" }`, and `"tags": []` — while
|
|
61
|
-
`artifacts` stays empty, so the referenced artifact does not exist;
|
|
62
|
-
- `ambiguous-query-route`: the base plus two named queries `first` and
|
|
63
|
-
`second`, each with input `{ "kind": "void" }`, output
|
|
64
|
-
`{ "kind": "void" }`, implementation `{ "kind": "semantic-plan",
|
|
65
|
-
"query": { "kind": "dataset", "dataset": "orders", "dimensions": [],
|
|
66
|
-
"measures": [], "filters": [], "orderBy": [] } }`, endpoint
|
|
67
|
-
`{ "access": { "kind": "public" }, "tenant": { "kind": "not-required" },
|
|
68
|
-
"method": "GET", "path": "/same" }`, and `"tags": []` — both share one
|
|
69
|
-
method and path;
|
|
70
|
-
- `too-many-datasets`: the base with 101 datasets `dataset("dataset_0")`
|
|
71
|
-
through `dataset("dataset_100")`;
|
|
72
|
-
- `source-too-large`: the base with its only dataset's `source` replaced by
|
|
73
|
-
1025 repetitions of `a`;
|
|
74
|
-
- `unsafe-accessor`: the base with `kind` served by an enumerable computed
|
|
75
|
-
accessor returning `"hypequery-deployment"` instead of a plain data
|
|
76
|
-
property. Host-model conditional (RFC 0012): implementations whose input
|
|
77
|
-
model cannot express computed accessors skip this case.
|
|
9
|
+
Coverage includes closed fields, versions, identifiers, relationship queryability, missing runtime artifacts, ambiguous routes, collection limits, source limits, and unsafe accessors.
|
|
@@ -1,25 +1,7 @@
|
|
|
1
|
-
# Portable expression fixtures
|
|
1
|
+
# Portable expression v1 fixtures
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
operator registry and both semantic query envelopes. `rejections.json` covers
|
|
5
|
-
every stable failure code; generator entries describe inputs that are awkward
|
|
6
|
-
or unsafe to encode directly as JSON.
|
|
3
|
+
This family accompanies RFC 0003 and covers the closed semantic expression registry plus metric and dataset query envelopes.
|
|
7
4
|
|
|
8
|
-
|
|
5
|
+
`success.json` exercises accepted expressions and queries. `rejections.json` pins every stable failure code, including generated depth, width, node-count, and unsafe-accessor cases.
|
|
9
6
|
|
|
10
|
-
|
|
11
|
-
(`expression` or `query`) selecting the validated surface, and the required
|
|
12
|
-
stable `error` code. Generator types expand as follows (RFC 0012), where
|
|
13
|
-
`literal` denotes `{ "kind": "literal", "value": false }`:
|
|
14
|
-
|
|
15
|
-
- `nested-not`: wraps `literal` in
|
|
16
|
-
`{ "kind": "logical", "operator": "not", "operand": ... }` `depth` times;
|
|
17
|
-
- `logical-operands`: one
|
|
18
|
-
`{ "kind": "logical", "operator": "and", "operands": [...] }` node whose
|
|
19
|
-
operands are `count` copies of `literal`;
|
|
20
|
-
- `logical-tree`: one `and` node whose operands are 10 `and` nodes, each
|
|
21
|
-
with 100 copies of `literal` as operands (1011 nodes total);
|
|
22
|
-
- `unsafe-accessor`: `{ "kind": "reference" }` with `name` served by an
|
|
23
|
-
enumerable computed accessor returning `"orders"` instead of a plain data
|
|
24
|
-
property. Host-model conditional (RFC 0012): implementations whose input
|
|
25
|
-
model cannot express computed accessors skip this case.
|
|
7
|
+
Each rejection selects the `expression` or `query` validation surface and contains exactly one literal value or deterministic generator.
|
|
@@ -1,29 +1,9 @@
|
|
|
1
|
-
#
|
|
1
|
+
# Deterministic fuzz seed corpus v1
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
(RFC 0012). A mutating fuzzer is out of scope; this corpus is the foundation
|
|
5
|
-
it would grow. Any input that later crashes an implementation must be
|
|
6
|
-
minimized and added here as a seed.
|
|
3
|
+
These adversarial inputs replay on every conformance run under RFC 0012. An implementation may accept a seed within documented limits or reject it with a stable `HQ_*` code; it must never crash, hang, partially execute input, or allocate without bounds.
|
|
7
4
|
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
input, and must enforce documented limits before unbounded allocation.
|
|
5
|
+
- `value-sources.json` targets duplicate-aware JSON decoding and tagged values.
|
|
6
|
+
- `structured-values.json` targets selected structural validator families.
|
|
7
|
+
- `sql-expressions.json` targets the SQL portability compiler.
|
|
12
8
|
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
- `value-sources.json` targets the tagged-values-v1 decode and validation
|
|
16
|
-
path. Entries carry an `id` and exactly one of `sourceUtf8` (exact JSON
|
|
17
|
-
source for a duplicate-aware parser) or `generator` (expanded per the
|
|
18
|
-
tagged-values-v1 README).
|
|
19
|
-
- `structured-values.json` targets structural validators. Entries carry an
|
|
20
|
-
`id`, a `value`, and a `targets` array of family names; the seed is
|
|
21
|
-
replayed once per target family through that family's validate operation.
|
|
22
|
-
- `sql-expressions.json` targets the sql-portability-v1 compiler. Entries
|
|
23
|
-
carry an `id` and either `sql` (the exact source) or `sqlRepeat`
|
|
24
|
-
(`{ "value": ..., "count": ... }`, expanded by concatenating `count`
|
|
25
|
-
copies of `value`, optionally between `prefix` and `suffix`).
|
|
26
|
-
|
|
27
|
-
Seed ids are unique within one file. Seeds carry no expected code: any
|
|
28
|
-
stable rejection is conforming, and an implementation that accepts a seed
|
|
29
|
-
within its limits also conforms.
|
|
9
|
+
Minimize any newly discovered crashing input and add it here with a unique ID.
|
|
@@ -1,15 +1,7 @@
|
|
|
1
|
-
# Portable identifier
|
|
1
|
+
# Portable identifier v1 fixtures
|
|
2
2
|
|
|
3
|
-
These draft
|
|
3
|
+
These draft fixtures accompany RFC 0002.
|
|
4
4
|
|
|
5
|
-
Success
|
|
6
|
-
`value`, and the expected `segments`. Rejection entries contain exactly one of
|
|
7
|
-
`value` or `generator` and the required stable `error` code.
|
|
5
|
+
Success cases pin simple or qualified identifiers and their exact segments. Rejection cases contain a literal value or deterministic repeat/segment generator plus the required error code.
|
|
8
6
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
- `repeat-string`: concatenates `count` copies of `value`;
|
|
12
|
-
- `qualified-segments`: joins `count` copies of `segment` with `.`.
|
|
13
|
-
|
|
14
|
-
Fixture consumers must preserve accepted strings exactly. They must not trim,
|
|
15
|
-
case-fold, normalize, or reinterpret qualified identifiers as SQL names.
|
|
7
|
+
Conforming implementations preserve accepted strings exactly: no trimming, case folding, Unicode normalization, or reinterpretation as SQL identifiers.
|
|
@@ -54,5 +54,43 @@
|
|
|
54
54
|
"count": 9
|
|
55
55
|
},
|
|
56
56
|
"error": "HQ_IDENTIFIER_TOO_MANY_SEGMENTS"
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
"id": "qualified-bytes-513",
|
|
60
|
+
"mode": "qualified",
|
|
61
|
+
"value": "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
|
62
|
+
"error": "HQ_IDENTIFIER_TOO_LONG"
|
|
63
|
+
},
|
|
64
|
+
{
|
|
65
|
+
"id": "reserved-non-first-segment",
|
|
66
|
+
"mode": "qualified",
|
|
67
|
+
"value": "orders.__hypequery_internal",
|
|
68
|
+
"error": "HQ_IDENTIFIER_RESERVED"
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
"id": "precedence-length-before-reserved",
|
|
72
|
+
"mode": "simple",
|
|
73
|
+
"generator": {
|
|
74
|
+
"type": "repeat-string",
|
|
75
|
+
"value": "__hypequery",
|
|
76
|
+
"count": 12
|
|
77
|
+
},
|
|
78
|
+
"error": "HQ_IDENTIFIER_TOO_LONG"
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
"id": "precedence-length-before-format",
|
|
82
|
+
"mode": "simple",
|
|
83
|
+
"generator": {
|
|
84
|
+
"type": "repeat-string",
|
|
85
|
+
"value": "-",
|
|
86
|
+
"count": 129
|
|
87
|
+
},
|
|
88
|
+
"error": "HQ_IDENTIFIER_TOO_LONG"
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
"id": "precedence-format-before-reserved",
|
|
92
|
+
"mode": "simple",
|
|
93
|
+
"value": "__hypequery-internal",
|
|
94
|
+
"error": "HQ_IDENTIFIER_INVALID_FORMAT"
|
|
57
95
|
}
|
|
58
96
|
]
|
|
@@ -22,5 +22,23 @@
|
|
|
22
22
|
"mode": "qualified",
|
|
23
23
|
"value": "orders.customer.country",
|
|
24
24
|
"segments": ["orders", "customer", "country"]
|
|
25
|
+
},
|
|
26
|
+
{
|
|
27
|
+
"id": "segment-bytes-128",
|
|
28
|
+
"mode": "simple",
|
|
29
|
+
"value": "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
|
30
|
+
"segments": ["aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"]
|
|
31
|
+
},
|
|
32
|
+
{
|
|
33
|
+
"id": "qualified-segments-8",
|
|
34
|
+
"mode": "qualified",
|
|
35
|
+
"value": "s0.s1.s2.s3.s4.s5.s6.s7",
|
|
36
|
+
"segments": ["s0", "s1", "s2", "s3", "s4", "s5", "s6", "s7"]
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"id": "qualified-bytes-512",
|
|
40
|
+
"mode": "qualified",
|
|
41
|
+
"value": "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
|
|
42
|
+
"segments": ["aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"]
|
|
25
43
|
}
|
|
26
44
|
]
|