Skip to content

refactor(op): Create plan provider, flatten plan namespace (#264) - #266

Merged
David-Noble-at-work merged 3 commits into
developfrom
refactor/extract-starlark-from-op
Mar 25, 2026
Merged

David-Noble-at-work merged 3 commits into
developfrom
refactor/extract-starlark-from-op

Conversation

@David-Noble-at-work

Copy link
Copy Markdown
Contributor

Summary

Phase 1 of #264 — extract starlark infrastructure from pkg/op into pkg/op/bind.

  • Plan Provider (pkg/op/provider/plan/) — executing receiver whose methods create graph nodes during script evaluation. Methods: Complete, Degraded, Fatal, WaitUntil, Gather, Choose
  • PlanRoot — thin namespace assembly: plan Provider's ExecutingReceiver + sub-namespace attributes (plan.file, plan.git, etc.)
  • Flat plan namespace — plan.flow.complete -> plan.complete, plan.flow.degraded -> plan.degraded, etc.
  • Removed flow/planned.go (methods moved to plan Provider), plan.source (redundant with plan.file.read_text)
  • PlanReceiverFactory interface — plan provider creates its ExecutingReceiver with (graph, project, reg) instead of (ctx)
  • Unmarshal enhancement — Go pointer handles (e.g., *Promise) pass through as-is in unmarshalValue and unmarshalToAny
  • Regenerated receiver code from updated doc-comment template

Deferred to Phase 1.50

  • **kwargs support in ExecutingReceiver bridge (needed for plan.degraded/plan.fatal template kwargs)

Test plan

  • make test — all packages pass
  • make lint — 198 issues (matches develop baseline)
  • make vet — clean
  • devlore-test scripts updated and passing
  • flow integration tests rewritten to use plan Provider

David Noble added 3 commits March 25, 2026 11:05
Phase 1 of extracting starlark from pkg/op. The plan Provider is an
executing receiver whose methods create graph nodes during script
evaluation.

- Create pkg/op/provider/plan with Provider (Complete, Degraded, Fatal,
  WaitUntil, Gather, Choose) and factory (PlanReceiverFactory)
- PlanRoot becomes thin namespace assembly: plan Provider's
  ExecutingReceiver + sub-namespace attributes
- Flatten plan namespace: plan.flow.complete -> plan.complete, etc.
- Delete flow/planned.go (methods moved to plan Provider)
- Remove PlanningReceiverFactory from flowProvider
- Remove plan.source (redundant with plan.file.read_text)
- Add PlanReceiverFactory interface to pkg/op/provider.go
- Add Go pointer handle passthrough to unmarshal infrastructure
- Update devlore-test scripts for flat namespace
- Regenerated receiver code from updated doc-comment template
Phase 1 of extracting starlark from pkg/op. The plan Provider is an
executing receiver whose methods create graph nodes during script
evaluation.

- Create pkg/op/provider/plan with Provider (Complete, Degraded, Fatal,
  WaitUntil, Gather, Choose) and factory (PlanReceiverFactory)
- PlanRoot becomes thin namespace assembly: plan Provider's
  ExecutingReceiver + sub-namespace attributes
- Flatten plan namespace: plan.flow.complete -> plan.complete, etc.
- Delete flow/planned.go (methods moved to plan Provider)
- Remove PlanningReceiverFactory from flowProvider
- Remove plan.source (redundant with plan.file.read_text)
- Add PlanReceiverFactory interface to pkg/op/provider.go
- Add Go pointer handle passthrough to unmarshal infrastructure
- Update devlore-test scripts for flat namespace
- Regenerated receiver code from updated doc-comment template
…actor/devlore-cli into refactor/extract-starlark-from-op
@David-Noble-at-work
David-Noble-at-work merged commit a3fcbe5 into develop Mar 25, 2026
2 checks passed
@David-Noble-at-work
David-Noble-at-work deleted the refactor/extract-starlark-from-op branch March 25, 2026 18:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant