gui.model.NextAction

gui.model.NextAction(text, view, command)

One suggested next step on the Overview.

Attributes

Name Type Description
text str What to do, in plain words.
view str The view that helps, "check" or "status".
command tuple[str, …] The arguments (without the program name) of the command line that shows the same information.

Examples

from pathlib import Path
from tempfile import TemporaryDirectory

from spotregen import make_sample_repo
from spotregen.gui.model import build_overview, load_repository, run_check

with TemporaryDirectory() as tmp:
    root = make_sample_repo(Path(tmp) / "demo")
    (root / "scripts").mkdir()
    (root / "scripts/use_it.py").write_text("from samplepkg.core import calc\n")
    spec = load_repository(root).spec
    for action in build_overview(spec, run_check(spec)).actions:
        print(action.text, "->", action.view)
Fix 1 error(s) -> check
Declare 1 undeclared consumer(s) -> check