@imferno/schema 3.0.2-beta.8b55d2c → 3.0.2-beta.8c7d3cd
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 +2 -0
- package/index.d.ts +6 -0
- package/index.js +4 -0
- package/package.json +1 -1
- package/schemas/asset-map.json +21 -0
- package/schemas/composition-playlist.json +184 -6
- package/schemas/imf-report.json +268 -8
- package/schemas/imferno-package.json +3556 -0
- package/schemas/rules-config.json +1 -1
- package/schemas/validation-report.json +182 -8
- package/schemas/validation-result.json +4267 -0
package/schemas/imf-report.json
CHANGED
|
@@ -19,6 +19,13 @@
|
|
|
19
19
|
"package": {
|
|
20
20
|
"$ref": "#/definitions/PackageSummary"
|
|
21
21
|
},
|
|
22
|
+
"ruleWarnings": {
|
|
23
|
+
"description": "Keys of the `rules` option that select no rule (typos, unknown editions); they were ignored. Absent when every key matched.",
|
|
24
|
+
"type": "array",
|
|
25
|
+
"items": {
|
|
26
|
+
"$ref": "#/definitions/RuleValidationWarning"
|
|
27
|
+
}
|
|
28
|
+
},
|
|
22
29
|
"validation": {
|
|
23
30
|
"$ref": "#/definitions/ValidationReport"
|
|
24
31
|
}
|
|
@@ -335,7 +342,7 @@
|
|
|
335
342
|
"format": "uuid"
|
|
336
343
|
},
|
|
337
344
|
"IssueSource": {
|
|
338
|
-
"description": "Which authority produced a validation finding.\n\nEncodes the \"prose vs XSD\" provenance distinction that SMPTE ST 2067-3 §5.1 calls out (\"the prose document takes precedence on conflict\"), so callers can filter, group, or apply per-source severity overrides without inspecting the code string.\n\
|
|
345
|
+
"description": "Which authority produced a validation finding.\n\nEncodes the \"prose vs XSD\" provenance distinction that SMPTE ST 2067-3 §5.1 calls out (\"the prose document takes precedence on conflict\"), so callers can filter, group, or apply per-source severity overrides without inspecting the code string.\n\nDerived from the rule's spec ([`Spec::source`]): `XSD` rules are `XsdLayer`, `IMFERNO` rules `EngineInternal`, SMPTE specs `ProseRule`.",
|
|
339
346
|
"oneOf": [
|
|
340
347
|
{
|
|
341
348
|
"description": "Came from the runtime XSD validator (uppsala). Schema-layer: the structural subset of the spec that the XSD DSL can express.",
|
|
@@ -428,6 +435,13 @@
|
|
|
428
435
|
"format": "uint",
|
|
429
436
|
"minimum": 0.0
|
|
430
437
|
},
|
|
438
|
+
"segment_id": {
|
|
439
|
+
"description": "Segment Id (`urn:uuid:…`) if applicable",
|
|
440
|
+
"type": [
|
|
441
|
+
"string",
|
|
442
|
+
"null"
|
|
443
|
+
]
|
|
444
|
+
},
|
|
431
445
|
"sequence_id": {
|
|
432
446
|
"description": "Sequence UUID if applicable",
|
|
433
447
|
"type": [
|
|
@@ -514,6 +528,85 @@
|
|
|
514
528
|
}
|
|
515
529
|
}
|
|
516
530
|
},
|
|
531
|
+
"RuleValidationReason": {
|
|
532
|
+
"oneOf": [
|
|
533
|
+
{
|
|
534
|
+
"description": "`source:<variant>` — `<variant>` isn't a known [`IssueSource`].",
|
|
535
|
+
"type": "object",
|
|
536
|
+
"required": [
|
|
537
|
+
"kind",
|
|
538
|
+
"variant"
|
|
539
|
+
],
|
|
540
|
+
"properties": {
|
|
541
|
+
"kind": {
|
|
542
|
+
"type": "string",
|
|
543
|
+
"enum": [
|
|
544
|
+
"unknown_source"
|
|
545
|
+
]
|
|
546
|
+
},
|
|
547
|
+
"variant": {
|
|
548
|
+
"type": "string"
|
|
549
|
+
}
|
|
550
|
+
}
|
|
551
|
+
},
|
|
552
|
+
{
|
|
553
|
+
"description": "The key matches no rule, edition or spec of the catalogue.",
|
|
554
|
+
"type": "object",
|
|
555
|
+
"required": [
|
|
556
|
+
"kind"
|
|
557
|
+
],
|
|
558
|
+
"properties": {
|
|
559
|
+
"kind": {
|
|
560
|
+
"type": "string",
|
|
561
|
+
"enum": [
|
|
562
|
+
"matches_nothing"
|
|
563
|
+
]
|
|
564
|
+
}
|
|
565
|
+
}
|
|
566
|
+
},
|
|
567
|
+
{
|
|
568
|
+
"description": "The key uses syntax the matcher doesn't support (e.g. `XSD/*`).",
|
|
569
|
+
"type": "object",
|
|
570
|
+
"required": [
|
|
571
|
+
"hint",
|
|
572
|
+
"kind"
|
|
573
|
+
],
|
|
574
|
+
"properties": {
|
|
575
|
+
"hint": {
|
|
576
|
+
"type": "string"
|
|
577
|
+
},
|
|
578
|
+
"kind": {
|
|
579
|
+
"type": "string",
|
|
580
|
+
"enum": [
|
|
581
|
+
"unsupported_pattern"
|
|
582
|
+
]
|
|
583
|
+
}
|
|
584
|
+
}
|
|
585
|
+
}
|
|
586
|
+
]
|
|
587
|
+
},
|
|
588
|
+
"RuleValidationWarning": {
|
|
589
|
+
"description": "A diagnostic about a `RulesConfig` key that the engine couldn't match.\n\nProduced by [`RulesConfig::validate`]. Operators can use these at config-load time to catch typos before any validation work runs.",
|
|
590
|
+
"type": "object",
|
|
591
|
+
"required": [
|
|
592
|
+
"key",
|
|
593
|
+
"reason"
|
|
594
|
+
],
|
|
595
|
+
"properties": {
|
|
596
|
+
"key": {
|
|
597
|
+
"description": "The configured key that triggered the warning.",
|
|
598
|
+
"type": "string"
|
|
599
|
+
},
|
|
600
|
+
"reason": {
|
|
601
|
+
"description": "Why it triggered.",
|
|
602
|
+
"allOf": [
|
|
603
|
+
{
|
|
604
|
+
"$ref": "#/definitions/RuleValidationReason"
|
|
605
|
+
}
|
|
606
|
+
]
|
|
607
|
+
}
|
|
608
|
+
}
|
|
609
|
+
},
|
|
517
610
|
"Severity": {
|
|
518
611
|
"description": "Severity level of validation issues",
|
|
519
612
|
"oneOf": [
|
|
@@ -547,6 +640,135 @@
|
|
|
547
640
|
}
|
|
548
641
|
]
|
|
549
642
|
},
|
|
643
|
+
"Spec": {
|
|
644
|
+
"description": "A document whose rules imferno checks.",
|
|
645
|
+
"oneOf": [
|
|
646
|
+
{
|
|
647
|
+
"description": "SMPTE ST 377-1 — MXF File Format.",
|
|
648
|
+
"type": "string",
|
|
649
|
+
"enum": [
|
|
650
|
+
"ST377-1"
|
|
651
|
+
]
|
|
652
|
+
},
|
|
653
|
+
{
|
|
654
|
+
"description": "SMPTE ST 377-4 — MXF Multichannel Audio Labeling.",
|
|
655
|
+
"type": "string",
|
|
656
|
+
"enum": [
|
|
657
|
+
"ST377-4"
|
|
658
|
+
]
|
|
659
|
+
},
|
|
660
|
+
{
|
|
661
|
+
"description": "SMPTE ST 429-8 — Packing List.",
|
|
662
|
+
"type": "string",
|
|
663
|
+
"enum": [
|
|
664
|
+
"ST429-8"
|
|
665
|
+
]
|
|
666
|
+
},
|
|
667
|
+
{
|
|
668
|
+
"description": "SMPTE ST 429-9 — Asset Mapping and File Segmentation.",
|
|
669
|
+
"type": "string",
|
|
670
|
+
"enum": [
|
|
671
|
+
"ST429-9"
|
|
672
|
+
]
|
|
673
|
+
},
|
|
674
|
+
{
|
|
675
|
+
"description": "SMPTE ST 2067-2 — IMF Core Constraints.",
|
|
676
|
+
"type": "string",
|
|
677
|
+
"enum": [
|
|
678
|
+
"ST2067-2"
|
|
679
|
+
]
|
|
680
|
+
},
|
|
681
|
+
{
|
|
682
|
+
"description": "SMPTE ST 2067-3 — IMF Composition Playlist.",
|
|
683
|
+
"type": "string",
|
|
684
|
+
"enum": [
|
|
685
|
+
"ST2067-3"
|
|
686
|
+
]
|
|
687
|
+
},
|
|
688
|
+
{
|
|
689
|
+
"description": "SMPTE ST 2067-5 — IMF Essence Component.",
|
|
690
|
+
"type": "string",
|
|
691
|
+
"enum": [
|
|
692
|
+
"ST2067-5"
|
|
693
|
+
]
|
|
694
|
+
},
|
|
695
|
+
{
|
|
696
|
+
"description": "SMPTE ST 2067-9 — IMF Sidecar Composition Map.",
|
|
697
|
+
"type": "string",
|
|
698
|
+
"enum": [
|
|
699
|
+
"ST2067-9"
|
|
700
|
+
]
|
|
701
|
+
},
|
|
702
|
+
{
|
|
703
|
+
"description": "SMPTE ST 2067-21 — IMF Application #2E.",
|
|
704
|
+
"type": "string",
|
|
705
|
+
"enum": [
|
|
706
|
+
"ST2067-21"
|
|
707
|
+
]
|
|
708
|
+
},
|
|
709
|
+
{
|
|
710
|
+
"description": "SMPTE ST 2067-201 — IMF IAB Level 0 Plug-in.",
|
|
711
|
+
"type": "string",
|
|
712
|
+
"enum": [
|
|
713
|
+
"ST2067-201"
|
|
714
|
+
]
|
|
715
|
+
},
|
|
716
|
+
{
|
|
717
|
+
"description": "SMPTE ST 2067-202 — IMF ISXD Plug-in.",
|
|
718
|
+
"type": "string",
|
|
719
|
+
"enum": [
|
|
720
|
+
"ST2067-202"
|
|
721
|
+
]
|
|
722
|
+
},
|
|
723
|
+
{
|
|
724
|
+
"description": "The XML Schema layer: findings of the runtime XSD validator against the vendored schema of a document's namespace.",
|
|
725
|
+
"type": "string",
|
|
726
|
+
"enum": [
|
|
727
|
+
"XSD"
|
|
728
|
+
]
|
|
729
|
+
},
|
|
730
|
+
{
|
|
731
|
+
"description": "imferno's own checks (parse failures, package scanning) that no single SMPTE clause defines.",
|
|
732
|
+
"type": "string",
|
|
733
|
+
"enum": [
|
|
734
|
+
"IMFERNO"
|
|
735
|
+
]
|
|
736
|
+
}
|
|
737
|
+
]
|
|
738
|
+
},
|
|
739
|
+
"Strength": {
|
|
740
|
+
"description": "Normative strength of a rule in an edition's text.",
|
|
741
|
+
"oneOf": [
|
|
742
|
+
{
|
|
743
|
+
"description": "A requirement (\"shall\").",
|
|
744
|
+
"type": "string",
|
|
745
|
+
"enum": [
|
|
746
|
+
"shall"
|
|
747
|
+
]
|
|
748
|
+
},
|
|
749
|
+
{
|
|
750
|
+
"description": "A recommendation (\"should\").",
|
|
751
|
+
"type": "string",
|
|
752
|
+
"enum": [
|
|
753
|
+
"should"
|
|
754
|
+
]
|
|
755
|
+
},
|
|
756
|
+
{
|
|
757
|
+
"description": "A permission or an observation (\"may\").",
|
|
758
|
+
"type": "string",
|
|
759
|
+
"enum": [
|
|
760
|
+
"may"
|
|
761
|
+
]
|
|
762
|
+
},
|
|
763
|
+
{
|
|
764
|
+
"description": "Deprecated in this edition.",
|
|
765
|
+
"type": "string",
|
|
766
|
+
"enum": [
|
|
767
|
+
"deprecated"
|
|
768
|
+
]
|
|
769
|
+
}
|
|
770
|
+
]
|
|
771
|
+
},
|
|
550
772
|
"UnreferencedAsset": {
|
|
551
773
|
"type": "object",
|
|
552
774
|
"required": [
|
|
@@ -563,19 +785,25 @@
|
|
|
563
785
|
}
|
|
564
786
|
},
|
|
565
787
|
"ValidationIssue": {
|
|
566
|
-
"description": "A single validation
|
|
788
|
+
"description": "A single validation finding.\n\nCreated only through [`ValidationIssue::from_rule`]: severity, category, clause and display code all come from the rule table row of the edition that was applied.",
|
|
567
789
|
"type": "object",
|
|
568
790
|
"required": [
|
|
569
791
|
"category",
|
|
792
|
+
"clause",
|
|
570
793
|
"code",
|
|
571
794
|
"context",
|
|
795
|
+
"edition",
|
|
572
796
|
"location",
|
|
573
797
|
"message",
|
|
574
|
-
"
|
|
798
|
+
"rule",
|
|
799
|
+
"severity",
|
|
800
|
+
"source",
|
|
801
|
+
"spec",
|
|
802
|
+
"strength"
|
|
575
803
|
],
|
|
576
804
|
"properties": {
|
|
577
805
|
"additional_instances": {
|
|
578
|
-
"description": "Other `Location`s when this issue represents an aggregation of multiple identical-code occurrences (see [`ValidationReport::aggregate`]). Empty for fresh, un-aggregated issues. Skipped during serialisation when empty
|
|
806
|
+
"description": "Other `Location`s when this issue represents an aggregation of multiple identical-code occurrences (see [`ValidationReport::aggregate`]). Empty for fresh, un-aggregated issues. Skipped during serialisation when empty.",
|
|
579
807
|
"type": "array",
|
|
580
808
|
"items": {
|
|
581
809
|
"$ref": "#/definitions/Location"
|
|
@@ -589,8 +817,12 @@
|
|
|
589
817
|
}
|
|
590
818
|
]
|
|
591
819
|
},
|
|
820
|
+
"clause": {
|
|
821
|
+
"description": "Clause of that edition the rule comes from (empty for pseudo-specs without clauses).",
|
|
822
|
+
"type": "string"
|
|
823
|
+
},
|
|
592
824
|
"code": {
|
|
593
|
-
"description": "
|
|
825
|
+
"description": "Display code: `SPEC:EDITION:CLAUSE/Name`, with the edition actually applied (e.g. `ST2067-3:2016:7.2/SegmentDuration`).",
|
|
594
826
|
"type": "string"
|
|
595
827
|
},
|
|
596
828
|
"context": {
|
|
@@ -600,6 +832,10 @@
|
|
|
600
832
|
"type": "string"
|
|
601
833
|
}
|
|
602
834
|
},
|
|
835
|
+
"edition": {
|
|
836
|
+
"description": "Edition of the spec that was applied (`\"2016\"`; empty for single-edition pseudo-specs).",
|
|
837
|
+
"type": "string"
|
|
838
|
+
},
|
|
603
839
|
"location": {
|
|
604
840
|
"description": "Location where issue was found",
|
|
605
841
|
"allOf": [
|
|
@@ -612,8 +848,12 @@
|
|
|
612
848
|
"description": "Human-readable message",
|
|
613
849
|
"type": "string"
|
|
614
850
|
},
|
|
851
|
+
"rule": {
|
|
852
|
+
"description": "Stable, edition-free rule id (`ST2067-3/SegmentDuration`).",
|
|
853
|
+
"type": "string"
|
|
854
|
+
},
|
|
615
855
|
"severity": {
|
|
616
|
-
"description": "Severity level",
|
|
856
|
+
"description": "Severity level (the table default, possibly remapped by a rules config).",
|
|
617
857
|
"allOf": [
|
|
618
858
|
{
|
|
619
859
|
"$ref": "#/definitions/Severity"
|
|
@@ -621,14 +861,29 @@
|
|
|
621
861
|
]
|
|
622
862
|
},
|
|
623
863
|
"source": {
|
|
624
|
-
"description": "Authority that emitted this issue (XSD layer, prose rule, engine internal)
|
|
625
|
-
"default": "EngineInternal",
|
|
864
|
+
"description": "Authority that emitted this issue (XSD layer, prose rule, engine internal), derived from the rule's spec.",
|
|
626
865
|
"allOf": [
|
|
627
866
|
{
|
|
628
867
|
"$ref": "#/definitions/IssueSource"
|
|
629
868
|
}
|
|
630
869
|
]
|
|
631
870
|
},
|
|
871
|
+
"spec": {
|
|
872
|
+
"description": "Spec the rule belongs to.",
|
|
873
|
+
"allOf": [
|
|
874
|
+
{
|
|
875
|
+
"$ref": "#/definitions/Spec"
|
|
876
|
+
}
|
|
877
|
+
]
|
|
878
|
+
},
|
|
879
|
+
"strength": {
|
|
880
|
+
"description": "Normative strength of the rule in that edition.",
|
|
881
|
+
"allOf": [
|
|
882
|
+
{
|
|
883
|
+
"$ref": "#/definitions/Strength"
|
|
884
|
+
}
|
|
885
|
+
]
|
|
886
|
+
},
|
|
632
887
|
"suggestion": {
|
|
633
888
|
"description": "Suggestion for how to fix",
|
|
634
889
|
"type": [
|
|
@@ -672,6 +927,7 @@
|
|
|
672
927
|
"errors",
|
|
673
928
|
"info",
|
|
674
929
|
"is_compliant",
|
|
930
|
+
"is_fully_validated",
|
|
675
931
|
"is_playable",
|
|
676
932
|
"profile",
|
|
677
933
|
"timestamp",
|
|
@@ -703,6 +959,10 @@
|
|
|
703
959
|
"description": "Whether the package is compliant with base SMPTE standards",
|
|
704
960
|
"type": "boolean"
|
|
705
961
|
},
|
|
962
|
+
"is_fully_validated": {
|
|
963
|
+
"description": "Whether everything in the package was validated. False when a finding says part of it was not (e.g. `IMFERNO:Cpl/ExtensionSequenceNotValidated` for S-ADM audio): then `is_compliant` only covers what was checked. A rule override that switches such a finding `off` moves it to `suppressed` but keeps this false.",
|
|
964
|
+
"type": "boolean"
|
|
965
|
+
},
|
|
706
966
|
"is_playable": {
|
|
707
967
|
"description": "Whether the package is playable despite issues",
|
|
708
968
|
"type": "boolean"
|