Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Non-JSON output with --format sarif #78

Open
homersimpsons opened this issue Dec 12, 2023 · 0 comments
Open

Non-JSON output with --format sarif #78

homersimpsons opened this issue Dec 12, 2023 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@homersimpsons
Copy link

homersimpsons commented Dec 12, 2023

Issue

The following command does not output JSON-only in STDOUT:

$ docker scout cves --format sarif nginx:1.8-alpine 2>/dev/null

Diagnostic

The above command outputs a "What's next" message that breaks the JSON output making it hard to parse with traditional tools:

$ docker scout cves --format sarif nginx:1.8-alpine 2>/dev/null | tail          ]
        }
      ]
    }
  ]
}

What's Next?
  View base image update recommendations → docker scout recommendations nginx:1.8-alpine



Possible fix

This message should be output in STDERR, just like the other "general messages".

I know it is possible to use --output flag, but I would prefer using STDOUT directly instead of having to manage temporary files.

(I have the latest version, the source code looks closed, so I cannot really dig further myself)

@cdupuis cdupuis added the bug Something isn't working label Dec 12, 2023
@cdupuis cdupuis self-assigned this Jan 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants