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

DEV - Improve order flow main #3815

Merged
merged 237 commits into from
Jan 23, 2025
Merged

DEV - Improve order flow main #3815

merged 237 commits into from
Jan 23, 2025

Conversation

islean
Copy link
Contributor

@islean islean commented Oct 7, 2024

Description

Development branch for the https://github.com/Clinical-Genomics/project-planning/issues/540 project.

Moves the order validation from the Frontend to the backend.

Frontend branch: https://github.com/Clinical-Genomics/clinical-genomics-ui/pull/514

Added

  • New validation flow for all order types
  • New OrderValidationService
  • New BaseModel's for all order types performing basic validation such as type checking
  • Rules written for each validation for more complicated rules, including database checks and fields dependent on each other.
  • New endpoint for validating orders
  • New Request handling in submit_order

Changed

Fixed

How to prepare for test

  • Ssh to relevant server (depending on type of change)
  • Use stage: us
  • Paxa the environment: paxa
  • Install on stage (example for Hasta):
    bash /home/proj/production/servers/resources/hasta.scilifelab.se/update-tool-stage.sh -e S_cg -t cg -b [THIS-BRANCH-NAME] -a

How to test

  • Do ...

Expected test outcome

  • Check that ...
  • Take a screenshot and attach or copy/paste the output.

Review

  • Tests executed by
  • "Merge and deploy" approved by
    Thanks for filling in who performed the code review and the test!

This version is a

  • MAJOR - when you make incompatible API changes
  • MINOR - when you add functionality in a backwards compatible manner
  • PATCH - when you make backwards compatible bug fixes or documentation/instructions

Implementation Plan

  • Document in ...
  • Deploy this branch on ...
  • Inform to ...

islean and others added 30 commits July 5, 2024 15:09
Add parent models and Tomte models for the new validation flow.
Split logic into modules based on workflow
### Fixed

- Some typing and a blueprint method for converting pydantic errors to our own custom errors.
### Added

- Validation that the provided applications exist in the database
### Added

- Check that the application provided is compatible with the chosen workflow.
### Added

- Applications are validated not to be archived.
### Fixed

- Standardised rule naming.
### Added

- Added validation making sure that the gene panels exist in status db
### Added

- Adds validation ensuring gene panels are not specified more than once.
### Added

- Buffer validation for orders attempting to skip reception control
### Added

- Validation ensuring that the subject id is not the same as the case name.
### Added

- Validation ensuring that the sample name and subject id can not be the same.
### Added

- Validation that the concentration is provided for all samples when skip reception control is attempted.
### Added

- Container names are required when using well plates.
### Added

- Validation that well position is filled in for samples in a well plate.
diitaz93 and others added 10 commits January 21, 2025 09:34
enhance order submission integration tests
### Fixed

- No hard coding of delivery type or workflow in the storing services
### Fixed

- The pre commit matches master
### Fixed

- MutantSample and MicrosaltSample dumps the verified_organism value
### Fixed

- The repeated case name rule only considers new cases
### Fixed

- The volume interval is not validated for Pacbio orders since the interval is not what the customers need either way
### Fixed

- Panels are optional for existing cases.
add test for validation pool
add tests for mutant validator
@islean islean marked this pull request as ready for review January 21, 2025 12:00
@islean islean requested a review from a team as a code owner January 21, 2025 12:00
@clingen-sthlm clingen-sthlm temporarily deployed to stage January 21, 2025 12:03 Inactive
Copy link
Contributor

@diitaz93 diitaz93 left a comment

Choose a reason for hiding this comment

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

💪 💪 💪 💪 💪

@clingen-sthlm clingen-sthlm temporarily deployed to stage January 21, 2025 14:50 Inactive
@moedarrah
Copy link

🥇

add other organism to microbial sample models and unit test for adding new organism
@clingen-sthlm clingen-sthlm temporarily deployed to stage January 22, 2025 12:24 Inactive
…mes (#4135) (patch)

### Fixed

- validate_sample_names_different_from_case_names work with existing cases
### Fixed

- Export skip reception control to LIMS
@Vince-janv Vince-janv merged commit f8a0f80 into master Jan 23, 2025
9 checks passed
@Vince-janv Vince-janv deleted the improve-order-flow-main branch January 23, 2025 09:01
@diitaz93
Copy link
Contributor

diitaz93 commented Jan 23, 2025

  • Deployed to Hasta stage:
Logging deploy ...
Getting deployer... done.
Getting last commit message and SHA... done.
Getting version of deploy scripts... /home/js.diazboada
done.
Log deploy... done.
cg, version 67.0.0
[js.diazboada@hasta:~] [S_base] $ up
  • Deployed to Hasta production:
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
repository is clean
Logging deploy ...
Getting deployer... done.
Getting last commit message and SHA... done.
Getting version of deploy scripts... /home/js.diazboada
done.
Log deploy... done.
cg, version 67.0.0

@islean
Copy link
Contributor Author

islean commented Jan 23, 2025

Deployed to the VMs
image

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.

Bug: Delivery of cases where case.name is the same as the sample.name
9 participants