[PR #534] [MERGED] fix(native): match compound otool keys exactly and badge unknown thread entrypoints #2056

Closed
opened 2026-10-16 21:13:48 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/morluto/rea/pull/534
Author: @morluto
Created: 10/5/2026
Status: ✅ Merged
Merged: 10/5/2026
Merged by: @morluto

Base: main ← Head: cleanup/native-key-and-coverage


📝 Commits (1)

  • 4ec14d5 fix(native): match compound otool keys exactly and badge unknown thread entrypoints

📊 Changes

3 files changed (+54 additions, -12 deletions)

View changed files

📝 src/native/NativeMachoInspection.ts (+16 -10)
📝 src/native/parsers/otool.ts (+5 -1)
📝 tests/boundary/providers/native/nativeLoadKinds.golden.test.ts (+33 -1)

📄 Description

Addresses two review findings on #531/#532 — both confirmed by reproducing the input first.

1. Over-greedy stamp suffix (#531). The key regex I widened to (?:version|stamp) matched stamp after any key. Verified: name stamp plugin.dylib (offset 24) parsed to key name stamp, and since collectDependency reads name, the observed dependency path became unknown — a real regression on a legitimate install name. Now matches the one real compound key time stamp as a whole and keeps the generic token version rule separate.

2. entrypoints claimed exhaustive while acknowledged as undecoded (#532). With only LC_UNIXTHREAD/LC_THREAD, the global limitation said the entrypoint was not decoded, but the facet still returned total: 0, exhaustive: true — exactly the false-absence the product direction forbids, and a consumer reading the facet (not the global limitations) would see an observed absence. The facet now returns exhaustive: false, total: null and carries the limitation locally, matching how imports/exports already scope theirs.

Tests: added a stamp plugin.dylib dependency case and tightened the thread-entrypoint test to assert the non-exhaustive facet. All 44 native boundary tests, tsc, oxlint and check:fast green.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/morluto/rea/pull/534 **Author:** [@morluto](https://github.com/morluto) **Created:** 10/5/2026 **Status:** ✅ Merged **Merged:** 10/5/2026 **Merged by:** [@morluto](https://github.com/morluto) **Base:** `main` ← **Head:** `cleanup/native-key-and-coverage` --- ### 📝 Commits (1) - [`4ec14d5`](https://github.com/morluto/rea/commit/4ec14d5cb47d817cd5cf1f15bdde60579040ea71) fix(native): match compound otool keys exactly and badge unknown thread entrypoints ### 📊 Changes **3 files changed** (+54 additions, -12 deletions) <details> <summary>View changed files</summary> 📝 `src/native/NativeMachoInspection.ts` (+16 -10) 📝 `src/native/parsers/otool.ts` (+5 -1) 📝 `tests/boundary/providers/native/nativeLoadKinds.golden.test.ts` (+33 -1) </details> ### 📄 Description Addresses two review findings on #531/#532 — both confirmed by reproducing the input first. **1. Over-greedy `stamp` suffix (#531).** The key regex I widened to `(?:version|stamp)` matched `stamp` after *any* key. Verified: `name stamp plugin.dylib (offset 24)` parsed to key `name stamp`, and since `collectDependency` reads `name`, the observed dependency path became `unknown` — a real regression on a legitimate install name. Now matches the one real compound key `time stamp` as a whole and keeps the generic `token version` rule separate. **2. `entrypoints` claimed exhaustive while acknowledged as undecoded (#532).** With only `LC_UNIXTHREAD`/`LC_THREAD`, the global limitation said the entrypoint was not decoded, but the facet still returned `total: 0, exhaustive: true` — exactly the false-absence the product direction forbids, and a consumer reading the facet (not the global limitations) would see an observed absence. The facet now returns `exhaustive: false, total: null` and carries the limitation locally, matching how `imports`/`exports` already scope theirs. Tests: added a `stamp plugin.dylib` dependency case and tightened the thread-entrypoint test to assert the non-exhaustive facet. All 44 native boundary tests, tsc, oxlint and check:fast green. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-16 21:13:48 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
morluto/rea#2056
No description provided.