File tree 1 file changed +9
-5
lines changed
api/src/opentrons/protocol_engine/types
1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -107,15 +107,19 @@ class WellInfoSummary(BaseModel):
107
107
@field_validator ("probed_height" , "probed_volume" , mode = "before" )
108
108
@classmethod
109
109
def validate_simulated_probe_result (
110
- cls , input_val : str | None
110
+ cls , input_val : str | LiquidTrackingType | None
111
111
) -> LiquidTrackingType | None :
112
112
"""Return the appropriate input to WellInfoSummary from json data."""
113
113
if not input_val :
114
114
return None
115
- if input_val .isdigit ():
116
- return float (input_val )
117
- else :
118
- return SimulatedProbeResult ()
115
+ if isinstance (input_val , LiquidTrackingType ):
116
+ return input_val
117
+ if isinstance (input_val , str ):
118
+ if input_val .isdigit ():
119
+ return float (input_val )
120
+ elif input_val == "SimulatedProbeResult" :
121
+ return SimulatedProbeResult ()
122
+ return None
119
123
120
124
labware_id : str
121
125
well_name : str
You can’t perform that action at this time.
0 commit comments