Skip to content

BI-2983: Remove obsUnitId from additionalInfo for Samples - #584

Merged
jloux-brapi merged 1 commit into
epic/BI-2862from
feature/BI-2983
Dec 2, 2026
Merged

jloux-brapi merged 1 commit into
epic/BI-2862from
feature/BI-2983

Conversation

@humsika

@humsika humsika commented Dec 2, 2026 •

Copy link
Copy Markdown
Contributor

Description
Story: BI-2983
Sample submissions saved the ObsUnitID twice: in the BrAPI observationUnitDbId field and in additionalInfo.obsUnitID. The duplicate could drift from the real field, and it had already broken tests during BI-2914. The sample import now sets only observationUnitDbId. The Sample Submission CSV download reads the ObsUnitID from that field, and the unused OBS_UNIT_ID additionalInfo constant is removed.

Dependencies:
bi-web: feature/BI-2983
bi-api: feature/BI-2983
brapi-Java-ProdServer: feature/BI-2983

Testing:

  1. In a program with an experiment, copy a few ObsUnitIDs from the experiment's observation unit table and note a few GIDs from the Germplasm page.
  2. Go to Import → Genotype Sample Submission and upload a file where some rows have an ObsUnitID only and some have a GID only.
  3. In the preview, verify that:
    • Rows with an ObsUnitID show it in the ObsUnitID column.
    • Rows with only a GID show a blank ObsUnitID.
  4. Commit the import, then open Sample Management → the new submission. Verify that the ObsUnitID column shows the same values as the preview.
  5. From the same page, go to Actions → Download Sample Submission. Verify in the CSV that:
    • The ObsUnitID column matches the uploaded file.
    • The ObsUnitID is blank (not "null") for the GID-only rows.

Checklist:
[x] I have performed a self-review of my own code
[x]I have tested my code and ensured it meets the acceptance criteria of the story
[x]I have create/modified unit and/or integration tests to cover this change or tests are not applicable
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have either updated the source of truth or arranged for update with product owner if needed https://breedinginsight.atlassian.net/wiki/spaces/BI/pages/1559953409/Source+of+Truth

@jloux-brapi
jloux-brapi merged commit 2440dcb into epic/BI-2862 Dec 2, 2026
4 of 7 checks passed
@jloux-brapi
jloux-brapi deleted the feature/BI-2983 branch December 2, 2026 16:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants