From 2d6050e32f7285eda2f83d4c4c110a0961b6759c Mon Sep 17 00:00:00 2001 From: Alexandr Date: Mon, 19 Oct 2026 16:20:35 +0200 Subject: [PATCH 1/6] MILAB-7194: warn about blocks missing data of this block --- .changeset/column-value-refs.md | 7 +++++++ model/src/index.ts | 4 +++- ui/src/pages/MetadataPage.vue | 2 ++ 3 files changed, 12 insertions(+), 1 deletion(-) create mode 100644 .changeset/column-value-refs.md diff --git a/.changeset/column-value-refs.md b/.changeset/column-value-refs.md new file mode 100644 index 0000000..5580504 --- /dev/null +++ b/.changeset/column-value-refs.md @@ -0,0 +1,7 @@ +--- +"@platforma-open/milaboratories.samples-and-data": minor +"@platforma-open/milaboratories.samples-and-data.model": minor +"@platforma-open/milaboratories.samples-and-data.ui": minor +--- + +Warns when blocks that use data of this block no longer find it — an output it does not export or values it no longer has — and suggests adding the data or reconfiguring those blocks, via the SDK dependencies plugin. diff --git a/model/src/index.ts b/model/src/index.ts index a254cf6..ee6673b 100644 --- a/model/src/index.ts +++ b/model/src/index.ts @@ -1,6 +1,6 @@ import { kind } from "@platforma-open/milaboratories.samples-and-data.kind"; import type { ImportFileHandle, InferHrefType, InferOutputsType, PlId } from "@platforma-sdk/model"; -import { BlockModelV3 } from "@platforma-sdk/model"; +import { BlockModelV3, blockDependencies } from "@platforma-sdk/model"; import { blockDataModel } from "./data_model"; import type { BlockArgs, BlockPrerunArgs } from "./args"; import { validateMultiplexingRules } from "./multiplexing-rules-validation"; @@ -123,6 +123,8 @@ export const platforma = BlockModelV3.create({ dataModel: blockDataModel, kind } ctx.prerun?.traverse({ field: "metadataFile" })?.getFileHandle(), ) + .plugin(blockDependencies) + .title(() => "Samples & Data") .subtitle((ctx) => { diff --git a/ui/src/pages/MetadataPage.vue b/ui/src/pages/MetadataPage.vue index ce0f1b1..a2853c7 100644 --- a/ui/src/pages/MetadataPage.vue +++ b/ui/src/pages/MetadataPage.vue @@ -25,6 +25,7 @@ import { PlAgColumnHeader, type PlAgHeaderComponentParams, PlAgOverlayNoRows, + PlBlockDependencies, PlBlockPage, PlBtnGhost, PlBtnPrimary, @@ -371,6 +372,7 @@ const gridOptions = computed>(() => ({