pyk.proof.reachability module¶
- class APRFailureInfo(failing_nodes: 'Iterable[int]', pending_nodes: 'Iterable[int]', path_conditions: 'Mapping[int, str]', failure_reasons: 'Mapping[int, str]', models: 'Mapping[int, Iterable[tuple[str, str]]]')[source]¶
Bases:
FailureInfo
- failing_nodes: frozenset[int]¶
- failure_reasons: FrozenDict[int, str]¶
- static from_proof(proof: APRProof, kcfg_explore: KCFGExplore, counterexample_info: bool = False) APRFailureInfo [source]¶
- models: FrozenDict[int, frozenset[tuple[str, str]]]¶
- path_conditions: FrozenDict[int, str]¶
- pending_nodes: frozenset[int]¶
- class APRProof(id: str, kcfg: KCFG, terminal: Iterable[int], init: NodeIdLike, target: NodeIdLike, logs: dict[int, tuple[LogEntry, ...]], bmc_depth: int | None = None, bounded: Iterable[int] | None = None, proof_dir: Path | None = None, node_refutations: dict[int, str] | None = None, subproof_ids: Iterable[str] = (), circularity: bool = False, admitted: bool = False, _exec_time: float = 0, error_info: Exception | None = None, prior_loops_cache: dict[int, list[int]] | None = None)[source]¶
Bases:
Proof
,KCFGExploration
APRProof and APRProver implement all-path reachability logic, as introduced by A. Stefanescu and others in their paper ‘All-Path Reachability Logic’: https://doi.org/10.23638/LMCS-15(2:5)2019 Note that reachability logic formula phi =>A psi has not the same meaning as CTL/CTL*’s phi -> AF psi, since reachability logic ignores infinite traces. This implementation extends the above with bounded model checking, allowing the user to specify an optional loop iteration bound for each loop in execution.
- bmc_depth: int | None¶
- property can_progress: bool¶
- circularity: bool¶
- commit(result: StepResult) None [source]¶
- construct_node_refutation(node: Node) RefutationProof | None [source]¶
- property dict: dict[str, Any]¶
- error_info: Exception | None¶
- property exec_time: float¶
- static from_claim(defn: KDefinition, claim: KClaim, logs: dict[int, tuple[LogEntry, ...]], proof_dir: Path | None = None, bmc_depth: int | None = None, **kwargs: Any) APRProof [source]¶
- static from_spec_modules(defn: KDefinition, spec_modules: KFlatModuleList, logs: dict[int, tuple[LogEntry, ...]], proof_dir: Path | None = None, spec_labels: Iterable[str] | None = None, **kwargs: Any) list[APRProof] [source]¶
- init: int¶
- property module_name: str¶
- node_refutations: dict[int, RefutationProof]¶
- property own_status: ProofStatus¶
- prior_loops_cache: dict[int, list[int]]¶
- refute_node(node: Node) RefutationProof | None [source]¶
- shortest_path_to(node_id: NodeIdLike) tuple[KCFG.Successor, ...] [source]¶
- property summary: CompositeSummary¶
- target: int¶
- class APRProofBoundedResult(node_id: 'int')[source]¶
Bases:
APRProofResult
- class APRProofExtendResult(node_id: 'int', extend_result: 'KCFGExtendResult')[source]¶
Bases:
APRProofResult
- extend_result: KCFGExtendResult¶
- class APRProofResult(node_id: 'int')[source]¶
Bases:
StepResult
- node_id: int¶
- class APRProofSubsumeResult(node_id: 'int', csubst: 'CSubst')[source]¶
Bases:
APRProofResult
- class APRProofTerminalResult(node_id: 'int')[source]¶
Bases:
APRProofResult
- class APRProver(proof: APRProof, kcfg_explore: KCFGExplore, execute_depth: int | None = None, cut_point_rules: Iterable[str] = (), terminal_rules: Iterable[str] = (), counterexample_info: bool = False, always_check_subsumption: bool = True, fast_check_subsumption: bool = False)[source]¶
Bases:
Prover
- always_check_subsumption: bool¶
- circularities_module_name: str¶
- counterexample_info: bool¶
- cut_point_rules: Iterable[str]¶
- dependencies_module_name: str¶
- execute_depth: int | None¶
- failure_info() FailureInfo [source]¶
- fast_check_subsumption: bool¶
- main_module_name: str¶
- step_proof() Iterable[StepResult] [source]¶
- terminal_rules: Iterable[str]¶
- class APRSummary(id: 'str', status: 'ProofStatus', admitted: 'bool', nodes: 'int', pending: 'int', failing: 'int', vacuous: 'int', stuck: 'int', terminal: 'int', refuted: 'int', bmc_depth: 'int | None', bounded: 'int', subproofs: 'int', formatted_exec_time: 'str')[source]¶
Bases:
ProofSummary
- admitted: bool¶
- bmc_depth: int | None¶
- bounded: int¶
- failing: int¶
- formatted_exec_time: str¶
- id: str¶
- property lines: list[str]¶
- nodes: int¶
- pending: int¶
- refuted: int¶
- status: ProofStatus¶
- stuck: int¶
- subproofs: int¶
- terminal: int¶
- vacuous: int¶