feat(ogar-from-rails): extract_app — opt-in Rails engine walking (consumes ruff#28)#75
Merged
Merged
Conversation
Threads through ruff#28's extract_app_with so producers can opt into walking the core app/models PLUS every mounted engine's app/models (modules/*, engines/*). OpenProject keeps a large share of its domain in modules/* engines (TimeEntry lives in modules/costs/app/models), invisible to the existing core-only extract / extract_with. New API (additive): - pub fn extract_app_with(path, curator) — whole-app harvest tagged with the curator namespace; cross-root reopen-merge handled by ruff. - pub fn extract_app(path) — defaults to "openproject" curator. Existing extract / extract_with stay core-only (backward compatible). Tests: - nonexistent_source_tree_yields_empty_vec extended to cover the two new no-panic paths. - extract_app_harvests_openproject_modules (env-gated, real corpus) — extract_app strictly exceeds extract; the harvested TimeEntry maps onto billable_work_entry/0x0103 and carries source_curator="openproject"; core-only definitively does NOT see modules/costs/TimeEntry (regression guard on the gap). Closes the modular-engine extraction gap on the producer side, which unblocks completing the billable_work_entry bridge in redmine-rs (OP's TimeEntry was previously invisible and the bridge was Redmine-only).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Wires AdaWorldAPI/ruff#28's
extract_app_with/extract_appintoogar-from-rails, so producers can opt into harvesting the whole Rails application (coreapp/modelsplus every mounted engine'sapp/models).New API (purely additive):
pub fn extract_app_with(path, curator) -> Vec<Class>— whole-app harvest tagged with the curator namespace.pub fn extract_app(path) -> Vec<Class>— defaults to"openproject"curator.Existing
extract/extract_withstay core-only (backward compatible). Engines are opt-in.Why
OpenProject keeps a large share of its domain in
modules/*engines (e.g.TimeEntrylives inmodules/costs/app/models). With the old core-only walk, OP's side of thebillable_work_entry(0x0103) bridge was empty — Redmine'sTimeEntrylifted but OpenProject's didn't, understating the OP↔Redmine convergence.Tests
extract_app_harvests_openproject_modules(env-gated, real corpus):extract_appstrictly exceeds core-onlyextract.TimeEntrymaps ontobillable_work_entry/0x0103and carriessource_curator="openproject".modules/costs/TimeEntry(regression guard on the gap).nonexistent_source_tree_yields_empty_vecextended to cover the two new no-panic paths.Workspace check + test green.
Unblocks
A follow-up regen on
AdaWorldAPI/redmine-rs(callingextract_app_with("openproject")instead ofextract_with) will populate the OP side ofbillable_work_entryand flip the cross-fork convergence from 25/26 → 26/26 shared.