Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(engine): thermocycler run profile #10921

Merged
merged 7 commits into from
Jun 30, 2022
Merged

Conversation

jbleon95
Copy link
Contributor

Overview

Closes #9559

Adds thermocycler runProfile command to Protocol Engine.

Changelog

  • Added runProfile to Protocol Engine thermocycler commands.

Review requests

Risk assessment

Low

@jbleon95 jbleon95 requested a review from a team as a code owner June 27, 2022 19:49
@codecov
Copy link

codecov bot commented Jun 27, 2022

Codecov Report

Merging #10921 (a1d1557) into edge (d65147e) will increase coverage by 0.00%.
The diff coverage is 100.00%.

Impacted file tree graph

@@           Coverage Diff           @@
##             edge   #10921   +/-   ##
=======================================
  Coverage   73.78%   73.78%           
=======================================
  Files        2076     2076           
  Lines       57327    57328    +1     
  Branches     5727     5727           
=======================================
+ Hits        42299    42300    +1     
  Misses      13789    13789           
  Partials     1239     1239           
Flag Coverage Δ
app 70.85% <ø> (ø)
notify-server 89.17% <ø> (ø)
protocol-designer 46.01% <ø> (ø)
shared-data 86.04% <ø> (ø)
step-generation 89.27% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...entrons/protocol_engine/commands/command_unions.py 100.00% <ø> (ø)
...esigner/src/components/FileSidebar/FileSidebar.tsx 77.77% <ø> (ø)
...server/robot_server/runs/router/commands_router.py 100.00% <ø> (ø)
...c/commandCreators/atomic/thermocyclerRunProfile.ts 100.00% <100.00%> (ø)

@jbleon95 jbleon95 added the robot-svcs Falls under the purview of the Robot Services squad (formerly CPX, Core Platform Experience). label Jun 27, 2022
mcous
mcous previously approved these changes Jun 28, 2022
Copy link
Contributor

@mcous mcous left a comment

Choose a reason for hiding this comment

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

I have one comment for the SME's about whether the blockMaxVolumeUl argument should be optional, but this PR looks great!

...,
description="Array of profile steps with target temperature and temperature hold time.",
)
blockMaxVolumeUl: float = Field(
Copy link
Contributor

Choose a reason for hiding this comment

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

@shlokamin or @sanni-t, do either of y'all know why this is a required parameter of runProfile but optional for setTargetBlockTemperature? My gut reaction is that it should be optional in runProfile, too.

It's optional once you hit the hardware control API, FWIW

Copy link
Member

Choose a reason for hiding this comment

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

AFAIK it should be optional, not sure why it's required in the JSON schema. im fine with updating the schema to make it optional as part of this PR (i can do that as part of the frontend side). that cool with you @sanni-t ?

Copy link
Member

@shlokamin shlokamin Jun 28, 2022

Choose a reason for hiding this comment

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

also note to self, i need to add to the JSON schema migration to make sure <v6 protocols get these parameters updated

Copy link
Member

Choose a reason for hiding this comment

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

Yep, volume should be optional. It defaults to 25uL in firmware

Copy link
Member

Choose a reason for hiding this comment

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

Unless we want to make sure that PD protocols always specify the volume for ideal heating. I'm guessing that since PD does volume tracking, the volume will always be specified anyway?

The volume parameter was added to setTargetBlockTemperature only in v6. Hence that one definitely needs to stay optional to allow older protocols to run as expected.

Copy link
Member

Choose a reason for hiding this comment

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

good point, the thermocycler step form in PD does require volume, but thats a PD concern (not a step generation/schema concern), so ill go ahead and mark it as optional

Comment on lines 72 to 75
{
"temperature": target_temperature,
"hold_time_seconds": profile_step.holdSeconds,
}
Copy link
Contributor

Choose a reason for hiding this comment

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

I would love for the hardware control API to accept a dataclass or NamedTuple rather than a dict. Might add it to the confluence doc

@jbleon95 jbleon95 requested a review from a team as a code owner June 28, 2022 20:06
@@ -843,7 +843,7 @@
"commandType": { "enum": ["thermocycler/runProfile"] },
"params": {
"type": "object",
"required": ["moduleId", "profile", "volume"],
Copy link
Member

Choose a reason for hiding this comment

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

removing volume (renamed to blockMaxVolumeUl) as a required param

@shlokamin shlokamin requested a review from mcous June 28, 2022 20:22
@shlokamin shlokamin dismissed mcous’s stale review June 28, 2022 20:23

dismissing and re-requesting review after changes to the JSON schema

@shlokamin shlokamin added the json-v6 Issues related to JSON Protocol Schema v6 label Jun 28, 2022
@jbleon95 jbleon95 merged commit 8a70b53 into edge Jun 30, 2022
@SyntaxColoring SyntaxColoring deleted the pe-thermocycler-run-profile branch July 1, 2022 20:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
json-v6 Issues related to JSON Protocol Schema v6 robot-svcs Falls under the purview of the Robot Services squad (formerly CPX, Core Platform Experience).
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feat(engine): execute a thermocycler profile
4 participants