Skip to content

refactor: dataflow scheduler + stripped PipelineGraph API#8

Merged
markovejnovic merged 43 commits into
mainfrom
refactor/tear-out-pipeline-ir
May 24, 2026
Merged

refactor: dataflow scheduler + stripped PipelineGraph API#8
markovejnovic merged 43 commits into
mainfrom
refactor/tear-out-pipeline-ir

Conversation

@markovejnovic
Copy link
Copy Markdown
Contributor

@markovejnovic markovejnovic commented May 23, 2026

No description provided.

@markovejnovic markovejnovic changed the title refactor: extract pipeline IR into dedicated hm-pipeline-ir crate refactor: extract pipeline IR crate + merge harmont-py into monorepo May 23, 2026
@markovejnovic markovejnovic changed the title refactor: extract pipeline IR crate + merge harmont-py into monorepo refactor: extract pipeline IR crate, merge harmont-py, add daggy graph May 23, 2026
Delete Pipeline, Step, WaitStep types and the PipelineGraph::build()
constructor. The JSON wire format is now the petgraph-serde graph
directly — scheduler receives a pre-deserialized PipelineGraph instead
of building one from a flat step list.

CommandStep loses its builds_in field (edges carry that information).
The anyhow dependency is removed from hm-pipeline-ir since nothing
uses it anymore.

Test files in hm-pipeline-ir (graph_build, parse_pipeline,
schema_snapshot) will not compile until their fixtures are rewritten
to the new graph format in the next task.
…rmat

Replace _lower_to_dicts with _lower_to_graph in pipeline.py to emit the
new graph-based wire format (nodes/edges/edge_property/node_holes)
instead of a flat steps list. Update keygen.py to accept a graph dict
and derive parent relationships from builds_in edges. Update all call
sites (json_emit.py, _envelope.py, dev/_registry_dump.py).
Rewrite assertions across 26 test files to match the new graph-based
IR: p["steps"] -> p["graph"]["nodes"], step["type"]/step["builds_in"]
removed, parent relationships read from edges, wait barriers become
depends_on edges, env merged into node dicts.
@markovejnovic markovejnovic changed the title refactor: extract pipeline IR crate, merge harmont-py, add daggy graph Replace flat Pipeline wire format with petgraph-serde graph May 24, 2026
lib.rs now only re-exports from the private graph module.
All downstream imports use hm_pipeline_ir::{PipelineGraph, ...} directly.
…r, rewrite chains() functionally

- NodeWeight → Transition (public), accessed via PipelineGraph::get_transition()
- Replaces separate command_step()/step_env() accessors
- chains() rewritten using std::iter::successors — no mutable placed map
- Removed unused node_indices() method
Walk the DAG in topological order, spawning a Shared<BoxFuture> per
node. Each future awaits its predecessors, acquires a parallelism
permit, then dispatches to the executor plugin. Snapshot lineage
flows through future results — no cross-chain map needed.

Deletes run_chain(); the entire scheduling model is now ~50 lines
in the dataflow loop.
@markovejnovic markovejnovic changed the title Replace flat Pipeline wire format with petgraph-serde graph refactor: dataflow scheduler + stripped PipelineGraph API May 24, 2026
@markovejnovic markovejnovic marked this pull request as ready for review May 24, 2026 03:49
@markovejnovic markovejnovic merged commit 18a7589 into main May 24, 2026
24 checks passed
@markovejnovic markovejnovic deleted the refactor/tear-out-pipeline-ir branch May 24, 2026 03:49
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