Describe the bug
On macOS where we don't analyze package data we throw a very large number of errors when getting platform data. We shouldn't be throwing this 12 times for the user when it's an expected issue on macOS.
To Reproduce
Steps to reproduce the behavior:
run cnspec shell
run `platform {*}
See error
Expected behavior
Warnings in the sections of the data structure that we can't fix
Screenshots or CLI Output
~/dev cnspec shell
→ no provider specified, defaulting to local.
Use --help for a list of available providers.
→ loaded configuration from /Users/tsmith/.config/mondoo/mondoo.yml using source default
→ discover related assets for 1 asset(s)
→ resolved assets resolved-assets=1
___ _ __ ___ _ __ ___ ___
/ __| '_ \/ __| '_ \ / _ \/ __|
| (__| | | \__ \ |_) | __/ (__
\___|_| |_|___/ .__/ \___|\___|
mondoo™ |_|
cnspec> platform {*}
Query encountered errors:
12 errors occurred:
* rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
* rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
* rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
* rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
* rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
* rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
* rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
* rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
* rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
* rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
* rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
* rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
platform: {
arch: "arm64"
kind: "baremetal"
virtualization: platform.virtualization id = platform.virtualization
name: "macos"
labels: {}
fqdn: ""
platform.cves.list: rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
runtime: ""
vulnerabilityReport: rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
build: "22D68"
title: "macOS, bare metal"
platform.advisories.list: rpc error: code = InvalidArgument desc = package analysis is not supported for the provided platform
family: [
0: "darwin"
1: "bsd"
2: "unix"
3: "os"
]
version: "13.2.1"
runtimeEnv: ""
release: "13.2.1"
}
cnspec>
Desktop (please complete the following information):
The errors printed ahead of data seem to be 4x the actual error in the data. Running os.base shows 4 errors for the single os.base.rebootpending value that can't be returned
Describe the bug On macOS where we don't analyze package data we throw a very large number of errors when getting platform data. We shouldn't be throwing this 12 times for the user when it's an expected issue on macOS.
To Reproduce Steps to reproduce the behavior:
cnspec shell
Expected behavior Warnings in the sections of the data structure that we can't fix
Screenshots or CLI Output
Desktop (please complete the following information):