DRDataRaft/ docs
GitHub ↗

H32 Build on checked releases

H32DuckLake, releases and reports1 step

Use your current course session. Preparation and course runner · R script ↓

H32 Build on checked releases

Goal: Use a fixed RAW dependency.

Prerequisites: H31.

The source references the exact accepted input. A derived product can add transformations.

training_step(
  "H32",
  {
    raw_source <- dataraft.lake::dr_source_release(
      training_lake,
      "policies.raw",
      raw_accepted$release_id
    )
    clean_product <- dr_product(
      "policies.clean",
      raw_source,
      contract = policy_contract
    ) |>
      dr_add_recipe(rounding_recipe)
    clean_release <- dr_publish(clean_product, to = training_lake)
    print(dr_collect(clean_release))
    stopifnot(sum(dr_collect(clean_release)$premium) == 740)
  },
  needs = c("H31", "H08"),
  enabled = training_options$lake,
  optional = TRUE
)

Expected result: A derived release with a source in the RAW layer.

Task: What changes for a newer delivery?

Show solution

Bind the source to that delivery's accepted release ID.

Search documentation

Search functions, packages and guides.