@grafana/viz-contract 1.1.0 → 1.3.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.
Files changed (36) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/README.md +4 -2
  3. package/fixtures/epoch-range/args.json +1 -1
  4. package/fixtures/epoch-range/request.json +2 -2
  5. package/fixtures/epoch-range/response.json +0 -28
  6. package/fixtures/epoch-range/result.json +1 -29
  7. package/fixtures/epoch-range/spec.json +1 -29
  8. package/fixtures/hostile-label/args.json +1 -1
  9. package/fixtures/hostile-label/request.json +2 -2
  10. package/fixtures/hostile-label/response.json +0 -112
  11. package/fixtures/hostile-label/result.json +1 -113
  12. package/fixtures/hostile-label/spec.json +1 -113
  13. package/fixtures/partial-error/args.json +1 -1
  14. package/fixtures/partial-error/request.json +3 -3
  15. package/fixtures/partial-error/response.json +0 -56
  16. package/fixtures/partial-error/result.json +1 -57
  17. package/fixtures/partial-error/spec.json +1 -57
  18. package/fixtures/prometheus-line/args.json +1 -1
  19. package/fixtures/prometheus-line/request.json +2 -2
  20. package/fixtures/prometheus-line/response.json +0 -4
  21. package/fixtures/prometheus-line/result.json +1 -5
  22. package/fixtures/prometheus-line/spec.json +1 -5
  23. package/fixtures/title/args.json +15 -0
  24. package/fixtures/title/meta.json +4 -0
  25. package/fixtures/title/request.json +17 -0
  26. package/fixtures/title/response.json +1344 -0
  27. package/fixtures/title/result.json +1493 -0
  28. package/fixtures/title/spec.json +1373 -0
  29. package/fixtures/title/state.json +4 -0
  30. package/fixtures/too-large/args.json +1 -1
  31. package/package.json +1 -1
  32. package/registry/constants.json +1 -0
  33. package/registry/notices.json +1 -1
  34. package/schemas/bundled/query-datasource-args.schema.json +7 -0
  35. package/schemas/bundled/tool-result.schema.json +8 -1
  36. package/schemas/bundled/viz-spec.schema.json +11 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Changelog
2
2
 
3
+ This file lists the versions before 1.2.0. From 1.2.0 on, the
4
+ [GitHub Releases](https://github.com/grafana/viz-contract/releases) list the versions, with notes made from the titles
5
+ of the pull requests.
6
+
3
7
  Each version of the contract has one entry. [8-versioning.md](8-versioning.md) gives the version rules. An entry
4
8
  marked `internal` changes only an interface with the internal or the provisional promise.
5
9
 
package/README.md CHANGED
@@ -48,6 +48,7 @@ flowchart TB
48
48
  | App | The view in `ui://grafana/app.html` of mcp-grafana that gets the tool result and calls the Renderer |
49
49
  | Renderer | The browser bundle that draws a viz spec |
50
50
  | Viz spec | The JSON object that the App gives to the Renderer |
51
+ | Icon cache | The `react-inlinesvg` cache of the copy of `@grafana/ui` in the App. `Icon` reads an SVG from it, and makes no request for that SVG |
51
52
  | Note | A text line that the Source gives to `render_grafana_app`, and that the model reads in the same turn (`tool.28`). Not a notice: the Renderer shows a notice in the chart (`state.7`) |
52
53
 
53
54
  The Renderer draws the panels of the package `@plugins/grafana-echarts`.
@@ -123,6 +124,7 @@ version.
123
124
  | `maxBundleGzipBytes` | not set | bytes | yes | Largest gzip size of the Renderer bundle. Not set until the host size research is done |
124
125
  | `maxAppNotes` | 5 | notes | yes | Most notes of the Source that render_grafana_app adds to its text line |
125
126
  | `maxAppNoteChars` | 200 | characters | yes | Longest note in the text line of render_grafana_app |
127
+ | `maxTitleChars` | 100 | characters | yes | Longest title of the tool arguments |
126
128
  | `deprecationDays` | 30 | days | yes | Shortest deprecation period of a change to a frozen interface |
127
129
  | `specVersion` | 1 | version | no | The viz spec version that this contract gives |
128
130
  <!-- constants:end -->
@@ -136,5 +138,5 @@ version.
136
138
 
137
139
  ## Changes
138
140
 
139
- [CHANGELOG.md](CHANGELOG.md) lists the versions. [CONTRIBUTING.md](CONTRIBUTING.md) gives the steps to change the
140
- contract.
141
+ The [GitHub Releases](https://github.com/grafana/viz-contract/releases) list the versions. [CHANGELOG.md](CHANGELOG.md)
142
+ lists the versions before 1.2.0. [CONTRIBUTING.md](CONTRIBUTING.md) gives the steps to change the contract.
@@ -8,7 +8,7 @@
8
8
  "format": "time_series"
9
9
  }
10
10
  ],
11
- "from": 1790349877294,
11
+ "from": 1790352577294,
12
12
  "to": 1790353477294,
13
13
  "unit": "reqps"
14
14
  }
@@ -1,5 +1,5 @@
1
1
  {
2
- "from": "1790349877294",
2
+ "from": "1790352577294",
3
3
  "to": "1790353477294",
4
4
  "queries": [
5
5
  {
@@ -11,7 +11,7 @@
11
11
  "uid": "lgtm-prometheus"
12
12
  },
13
13
  "maxDataPoints": 1000,
14
- "intervalMs": 3600
14
+ "intervalMs": 900
15
15
  }
16
16
  ]
17
17
  }
@@ -41,20 +41,6 @@
41
41
  "data": {
42
42
  "values": [
43
43
  [
44
- 1790351737294,
45
- 1790351797294,
46
- 1790351857294,
47
- 1790351917294,
48
- 1790351977294,
49
- 1790352037294,
50
- 1790352097294,
51
- 1790352157294,
52
- 1790352217294,
53
- 1790352277294,
54
- 1790352337294,
55
- 1790352397294,
56
- 1790352457294,
57
- 1790352517294,
58
44
  1790352577294,
59
45
  1790352637294,
60
46
  1790352697294,
@@ -73,20 +59,6 @@
73
59
  1790353477294
74
60
  ],
75
61
  [
76
- 12,
77
- 12.65,
78
- 13.24,
79
- 13.68,
80
- 13.94,
81
- 13.99,
82
- 13.82,
83
- 13.45,
84
- 12.91,
85
- 12.28,
86
- 11.62,
87
- 11,
88
- 10.49,
89
- 10.14,
90
62
  10,
91
63
  10.08,
92
64
  10.37,
@@ -135,7 +135,7 @@
135
135
  ],
136
136
  "data": {
137
137
  "range": {
138
- "from": 1790349877294,
138
+ "from": 1790352577294,
139
139
  "to": 1790353477294
140
140
  },
141
141
  "capturedAt": 1790353477806,
@@ -179,20 +179,6 @@
179
179
  "data": {
180
180
  "values": [
181
181
  [
182
- 1790351737294,
183
- 1790351797294,
184
- 1790351857294,
185
- 1790351917294,
186
- 1790351977294,
187
- 1790352037294,
188
- 1790352097294,
189
- 1790352157294,
190
- 1790352217294,
191
- 1790352277294,
192
- 1790352337294,
193
- 1790352397294,
194
- 1790352457294,
195
- 1790352517294,
196
182
  1790352577294,
197
183
  1790352637294,
198
184
  1790352697294,
@@ -211,20 +197,6 @@
211
197
  1790353477294
212
198
  ],
213
199
  [
214
- 12,
215
- 12.65,
216
- 13.24,
217
- 13.68,
218
- 13.94,
219
- 13.99,
220
- 13.82,
221
- 13.45,
222
- 12.91,
223
- 12.28,
224
- 11.62,
225
- 11,
226
- 10.49,
227
- 10.14,
228
200
  10,
229
201
  10.08,
230
202
  10.37,
@@ -24,7 +24,7 @@
24
24
  },
25
25
  "data": {
26
26
  "range": {
27
- "from": 1790349877294,
27
+ "from": 1790352577294,
28
28
  "to": 1790353477294
29
29
  },
30
30
  "capturedAt": 1790353477806,
@@ -68,20 +68,6 @@
68
68
  "data": {
69
69
  "values": [
70
70
  [
71
- 1790351737294,
72
- 1790351797294,
73
- 1790351857294,
74
- 1790351917294,
75
- 1790351977294,
76
- 1790352037294,
77
- 1790352097294,
78
- 1790352157294,
79
- 1790352217294,
80
- 1790352277294,
81
- 1790352337294,
82
- 1790352397294,
83
- 1790352457294,
84
- 1790352517294,
85
71
  1790352577294,
86
72
  1790352637294,
87
73
  1790352697294,
@@ -100,20 +86,6 @@
100
86
  1790353477294
101
87
  ],
102
88
  [
103
- 12,
104
- 12.65,
105
- 13.24,
106
- 13.68,
107
- 13.94,
108
- 13.99,
109
- 13.82,
110
- 13.45,
111
- 12.91,
112
- 12.28,
113
- 11.62,
114
- 11,
115
- 10.49,
116
- 10.14,
117
89
  10,
118
90
  10.08,
119
91
  10.37,
@@ -8,7 +8,7 @@
8
8
  "format": "time_series"
9
9
  }
10
10
  ],
11
- "from": "now-24h",
11
+ "from": "now-15m",
12
12
  "to": "now",
13
13
  "unit": "reqps"
14
14
  }
@@ -1,5 +1,5 @@
1
1
  {
2
- "from": "now-24h",
2
+ "from": "now-15m",
3
3
  "to": "now",
4
4
  "queries": [
5
5
  {
@@ -11,7 +11,7 @@
11
11
  "uid": "lgtm-prometheus"
12
12
  },
13
13
  "maxDataPoints": 1000,
14
- "intervalMs": 86400
14
+ "intervalMs": 900
15
15
  }
16
16
  ]
17
17
  }
@@ -41,20 +41,6 @@
41
41
  "data": {
42
42
  "values": [
43
43
  [
44
- 1790351737294,
45
- 1790351797294,
46
- 1790351857294,
47
- 1790351917294,
48
- 1790351977294,
49
- 1790352037294,
50
- 1790352097294,
51
- 1790352157294,
52
- 1790352217294,
53
- 1790352277294,
54
- 1790352337294,
55
- 1790352397294,
56
- 1790352457294,
57
- 1790352517294,
58
44
  1790352577294,
59
45
  1790352637294,
60
46
  1790352697294,
@@ -73,20 +59,6 @@
73
59
  1790353477294
74
60
  ],
75
61
  [
76
- 10,
77
- 10.65,
78
- 11.24,
79
- 11.68,
80
- 11.94,
81
- 11.99,
82
- 11.82,
83
- 11.45,
84
- 10.91,
85
- 10.28,
86
- 9.62,
87
- 9,
88
- 8.49,
89
- 8.14,
90
62
  8,
91
63
  8.08,
92
64
  8.37,
@@ -143,20 +115,6 @@
143
115
  "data": {
144
116
  "values": [
145
117
  [
146
- 1790351737294,
147
- 1790351797294,
148
- 1790351857294,
149
- 1790351917294,
150
- 1790351977294,
151
- 1790352037294,
152
- 1790352097294,
153
- 1790352157294,
154
- 1790352217294,
155
- 1790352277294,
156
- 1790352337294,
157
- 1790352397294,
158
- 1790352457294,
159
- 1790352517294,
160
118
  1790352577294,
161
119
  1790352637294,
162
120
  1790352697294,
@@ -175,20 +133,6 @@
175
133
  1790353477294
176
134
  ],
177
135
  [
178
- 14.68,
179
- 14.94,
180
- 14.99,
181
- 14.82,
182
- 14.45,
183
- 13.91,
184
- 13.28,
185
- 12.62,
186
- 12,
187
- 11.49,
188
- 11.14,
189
- 11,
190
- 11.08,
191
- 11.37,
192
136
  11.84,
193
137
  12.44,
194
138
  13.1,
@@ -245,20 +189,6 @@
245
189
  "data": {
246
190
  "values": [
247
191
  [
248
- 1790351737294,
249
- 1790351797294,
250
- 1790351857294,
251
- 1790351917294,
252
- 1790351977294,
253
- 1790352037294,
254
- 1790352097294,
255
- 1790352157294,
256
- 1790352217294,
257
- 1790352277294,
258
- 1790352337294,
259
- 1790352397294,
260
- 1790352457294,
261
- 1790352517294,
262
192
  1790352577294,
263
193
  1790352637294,
264
194
  1790352697294,
@@ -277,20 +207,6 @@
277
207
  1790353477294
278
208
  ],
279
209
  [
280
- 17.82,
281
- 17.45,
282
- 16.91,
283
- 16.28,
284
- 15.62,
285
- 15,
286
- 14.49,
287
- 14.14,
288
- 14,
289
- 14.08,
290
- 14.37,
291
- 14.84,
292
- 15.44,
293
- 16.1,
294
210
  16.75,
295
211
  17.31,
296
212
  17.73,
@@ -347,20 +263,6 @@
347
263
  "data": {
348
264
  "values": [
349
265
  [
350
- 1790351737294,
351
- 1790351797294,
352
- 1790351857294,
353
- 1790351917294,
354
- 1790351977294,
355
- 1790352037294,
356
- 1790352097294,
357
- 1790352157294,
358
- 1790352217294,
359
- 1790352277294,
360
- 1790352337294,
361
- 1790352397294,
362
- 1790352457294,
363
- 1790352517294,
364
266
  1790352577294,
365
267
  1790352637294,
366
268
  1790352697294,
@@ -379,20 +281,6 @@
379
281
  1790353477294
380
282
  ],
381
283
  [
382
- 19.28,
383
- 18.62,
384
- 18,
385
- 17.49,
386
- 17.14,
387
- 17,
388
- 17.08,
389
- 17.37,
390
- 17.84,
391
- 18.44,
392
- 19.1,
393
- 19.75,
394
- 20.31,
395
- 20.73,
396
284
  20.97,
397
285
  20.98,
398
286
  20.77,
@@ -135,7 +135,7 @@
135
135
  ],
136
136
  "data": {
137
137
  "range": {
138
- "from": 1790267077294,
138
+ "from": 1790352577294,
139
139
  "to": 1790353477294
140
140
  },
141
141
  "capturedAt": 1790353477806,
@@ -179,20 +179,6 @@
179
179
  "data": {
180
180
  "values": [
181
181
  [
182
- 1790351737294,
183
- 1790351797294,
184
- 1790351857294,
185
- 1790351917294,
186
- 1790351977294,
187
- 1790352037294,
188
- 1790352097294,
189
- 1790352157294,
190
- 1790352217294,
191
- 1790352277294,
192
- 1790352337294,
193
- 1790352397294,
194
- 1790352457294,
195
- 1790352517294,
196
182
  1790352577294,
197
183
  1790352637294,
198
184
  1790352697294,
@@ -211,20 +197,6 @@
211
197
  1790353477294
212
198
  ],
213
199
  [
214
- 10,
215
- 10.65,
216
- 11.24,
217
- 11.68,
218
- 11.94,
219
- 11.99,
220
- 11.82,
221
- 11.45,
222
- 10.91,
223
- 10.28,
224
- 9.62,
225
- 9,
226
- 8.49,
227
- 8.14,
228
200
  8,
229
201
  8.08,
230
202
  8.37,
@@ -281,20 +253,6 @@
281
253
  "data": {
282
254
  "values": [
283
255
  [
284
- 1790351737294,
285
- 1790351797294,
286
- 1790351857294,
287
- 1790351917294,
288
- 1790351977294,
289
- 1790352037294,
290
- 1790352097294,
291
- 1790352157294,
292
- 1790352217294,
293
- 1790352277294,
294
- 1790352337294,
295
- 1790352397294,
296
- 1790352457294,
297
- 1790352517294,
298
256
  1790352577294,
299
257
  1790352637294,
300
258
  1790352697294,
@@ -313,20 +271,6 @@
313
271
  1790353477294
314
272
  ],
315
273
  [
316
- 14.68,
317
- 14.94,
318
- 14.99,
319
- 14.82,
320
- 14.45,
321
- 13.91,
322
- 13.28,
323
- 12.62,
324
- 12,
325
- 11.49,
326
- 11.14,
327
- 11,
328
- 11.08,
329
- 11.37,
330
274
  11.84,
331
275
  12.44,
332
276
  13.1,
@@ -383,20 +327,6 @@
383
327
  "data": {
384
328
  "values": [
385
329
  [
386
- 1790351737294,
387
- 1790351797294,
388
- 1790351857294,
389
- 1790351917294,
390
- 1790351977294,
391
- 1790352037294,
392
- 1790352097294,
393
- 1790352157294,
394
- 1790352217294,
395
- 1790352277294,
396
- 1790352337294,
397
- 1790352397294,
398
- 1790352457294,
399
- 1790352517294,
400
330
  1790352577294,
401
331
  1790352637294,
402
332
  1790352697294,
@@ -415,20 +345,6 @@
415
345
  1790353477294
416
346
  ],
417
347
  [
418
- 17.82,
419
- 17.45,
420
- 16.91,
421
- 16.28,
422
- 15.62,
423
- 15,
424
- 14.49,
425
- 14.14,
426
- 14,
427
- 14.08,
428
- 14.37,
429
- 14.84,
430
- 15.44,
431
- 16.1,
432
348
  16.75,
433
349
  17.31,
434
350
  17.73,
@@ -485,20 +401,6 @@
485
401
  "data": {
486
402
  "values": [
487
403
  [
488
- 1790351737294,
489
- 1790351797294,
490
- 1790351857294,
491
- 1790351917294,
492
- 1790351977294,
493
- 1790352037294,
494
- 1790352097294,
495
- 1790352157294,
496
- 1790352217294,
497
- 1790352277294,
498
- 1790352337294,
499
- 1790352397294,
500
- 1790352457294,
501
- 1790352517294,
502
404
  1790352577294,
503
405
  1790352637294,
504
406
  1790352697294,
@@ -517,20 +419,6 @@
517
419
  1790353477294
518
420
  ],
519
421
  [
520
- 19.28,
521
- 18.62,
522
- 18,
523
- 17.49,
524
- 17.14,
525
- 17,
526
- 17.08,
527
- 17.37,
528
- 17.84,
529
- 18.44,
530
- 19.1,
531
- 19.75,
532
- 20.31,
533
- 20.73,
534
422
  20.97,
535
423
  20.98,
536
424
  20.77,