Skip to content

Implement full_build orchestration with manifest, domestication, assembly_lvl1, transformation, and plating#51

Merged
Gonza10V merged 4 commits into
full_buildfrom
codex/implement-buildcompiler.full_build-method
Apr 30, 2026
Merged

Implement full_build orchestration with manifest, domestication, assembly_lvl1, transformation, and plating#51
Gonza10V merged 4 commits into
full_buildfrom
codex/implement-buildcompiler.full_build-method

Conversation

@Gonza10V
Copy link
Copy Markdown
Contributor

Motivation

  • Provide a single high-level orchestration entrypoint to run the BuildCompiler workflow end-to-end through domestication, level‑1 assembly, transformation, and plating while explicitly skipping level‑2 for now.

Description

  • Added BuildCompiler.full_build(...) to normalize inputs (single/list/CombinatorialDerivation), preflight missing parts, domesticate unique missing parts, index domestication products, run transformation and plating for domestication outputs, run assembly_lvl1 per design, then transform & plate assembly outputs, and record an explicit assembly_lvl2 skip in the manifest.
  • Implemented helpers: _normalize_full_build_designs, _expand_combinatorial_derivation, _find_missing_parts_for_lvl1, _index_domestication_products, _safe_display_id, _serialize_sbol_identity, _write_json, _status_from_manifest, and _zip_full_build_results, plus small robustness fixes (fallback for domestication indexing).
  • Produce a structured manifest (full_build_manifest.json), attempt to write SBOL to sbol/full_build.xml, and package the results directory into full_build_results.zip.
  • Files changed: src/buildcompiler/buildcompiler.py (implementation + helpers) and tests/test_full_build.py (unit tests covering normalization, combinatorial expansion, missing‑part detection, domestication orchestration, assembly orchestration, skip behavior, and packaging).

Testing

  • Added tests/test_full_build.py and ran targeted tests together with existing transformation and plating tests using pytest -q tests/test_full_build.py tests/test_buildcompiler_transformation.py tests/test_plating.py, all tests passed (12 passed).

Codex Task

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c75a283bbe

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +1162 to +1166
if len(variant_design.components) == 0:
for comp_index, component in enumerate(ordered_components):
part_def = variant_parts[comp_index]
variant_component = variant_design.components.create(
f"{variant_display_id}_component_{comp_index+1:03d}"
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Add sequence constraints when generating variant designs

The combinatorial expansion path creates variant ComponentDefinitions with components only, but no SequenceConstraints. Later, full_build calls _find_missing_parts_for_lvl1, which depends on design.getInSequentialOrder() and raises ValueError for designs missing sequence constraints, so full_build fails for CombinatorialDerivation inputs even though this commit advertises support for them.

Useful? React with 👍 / 👎.

Comment on lines +1131 to +1134
zip_base = zip_path.with_suffix("")
archive = shutil.make_archive(
str(zip_base), "zip", root_dir=str(source_dir), base_dir="."
)
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Exclude output archive from its own zip input tree

This archives source_dir while writing full_build_results.zip inside that same directory, so the generated zip contains an entry for full_build_results.zip itself. That self-inclusion is a shutil.make_archive behavior in this layout and leads to bloated/confusing artifacts (the bundle embeds another bundle copy) instead of a clean results package.

Useful? React with 👍 / 👎.

Comment on lines +1036 to +1040
if manifest["assembly_lvl1"].get("successful"):
return "completed"
if (
manifest["assembly_lvl1"].get("failed")
or manifest["domestication"].get("errors")
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Treat domestication stage errors as non-success status

The status helper returns "completed" whenever any level-1 assembly succeeds, even if manifest["domestication"]["errors"] is populated. In runs where domestication transformation/plating fails but assembly succeeds, callers receive a success status despite recorded stage errors, which can mask partial failures in orchestration consumers.

Useful? React with 👍 / 👎.

@Gonza10V Gonza10V merged commit 932d474 into full_build Apr 30, 2026
0 of 4 checks passed
@Gonza10V Gonza10V deleted the codex/implement-buildcompiler.full_build-method branch April 30, 2026 22:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant