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

Adding delivery + new modification bp + updating database structure #34

Merged
merged 9 commits into from
Sep 5, 2024

Conversation

paulstretenowich
Copy link
Contributor

No description provided.

alembic.ini Outdated Show resolved Hide resolved
Copy link
Contributor

@poquirion poquirion left a comment

Choose a reason for hiding this comment

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

Mainly cosmetic request about commeted lines. Can be merge after update.

alembic.ini Outdated Show resolved Hide resolved
project_tracking/db_action.py Outdated Show resolved Hide resolved
project_tracking/db_action.py Outdated Show resolved Hide resolved
project_tracking/api/project.py Outdated Show resolved Hide resolved
project_tracking/db_action.py Outdated Show resolved Hide resolved
project_tracking/db_action.py Outdated Show resolved Hide resolved
project_tracking/db_action.py Show resolved Hide resolved
project_tracking/db_action.py Outdated Show resolved Hide resolved
project_tracking/db_action.py Outdated Show resolved Hide resolved
project_tracking/db_action.py Outdated Show resolved Hide resolved
@pphector
Copy link
Member

I finished going over the pull request, and here is a summary of what I understand that this will do. I am not an expert on some of these libraries, so I might be wrong. If the description here is correct, then I will approve the PR so we can move forward while PO is away:

  • Adding the alembic library and creating a directory to store some of the scripts associated with this library within.
  • Adding an alembic.ini file in the top-level directory to configure alembic, including variables to store the alembic scripts, and some variables associated with loggers of different kinds.
  • Modifying some additional scripts throughout the API including pyproject.toml and alembic/env.py to import functions from the alembic library.
  • The main change is a script that modifies the database schema in significant ways (the script is stored under alembic/versions/). The changes to the schema are as follows:
    • Adding a reference table to store information about genome reference (e.g. assembly, version, taxon_id, etc.)
    • Renaming the patient table so it is now called specimen as discussed previously, to facilitate interaction with PCGL and other projects.
    • Modifying all instances of the patient_id into specimen_id
    • Add two columns: ext_src and ext_id to the following tables: sample, run, readset, project, operation, operation_config, metric, location, job, file, and experiment
    • Add the column reference_id to the operation table.
    • Add the column state to the readset table, with the following possible values: VALID, ON_HOLD, and INVALID.
    • Remove the column quality_offset from the readset table.
    • Remove the column fms_id from several tables (sample, specimen and project)

@paulstretenowich
Copy link
Contributor Author

That's correct @pphector.

@pphector
Copy link
Member

pphector commented Aug 1, 2024

That's correct @pphector.

Perfect, then on my end, I will approve. Although I think it would still help if someone else can take a quick Look before we deploy.

Copy link
Member

@pphector pphector left a comment

Choose a reason for hiding this comment

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

This pull request makes major modifications to the database schema using the alembic library. The changes are versioned, this revision will have a specific ID to allow for potential recovery if required.

The biggest changes involve the change of the patient table to specimen. This involves also changing several other column IDs in other tables. Other changes include the addition of a reference table and ext_id and ext_src columns.

Copy link
Member

@garantjm garantjm left a comment

Choose a reason for hiding this comment

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

This is good to go, I'll let you decide id you want to implement the enumerate on this pull request or sometime downstream

@paulstretenowich paulstretenowich merged commit fc28f13 into dev Sep 5, 2024
3 checks passed
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