Skip to content

No error reported when file provided in input does not exists  #2675

@LasneF

Description

@LasneF

Describe the bug
running spectral on an non existing file does return that all is fine

To Reproduce

spectral lint bob --ruleset .spectral.spectral.yaml

with no file called bob
return

"No results with a severity of 'error' found!"

Expected behavior
a message indicating that bob file does not exists and return error exit code

Environment (remove any that are not applicable):

  • OS: Windows
  • Spectral ; 6.11.1

Additional context
if i set a wrong ruleset i have a nice error message ,
"Could not read ruleset" , i would expect the same cannot read the api decription file

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions