Repository navigation
fix(omp): resolve host modules and tokenizer from plugin runtime - #655
randomvariable wants to merge 2 commits into
Conversation
|
Design gate skipped: the |
There was a problem hiding this comment.
All reported issues were addressed across 6 files
Reply with feedback, questions, or to request a fix.
View guided diff | Re-trigger cubic
|
Thanks for this, and for splitting it from the discovery change. Before review, please address the open bot finding. Greptile notes that the new tokenizer-roots test may not exercise the fallback: Once the finding is resolved, we'll take it through review. |
|
Addressed all three threads in 3b046f4. The runtime fixture forces the primary loader to fail under bun --no-install and proves fallback estimator identity. A second fixture proves the plugin dependency beats a conflicting host-wide copy. Three focused tests, plugin typecheck, and Pi build passed. Negative control with the old probe ordering fails the precedence regression. Refs #657 for maintainer design approval. |
|
Want your agent to iterate on Greptile's feedback? Try greploops. |
|
Thanks for resolving the findings. I've labelled this
Affected: "the fallback loads from the plugin tree when the primary loader fails" and "the plugin's own tree outranks the host-wide ~/.omp/plugins copy". Could you rebase onto master and have the fixture copy |
Refs #657
Fix compiled OMP host-module imports and tokenizer runtime fallback resolution. Preserve package-local tokenizer precedence.
Independent of PR #656. Initial standalone verification: typecheck, build, 29 focused tests. Review regression improvements are in progress.

Confidence Score: 5/5
The PR appears safe to merge, with no new actionable issues found.Summary
The PR keeps host-package imports available for OMP to resolve at runtime and adds tokenizer lookup paths for plugin installs.
Diagram
%%{init: {'theme': 'neutral'}}%% flowchart TD A["preloadTokenizer()"] --> B["Load relative to import.meta.url"] B -->|Succeeds| C["Use tokenizer"] B -->|Fails| D["Probe project and OpenCode cache"] D --> E["Probe argv and module ancestors"] E --> F["Probe OMP plugin tree"] F --> G["Import first matching package"] G -->|Succeeds| C G -->|Fails| H["Use approximate counts"]Reviews (2) · Last reviewed commit: "fix(tokenizer): prove fallback loading a..." · Reviewed by Greptile