v0.7.0
TL;DR
Eleven new rules across four rule families (temporal, install/build/maintainer, naming, dependency-set), seven crash-bug fixes, python -m trustsight support, and fire rates measured for R068-R073 on the 3246-diff benign corpus.
Added
-
Temporal context rules (R065-R067). Three code-emitted rules that inspect git commit timestamps on the AUR repository rather than diff content. All are on by default with no config toggle.
Rule Name Severity Condition R065 Very Recent Update INFO (w 0) HEAD commit < 72 h old R066 Brand New Package INFO (w 0) First AUR commit < 30 days old R067 Stale Package Revived MEDIUM (w 15) Gap to last analyzed commit > 365 days -
Install, build, and maintainer rules (R068-R073). Six code-emitted rules that inspect install hooks, GPG verification removal, build environment subversion, maintainer takeovers, capability density, and release cadence.
Rule Name Severity Category Condition R068 Install Hook Present INFO (w 0) context PKGBUILD declares install=or diff touches*.installR069 GPG Verification Removed HIGH (w 25) integrity validpgpkeyspopulated before, empty/absent afterR070 Build Environment Subversion HIGH/MEDIUM (w 25/15) build LD_PRELOAD/LD_LIBRARY_PATH(HIGH) orCFLAGS/LDFLAGS/MAKEFLAGS/PATH(MED) set inside build functionR071 Untrusted Maintainer Takeover HIGH (w 25) maintainer Maintainer changed + new maintainer globally novel R072 Capability Density Anomaly INFO (w 0) meta Rule hits span 3+ distinct categories R073 Accelerated Release Cadence metadata (never scored) temporal-metadata HEAD has 3+ ancestors in the last 24 h All R068-R073 are always on, gated only by diff content or database
maturity rather than an experimental flag. -
Naming and dependency-set rules (R074-R075). Two code-emitted rules that detect package-name typosquatting and aggregate dependency-set expansion. Both are always on, gated only by a cold-start maturity check.
Rule Name Severity Category Condition R074 Package-Name Typosquat HIGH (w 25) naming Name within edit-distance 2 of a far-more-popular package, not a variant R075 Dependency-Set Expansion MEDIUM (w 15) dependency Diff adds 3+ deps whose count x mean-rarity exceeds gate (>= 1.5) R074 uses seed popularity data and requires a warmed database. R075 is fully corpus-calibratable.
-
Fire rates measured for R068-R075 on the 3246-diff benign corpus. All scored rules pass the 30% gate:
Rule Severity Fire rate Hits R068 INFO 20.95 % 680/3246 R069 HIGH 0.03 % 1/3246 R070 HIGH/MED 0.25 % 8/3246 R072 INFO 15.87 % 515/3246 R074 HIGH 1.12 % 2/179 pkgs R075 MEDIUM 0.34 % 11/3246 R071 and R073 require live git history and are marked TBD in fire-rates.md.
-
python -m trustsightsupport. Addedsrc/trustsight/__main__.pyso the tool works withpython -m trustsightin addition to the installed CLI script.
Fixed
-
Seven crash bugs (B1-B6, B10) that prevented the tool from running on unusual package states or missing dependencies:
ID Issue Fix B1 pygit2.GitErrorraisedNameErrorat runtime because pygit2 was not imported inanalysis.pyAdded import pygit2at module levelB2 generate_diffcrashes on stale commit OIDs that produceNonecommitsGuard against Nonebefore accessing.treeB3 get_head_commitpropagatesGitErrorfor empty/unborn reposWrapped in try/except, returns ""on failureB4 One bad package in a batch aborts the entire scan Per-package try/except around analyze_packagein CLI loopB5 Tool crashes on startup when richis not installedGuard console()and fallback paths withHAS_RICHchecksB6 Seed-import message leaks into JSON stdout with --jsonPass quiet=Truetomaybe_auto_import_seedin JSON modeB10 _simple_vercmpcompares version parts lexicographically (e.g.9>10)Parse as integers before comparison -
old_versionwas hardcoded to empty string. Now queriespacman -Qto populate the installed version, so the LLM verdict shows the correct version range. -
Stored empty commit treated as "no history" on every subsequent run, looping back to
_make_fresh_analysis. Changed the guard to distinguish "no record" from "record with empty commit." -
Zero-line diff shown unconditionally even when no diff was computed. Now guarded behind
lines_addedorlines_removed. -
fallback_verdict()always said "Version bump" regardless of whether version data existed. Now checksfirst_seenand returns a context-appropriate message. -
python-openaimoved to optdepends to avoid httpx conflict with thehttpxCLI package. The import is lazy, so the conflict only arises when verdict generation is invoked, not at CLI startup. -
D001/D004 tests now seed enough observations to fire correctly after the default-true promotion in v0.6.1.
Stats
- 11 commits since v0.6.1
- 702 tests (19 files), all passing
- Package version 0.7.0