From 6b63aae6b8574d2cb81ff24430f31f048b71b1be Mon Sep 17 00:00:00 2001 From: Jethary Date: Wed, 5 Feb 2025 13:12:58 -0500 Subject: [PATCH] fix load-file ingredients type --- .../fixtures/protocol/8/doItAllV3MigratedToV8.json | 4 ++-- .../fixtures/protocol/8/doItAllV4MigratedToV8.json | 4 ++-- .../fixtures/protocol/8/doItAllV7MigratedToV8.json | 8 ++++---- protocol-designer/fixtures/protocol/8/doItAllV8.json | 4 ++-- .../fixtures/protocol/8/example_1_1_0MigratedToV8.json | 8 ++++---- .../protocol/8/thermocyclerOnOt2V7MigratedToV8.json | 4 ++-- protocol-designer/src/file-types.ts | 3 ++- 7 files changed, 18 insertions(+), 17 deletions(-) diff --git a/protocol-designer/fixtures/protocol/8/doItAllV3MigratedToV8.json b/protocol-designer/fixtures/protocol/8/doItAllV3MigratedToV8.json index 3c85565988b..bfe4767cdff 100644 --- a/protocol-designer/fixtures/protocol/8/doItAllV3MigratedToV8.json +++ b/protocol-designer/fixtures/protocol/8/doItAllV3MigratedToV8.json @@ -34,10 +34,10 @@ "ingredients": { "0": { "displayName": "Water", + "displayColor": "#b925ff", "description": null, - "liquidGroupId": "0", "pythonName": "liquid_1", - "displayColor": "#b925ff" + "liquidGroupId": "0" } }, "ingredLocations": { diff --git a/protocol-designer/fixtures/protocol/8/doItAllV4MigratedToV8.json b/protocol-designer/fixtures/protocol/8/doItAllV4MigratedToV8.json index b90d764dcd6..5ef201e8e50 100644 --- a/protocol-designer/fixtures/protocol/8/doItAllV4MigratedToV8.json +++ b/protocol-designer/fixtures/protocol/8/doItAllV4MigratedToV8.json @@ -34,10 +34,10 @@ "ingredients": { "0": { "displayName": "Water", + "displayColor": "#b925ff", "description": null, - "liquidGroupId": "0", "pythonName": "liquid_1", - "displayColor": "#b925ff" + "liquidGroupId": "0" } }, "ingredLocations": { diff --git a/protocol-designer/fixtures/protocol/8/doItAllV7MigratedToV8.json b/protocol-designer/fixtures/protocol/8/doItAllV7MigratedToV8.json index 0596ed9cc97..17257c9b64d 100644 --- a/protocol-designer/fixtures/protocol/8/doItAllV7MigratedToV8.json +++ b/protocol-designer/fixtures/protocol/8/doItAllV7MigratedToV8.json @@ -37,17 +37,17 @@ "ingredients": { "0": { "displayName": "Water", + "displayColor": "#b925ff", "description": null, - "liquidGroupId": "0", "pythonName": "liquid_1", - "displayColor": "#b925ff" + "liquidGroupId": "0" }, "1": { "displayName": "Samples", + "displayColor": "#ffd600", "description": null, - "liquidGroupId": "1", "pythonName": "liquid_2", - "displayColor": "#ffd600" + "liquidGroupId": "1" } }, "ingredLocations": { diff --git a/protocol-designer/fixtures/protocol/8/doItAllV8.json b/protocol-designer/fixtures/protocol/8/doItAllV8.json index 515850a89d4..4cc1d1b94f1 100644 --- a/protocol-designer/fixtures/protocol/8/doItAllV8.json +++ b/protocol-designer/fixtures/protocol/8/doItAllV8.json @@ -33,14 +33,14 @@ }, "ingredients": { "0": { - "displayName": "", + "displayName": "h20", "description": null, "liquidGroupId": "0", "pythonName": "liquid_1", "displayColor": "#b925ff" }, "1": { - "displayName": "", + "displayName": "sample", "description": null, "liquidGroupId": "1", "pythonName": "liquid_2", diff --git a/protocol-designer/fixtures/protocol/8/example_1_1_0MigratedToV8.json b/protocol-designer/fixtures/protocol/8/example_1_1_0MigratedToV8.json index 090e26be9ec..7e0b8eeabff 100644 --- a/protocol-designer/fixtures/protocol/8/example_1_1_0MigratedToV8.json +++ b/protocol-designer/fixtures/protocol/8/example_1_1_0MigratedToV8.json @@ -38,16 +38,16 @@ "0": { "displayName": "samples", "description": null, - "liquidGroupId": "0", + "displayColor": "#b925ff", "pythonName": "liquid_1", - "displayColor": "#b925ff" + "liquidGroupId": "0" }, "1": { "displayName": "dna", "description": null, - "liquidGroupId": "1", "pythonName": "liquid_2", - "displayColor": "#ffd600" + "displayColor": "#ffd600", + "liquidGroupId": "1" } }, "ingredLocations": { diff --git a/protocol-designer/fixtures/protocol/8/thermocyclerOnOt2V7MigratedToV8.json b/protocol-designer/fixtures/protocol/8/thermocyclerOnOt2V7MigratedToV8.json index bded87d8356..d08d93857e8 100644 --- a/protocol-designer/fixtures/protocol/8/thermocyclerOnOt2V7MigratedToV8.json +++ b/protocol-designer/fixtures/protocol/8/thermocyclerOnOt2V7MigratedToV8.json @@ -34,10 +34,10 @@ "ingredients": { "0": { "displayName": "123", + "displayColor": "#b925ff", "description": null, - "liquidGroupId": "0", "pythonName": "liquid_1", - "displayColor": "#b925ff" + "liquidGroupId": "0" } }, "ingredLocations": { diff --git a/protocol-designer/src/file-types.ts b/protocol-designer/src/file-types.ts index f8923d7a9e1..d42fd2980b9 100644 --- a/protocol-designer/src/file-types.ts +++ b/protocol-designer/src/file-types.ts @@ -5,12 +5,13 @@ import type { ProtocolFile as ProtocolFileV3 } from '@opentrons/shared-data/prot import type { ProtocolFile as ProtocolFileV4 } from '@opentrons/shared-data/protocol/types/schemaV4' import type { ProtocolFile as ProtocolFileV5 } from '@opentrons/shared-data/protocol/types/schemaV5' import type { ProtocolFile as ProtocolFileV6 } from '@opentrons/shared-data/protocol/types/schemaV6' +import { LiquidEntities } from '@opentrons/step-generation' export interface PDMetadata { // pipetteId to tiprackModel pipetteTiprackAssignments: Record dismissedWarnings: DismissRoot['dismissedWarnings'] - ingredients: IngredRoot['ingredients'] + ingredients: LiquidEntities ingredLocations: IngredRoot['ingredLocations'] savedStepForms: StepformRoot['savedStepForms'] orderedStepIds: StepformRoot['orderedStepIds']