Skip to content

CLI validate command hates long lines #2491

Open
@kubukoz

Description

When you run validate, build or any other command that validates your model, if the sourceLocation in the validation events points to a compact JSON file (say, one of the AWS specs), the CLI will output basically a bunch of blank lines which will look terrible in the terminal.

Even with a smaller JSON file, like:

{"smithy":"2.0","shapes":{"example.weather#Home":{"type":"operation","input":{"target":"smithy.api#Unit"},"output":{"target":"smithy.api#Unit"},"traits":{"smithy.api#http":{"method":"GET","uri":"/"}}},"example.weather#Weather":{"type":"service","operations":[{"target":"example.weather#Home"}]}}}

Running validate yields:

image

which doesn't seem very useful with the source location.

Note: it's entirely possible that I've already reported this, because I remember writing about it, but I can't find any issue for this.

Metadata

Assignees

No one assigned

    Labels

    needs-discussionThis issue/PR requires more discussion with community.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions