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

refactor(step-generation, protocol-designer): create HydratedFormData #17308

Draft
wants to merge 4 commits into
base: edge
Choose a base branch
from

Conversation

jerader
Copy link
Collaborator

@jerader jerader commented Jan 18, 2025

Overview

Was cleaning up StepArgs a bit so it matches the command params a bit better and then ended up creating HydratedFormData type and wired it up. This resulted in a bit of a refactor and changing some arg names: i.e -> module is now moduleId for all instances and temperature is not celsius. This is so it matches TemperatureParams and ModuleOnlyParams which are used a lot for module commands.

I also deleted a bunch of stuff in generateSubsteps because we no longer have substeps for every step type now. only thermocycler and mix and move liquid have substeps

Test Plan and Hands on Testing

Smoke test creating protocols in PD, in particular make sure:

  1. you can properly generate form errors in any form type
  2. disabled fields properly work and dependent fields properly work as well in forms
  3. test that the step-generation commands are what you would expect them to be, i especially changed the module compound commands so test TC, heater-shaker, magnetic module, plate reader, and temperature modules.

Changelog

  • create HydratedFormData and wire it in
  • make sure every hydrated form data type includes description and name and create the form data for the thermocycler which was previously never created for some reason. change module to moduleId, temperature to celsius, and a few other things I think were changed that were more one-offs
  • fix all the type errors
  • update the tests

Review requests

lmk if anything seems weird to you!

Risk assessment

medium - this touches a bunch of code, if all tests pass (most importantly the migration files) then I am confident that these changes don't break anything.

Copy link

codecov bot commented Jan 18, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 73.84%. Comparing base (9a28d32) to head (f8dfe37).
Report is 71 commits behind head on edge.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             edge   #17308   +/-   ##
=======================================
  Coverage   73.84%   73.84%           
=======================================
  Files          43       43           
  Lines        3303     3304    +1     
=======================================
+ Hits         2439     2440    +1     
  Misses        864      864           
Flag Coverage Δ
shared-data 73.84% <ø> (+<0.01%) ⬆️

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

see 1 file with indirect coverage changes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant