Skip to content

feat(api): add per destination option to LC based transfer#18261

Merged
sanni-t merged 6 commits intoedgefrom
api-add_per_destination_option_to_LC_transfers
May 7, 2025
Merged

feat(api): add per destination option to LC based transfer#18261
sanni-t merged 6 commits intoedgefrom
api-add_per_destination_option_to_LC_transfers

Conversation

@sanni-t
Copy link
Copy Markdown
Member

@sanni-t sanni-t commented May 5, 2025

Closes AUTH-1784

Overview

Adds a 'per destination' tip policy to transfer_with_liquid_class only. Doesn't add it to LC based distribute or consolidate.

Test Plan and Hands on Testing

Added integration test.

Review requests

  • check for code sanity
  • Something to think about (not for this PR): with both 'per destination' and 'per source' being available now, should we enable per destination for distribute_with_liquid_class and per source for consolidate_with_liquid_class? Because the tip renewing behavior is pretty well-defined and useful for these above combinations (as opposed to having always/per source for distribution or always/per_destination for consolidation, which don't make total sense). That said, these cases are actually covered by transfer_with_liquid_class with a per source or per destination policy so adding per source, per destination to consolidate_with_liquid_class and distribute_with_liquid_class respectively doesn't add any new value.

Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing behavior.

@sanni-t sanni-t requested review from ddcc4 and jbleon95 May 5, 2025 19:29
@sanni-t sanni-t requested a review from a team as a code owner May 5, 2025 19:29
Copy link
Copy Markdown
Contributor

@jbleon95 jbleon95 left a comment

Choose a reason for hiding this comment

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

This looks good to me, I'd maybe add some unit tests to make sure consolidate and distribute raise if given per destination.

As for whether we should allow this with distribute and per source for consolidate, I'd say let's hold off on considering adding that for now, since it's not necessary for PD compatibility and we're not losing any functionality.

@ddcc4
Copy link
Copy Markdown
Contributor

ddcc4 commented May 7, 2025

should we enable per destination for distribute_with_liquid_class and per source for consolidate_with_liquid_class? These cases are actually covered by transfer_with_liquid_class with a per source or per destination policy so adding per source, per destination to consolidate_with_liquid_class and distribute_with_liquid_class respectively doesn't add any new value.

Can @ncdiehl11 weigh in? I don't remember whether he said the PD consolidate/distribute is exactly like consolidate_with_liquid_class()/distribute_with_liquid_class(). If so, and if a user chooses "Distribute: per destination" in PD, it would be nice if we could generate exactly the same code in Python. But I don't know if the user can even pick that in PD.

add_final_air_gap=True,
trash_location=mock.ANY,
),
mock.call.aspirate_liquid_class(
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Hey, what is this test supposed to do? If there are 2 destination wells, should it have picked up tips twice if you said "per destination"?

Copy link
Copy Markdown
Member Author

@sanni-t sanni-t May 7, 2025

Choose a reason for hiding this comment

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

Yep, and it does. This list is 'expected calls per tip'. The assert in the bottom checks that there's two calls. I didn't want to add 50 more lines duplicating the calls if I could avoid it.

@ncdiehl11
Copy link
Copy Markdown
Collaborator

should we enable per destination for distribute_with_liquid_class and per source for consolidate_with_liquid_class? These cases are actually covered by transfer_with_liquid_class with a per source or per destination policy so adding per source, per destination to consolidate_with_liquid_class and distribute_with_liquid_class respectively doesn't add any new value.

Can @ncdiehl11 weigh in? I don't remember whether he said the PD consolidate/distribute is exactly like consolidate_with_liquid_class()/distribute_with_liquid_class(). If so, and if a user chooses "Distribute: per destination" in PD, it would be nice if we could generate exactly the same code in Python. But I don't know if the user can even pick that in PD.

PD does not allow users to configure a per source/per destination tip policy for distribute/consolidate

)
):
if prev_src is not None:
if prev_src is not None and prev_dest is not None:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

I think this is fine. But since you have an and here, is there ever a case where prev_source is None but prev_dest is not None?

@sanni-t sanni-t merged commit d8966d3 into edge May 7, 2025
24 checks passed
@codecov
Copy link
Copy Markdown

codecov Bot commented May 7, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 23.62%. Comparing base (bfefd85) to head (95902f6).
Report is 38 commits behind head on edge.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             edge   #18261   +/-   ##
=======================================
  Coverage   23.62%   23.62%           
=======================================
  Files        3055     3055           
  Lines      255734   255734           
  Branches    30114    30114           
=======================================
  Hits        60419    60419           
  Misses     195301   195301           
  Partials       14       14           
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

ddcc4 pushed a commit that referenced this pull request May 16, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.
ddcc4 pushed a commit that referenced this pull request May 16, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.
ddcc4 pushed a commit that referenced this pull request May 17, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.
ddcc4 pushed a commit that referenced this pull request May 17, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.
ddcc4 pushed a commit that referenced this pull request May 17, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.
ddcc4 pushed a commit that referenced this pull request May 17, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 17, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 17, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 17, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 17, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 17, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 19, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 19, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 19, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 20, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 20, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 22, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 23, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 24, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 24, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 29, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 29, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
ddcc4 pushed a commit that referenced this pull request May 29, 2025
Closes AUTH-1784

# Overview

Adds a 'per destination' tip policy to `transfer_with_liquid_class`
only. Doesn't add it to LC based distribute or consolidate.

## Risk assessment

Low. Adds a new tip handling logic that shouldn't affect any existing
behavior.

(cherry picked from commit d8966d3)
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.

4 participants