From a5bb4444ecb4987a4ce2b4ff72b030ce79740ab5 Mon Sep 17 00:00:00 2001 From: idatui Date: Sun, 9 Aug 2026 13:44:10 +0200 Subject: Graph: name the interpreter when pytriskel is missing ./ida-tui runs $IDATUI_PYTHON (default ~/ida-venv), which is not the repo .venv the tests use -- so the graph view can report pytriskel as missing while tests/test_graph.py is exercising both engines. "not installed" on its own sends you to check the wrong python; the status now names sys.executable, and docs/GRAPH_VIEW.md says to install into both. --- docs/GRAPH_VIEW.md | 12 +++++++++++- idatui/app.py | 7 ++++++- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/docs/GRAPH_VIEW.md b/docs/GRAPH_VIEW.md index ea1f84d..d588b3d 100644 --- a/docs/GRAPH_VIEW.md +++ b/docs/GRAPH_VIEW.md @@ -217,10 +217,20 @@ drive raw graph action=zoom It is optional; without it everything works and `auto` means `native`. +**Install it into the interpreter the launcher actually runs**, which is +`$IDATUI_PYTHON` and defaults to `~/ida-venv/bin/python` — *not* the repo's +`.venv`, which is only what the tests use. Getting this wrong is the one way to +see `no pytriskel in ...` in the status bar while `tests/test_graph.py` happily +exercises both engines; the message names the interpreter for that reason. + ```bash -uv pip install ~/dev/triskel/bindings/python # needs cmake, ninja, a C++23 compiler +~/ida-venv/bin/python -m pip install ~/dev/triskel/bindings/python +.venv/bin/python -m pip install ~/dev/triskel/bindings/python # for the tests ``` +Needs cmake, ninja and a C++23 compiler at install time; the wheel is built from +source for whichever interpreter runs pip. + That is **our fork**, not PyPI. Upstream's wheels stop at cp313 with no sdist (so there is nothing to install on 3.14), and on any version their `get_waypoints()` raises, which means no edge routes at all. `~/dev/triskel/PATCHES.md` diff --git a/idatui/app.py b/idatui/app.py index 76aff62..b2b1722 100644 --- a/idatui/app.py +++ b/idatui/app.py @@ -20,6 +20,7 @@ import asyncio import os import re import subprocess +import sys import time from dataclasses import dataclass, field from enum import StrEnum @@ -2679,7 +2680,11 @@ class GraphView(NavMixin, ScrollView, can_focus=True): self._center_cursor() self.refresh(layout=True) got = self.lay.stats["engine"] if self.lay else "?" - note = "" if graph_triskel.available() else " (pytriskel not installed)" + # Name the interpreter. The launcher runs $IDATUI_PYTHON (default + # ~/ida-venv), which is NOT the repo .venv the tests use, so "not + # installed" on its own sends people to check the wrong python. + note = ("" if graph_triskel.available() + else f" (no pytriskel in {sys.executable})") self.app._status(f"graph: engine {self._engine} \u2192 {got}{note}") def action_center(self) -> None: -- cgit v1.3.1-sl0p