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(step-generation): python command generation for heater-shaker co… #17647

Merged
merged 2 commits into from
Mar 5, 2025

Conversation

jerader
Copy link
Collaborator

@jerader jerader commented Mar 4, 2025

…mmands

closes AUTH-1102

Overview

This PR adds python support for the majority of heater-shaker commands + setTemperature since it is used for heater-shaker (as well as temperature module commands)

Test Plan and Hands on Testing

I added unit test coverage but also review the code and smoke test

Changelog

  • add python command generation for each of the heater-shaker commands and add unit test coverage to the exiting heater-shaker tests

Risk assessment

low, behind ff

@jerader jerader requested a review from a team as a code owner March 4, 2025 17:38
@jerader jerader requested a review from ddcc4 March 4, 2025 17:39
Copy link

codecov bot commented Mar 4, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 25.68%. Comparing base (e583471) to head (98f93e1).
Report is 3 commits behind head on edge.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             edge   #17647   +/-   ##
=======================================
  Coverage   25.68%   25.68%           
=======================================
  Files        2851     2851           
  Lines      219457   219473   +16     
  Branches    17971    17972    +1     
=======================================
+ Hits        56363    56379   +16     
  Misses     163079   163079           
  Partials       15       15           
Flag Coverage Δ
protocol-designer 18.94% <8.33%> (-0.01%) ⬇️
step-generation 4.38% <100.00%> (+<0.01%) ⬆️

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

Files with missing lines Coverage Δ
...c/commandCreators/atomic/heaterShakerCloseLatch.ts 100.00% <100.00%> (ø)
...andCreators/atomic/heaterShakerDeactivateHeater.ts 100.00% <100.00%> (ø)
...rc/commandCreators/atomic/heaterShakerOpenLatch.ts 97.61% <100.00%> (+0.11%) ⬆️
...Creators/atomic/heaterShakerSetTargetShakeSpeed.ts 86.20% <100.00%> (+1.02%) ⬆️
...rc/commandCreators/atomic/heaterShakerStopShake.ts 100.00% <100.00%> (ø)
...ation/src/commandCreators/atomic/setTemperature.ts 85.96% <100.00%> (+1.05%) ⬆️
step-generation/src/fixtures/robotStateFixtures.ts 97.82% <100.00%> (+0.01%) ⬆️

Copy link
Contributor

@ddcc4 ddcc4 left a comment

Choose a reason for hiding this comment

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

Yay!

@@ -128,6 +128,9 @@ describe('heaterShaker compound command creator', () => {
},
},
])
expect(getSuccessResult(result).python).toBe(
'mock_heater_shaker_1.close_labware_latch()\nmock_heater_shaker_1.set_target_temperature(80)\nmock_heater_shaker_1.set_and_wait_for_shake_speed(444)\nprotocol.delay(seconds=30)\nmock_heater_shaker_1.deactivate_shaker()\nmock_heater_shaker_1.deactivate_heater()'
)
Copy link
Contributor

Choose a reason for hiding this comment

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

Feel free to use a multiline string here to make this easier to read, like we do for other tests.

@jerader jerader merged commit 62d1b6e into edge Mar 5, 2025
18 checks passed
@jerader jerader deleted the sg_heater-shaker-python branch March 5, 2025 13:36
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.

2 participants