KernelDB.check_report()
Everything the check command reports, as data (#46).
Usage
KernelDB.check_report(
mk_path, *, mission=None, hash_=False, remote=False, spice=False
)Runs check_metakernel (present), verify_metakernel (resolves, with SHA-256 checks when hash_ is set) and, only when remote is set, verify_against_server and newer_remote_version. Those two are the only network calls. check_metakernel itself prints nothing and touches no network.
The three verdicts, each a bit of the exit code, are:
- 1,
present: every kernel of the metakernel is on disk; - 2,
resolves: every entry resolves soundly throughPATH_VALUESand matches the database; - 4,
matches remote: every local kernel matches the server (only with remote).
Parameters
mk_path: str | Path-
Any reference resolve_metakernel accepts.
mission: str | None = None-
Mission name for preferred-mission resolution.
hash_: bool = False-
Verify SHA-256 hashes: recompute them for the
resolvesverdict and, with remote, compare them against the server. remote: bool = False-
Compare the local kernels with the server. This is the one network path.
spice: bool = False- With remote, also furnsh each local kernel in an isolated kernel pool and report what SPICE refuses to read. Needs SpiceyPy.
Returns
dict-
With the keys:
mk_path: the resolved path, as a stringpresent: the raw result of check_metakernelresolves: the raw result of verify_metakernelremote: the raw result of verify_against_server, orNonewithout remotenewer: the newer-version notice, orNoneverdicts: the three verdicts as{bit, ok, line}rows.okisTrue,False, orNonewhen the verdict was not checked- exit_code: the sum of the failed verdicts’ bits, 0 to 7
Raises
MetakernelNotTracked-
mk_path matches nothing.
AmbiguousMetakernel- mk_path matches several registry rows.