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

fix(shared-data): update tipracks to URIs #17288

Open
wants to merge 1 commit into
base: edge
Choose a base branch
from

Conversation

sanni-t
Copy link
Member

@sanni-t sanni-t commented Jan 16, 2025

Closes AUTH-1293

Overview

Replaces the tiprack names with URIs in Ethanol & Glycerol definitions

Review requests

Do we want to rename the liquid-class directory to liquid_class? (dash vs underscore)

Risk assessment

None

@sanni-t sanni-t requested a review from a team as a code owner January 16, 2025 16:08
@sanni-t sanni-t requested a review from jbleon95 January 16, 2025 16:08
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.

Shrug ... What's the difference between the old tiprack names and the new URIs? (I.e., when would we use one vs the other?)

Copy link
Contributor

@SyntaxColoring SyntaxColoring left a comment

Choose a reason for hiding this comment

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

Makes sense, thanks.

No opinion about hyphens vs. underscores. I don't think underscores are typical in JS, so it'll break somebody's convention no matter what we do.

@ddcc4
Copy link
Contributor

ddcc4 commented Jan 17, 2025

No opinion about hyphens vs. underscores. I don't think underscores are typical in JS, so it'll break somebody's convention no matter what we do.

I think the existing filename doesn't have enough types of word separators:

shared-data/liquid-class/definitions/1/ethanol_80.json
                  ^                           ^
                hyphen                    underscore

Compare that to a more sophisticated filename like this, which shows off our word separator capabilities much better:

shared-data/pipette/definitions/2/liquid/eight_channel/p50/lowVolumeDefault/3_0.json
      ^                                       ^               ^
    hyphen                                underscore       camelcase

or the masterpiece

analyses-snapshot-testing/tests/__snapshots__/analyses_snapshot_test/test_analysis_snapshot[ac886d7768][Flex_S_v2_15_P1000_96_GRIP_HS_MB_TC_TM_IDTXgen96Part1to3].json

😝😝😝

@sanni-t
Copy link
Member Author

sanni-t commented Jan 17, 2025

Shrug ... What's the difference between the old tiprack names and the new URIs? (I.e., when would we use one vs the other?)

The URIs are the full paths to the definition file of the tiprack. So it's inherently versioned and refer to a very specific instance of a labware definition. The names are not versioned. For the purposes of attaching any specific properties and behavior to a specific tiprack (or any labware if speaking in general terms), it's usually better to use the URIs to categorize instead of names so that if your labware's definition (& hence version) changes, you don't break any existing liquid class behavior. It also allows you to distinguish between an in-built opentrons labware and a same-named custom labware created by the user.

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.

3 participants