BigSaltyMan/cuesmith/compat does not have a README file

    ChangeKind

    pub(all) enum ChangeKind {
    RequiredFieldAdded
    FieldRemoved
    FieldBecameRequired
    TypeNarrowed
    EnumValueRemoved
    BoundsTightened
    RegexTightened
    StructClosed
    ListLengthTightened
    ConstraintAdded
    ValueNarrowed
    OptionalFieldAdded
    FieldBecameOptional
    TypeWidened
    EnumValueAdded
    BoundsWidened
    RegexWidened
    StructOpened
    ListWidened
    DefaultChanged
    ConstraintRelaxed
    ValueWidened
    } derive(Eq,
    Debug
    )

    Fine-grained classification of a schema compatibility change.

    ChangeSeverity

    pub(all) enum ChangeSeverity {
    Breaking
    Compatible
    Info
    } derive(Eq,
    Debug
    )

    Severity classification of a schema compatibility change.

    CompatReport

    pub(all) struct CompatReport {
    compatible : Bool
    breaking_count : Int
    compatible_count : Int
    info_count : Int
    old_source : String
    new_source : String
    changes : Array[SchemaChange]
    } derive(Eq,
    Debug
    )

    Result of comparing an old schema against a new schema.

    DiffOptions

    pub(all) struct DiffOptions {
    old_format : SchemaFormat
    new_format : SchemaFormat
    def_name : String?
    old_label : String
    new_label : String
    limits :
    EvalLimits

    } derive(Eq,
    Debug
    )

    Options controlling diff_schemas.

    DiffOptions::default

    fn DiffOptions::default() -> DiffOptions

    Returns the default DiffOptions (Auto format detection, no def_name, "<old>"/"<new>" labels, default EvalLimits).

    SchemaChange

    pub(all) struct SchemaChange {
    path : Array[String]
    severity : ChangeSeverity
    kind : ChangeKind
    rule_id : String
    message : String
    old_summary : String
    new_summary : String
    } derive(Eq,
    Debug
    )

    A single detected compatibility change between two schemas at path.

    SchemaFormat

    pub(all) enum SchemaFormat {
    Auto
    Cue
    JsonSchema
    OpenApi
    } derive(Eq,
    Debug
    )

    Input schema format for compatibility diffing.

    diff_packages

    fn diff_packages(fs :
    ModuleFs
    , old_dir : String, new_dir : String, def_name? : String, old_pkg? : String, new_pkg? : String, cwd? : String, limits? :
    ModLimits
    ) -> Result[CompatReport, Array[
    CueError
    ]]

    Evaluates and compares two CUE packages via @modsys.ModuleFs.

    diff_schemas

    fn diff_schemas(old_source : String, new_source : String, options? : DiffOptions) -> Result[CompatReport, Array[
    CueError
    ]]

    Compares two schema sources (CUE, JSON Schema, or OpenAPI 3.0/3.1), auto-detecting formats when options.old_format / options.new_format is Auto, and returns a CompatReport.

    diff_values

    Compares two evaluated @eval.Value schemas and returns a detailed CompatReport backed by @eval.subsumes_with_options.

    format_json

    fn format_json(report : CompatReport, indent? : Int) -> String

    Formats a CompatReport as deterministic RFC 8259 JSON.

    format_json_bounded

    fn format_json_bounded(report : CompatReport, max_output_bytes : Int, indent? : Int) -> Result[String,
    LimitError
    ]

    Formats a CompatReport as deterministic RFC 8259 JSON while enforcing max_output_bytes before/during indentation and text writes.

    format_markdown

    fn format_markdown(report : CompatReport) -> String

    Formats a CompatReport as GitHub-Flavored Markdown suitable for $GITHUB_STEP_SUMMARY or PR comments.

    format_markdown_bounded

    fn format_markdown_bounded(report : CompatReport, max_output_bytes : Int) -> Result[String,
    LimitError
    ]

    Formats a CompatReport as GitHub-Flavored Markdown while enforcing max_output_bytes during output generation.

    format_sarif

    fn format_sarif(report : CompatReport, indent? : Int) -> String

    Formats a CompatReport as SARIF 2.1.0 JSON suitable for CI code-scanning gates.

    format_sarif_bounded

    fn format_sarif_bounded(report : CompatReport, max_output_bytes : Int, indent? : Int) -> Result[String,
    LimitError
    ]

    Formats a CompatReport as SARIF 2.1.0 JSON while enforcing max_output_bytes before/during indentation and text writes.

    format_text

    fn format_text(report : CompatReport) -> String

    Formats a CompatReport as a human-readable text report.

    format_text_bounded

    fn format_text_bounded(report : CompatReport, max_output_bytes : Int) -> Result[String,
    LimitError
    ]

    Formats a CompatReport as a human-readable text report while enforcing max_output_bytes during output generation.

    Source Files