Closed lparsons closed 6 months ago
merged
@lparsons - I filled in a design and added the design:needs-review
tag. I'm going to proceed with this issue (branched off branch migrate_msrun
from PR #804) because it should be pretty straightforward, as most of this was already done in #774. If you see any design issues, please indicate the specific design item and highlight the specific issue and add the design:changes-requested
tag and a comment.
@hepcat72 Looks good to me. I would suggest that you create an issue to update the validation interface, since we know that will be needed. Might be a useful place to stash things you notice as you work on this.
@lparsons - I added requirement 7.
(and sub-items) based on the discussion about the polarity value in the meeting. I think I was true to what was decided in the meeting, but let me know if you see anything untoward.
It still seems useful to have the command line option to supply polarity. We want options for the curators. We just want to simplify the requests of the researchers.
When loading data, the polarity can be determined as follows:
When asking the researchers, do not explicity ask for polarity. Curators may decide to supply polarity values even if we don't have an mzXML file, but we shouldn't start by asking.
So, my attempt at putting that into your format above:
unknown
FEATURE REQUEST
Inspiration
Migration to new model
Description
Update the loading code to populate
MSRunSequence
andMSRunSample
. Typically, we will collect one set of data for each peak annotation file, but it would be ideal if when loading we could expand that to a table with:Most of the time, we can use the submission input to generate a table, but this would give us the flexibility to manually generate/edit the table for more complex submissions where one peak annotation file has samples that use different LC methods, etc.
Remove all references to test tag
broken_until_issue712
.Alternatives
Dependencies
This issue cannot be started until the completion of the following issue(s):
709 (PR submitted)
710 (PR submitted)
711 (merged)
Comment
Branch:
load_msrun_sample_sequence
ISSUE OWNER SECTION
Note, there is significant overlap between this issue and the already implemented issue #706, which implements the "table" described in the issue description. All that's needed is to populate the correct Models, remove the broken tags (
broken_until_issue712
), and:instrument
,ms_data_file
, andms_raw_file
(the last 2 as anArchiveFile
records and save the file)instrument
,ms_data_file
, andms_raw_file
intest_lcms_metadata_loading.py
(see 4TODO
comments)MSRunSample.null = False
TODO
intest_models.py
ResearcherNotNew
to take a list of researchers (seeTODO
inaccucor_data_loader.py
)Assumptions
None
Requirements
1.
None of the load scripts result in MSRun being loaded2.
Any load script that loaded MSRun must load the same data in MSRunSample and MSRunSequence instead3.
PeakGroup.msrun_sample.null
must be set toFalse
4.
Add migration forPeakGroup.msrun_sample
change5.
Allbroken_until_issue712
test tegs must be removed6.
ResearcherNotNew
must take a list of researchers (seeTODO
inaccucor_data_loader.py
)7.
polarity
value processing changes Decided on in planning meeting on 12/13/20237.1.
Add a polarity choices value: "unknown"7.2.
Parse polarity from the mzXML (if supplied) (in addition to the existing command line default and LCMS metadata column)7.3.
Polarity value precedence: mzXML file value > LCMS metadata file value > command line value > static "unknown" value7.4.
A command line default polarity value is no longer required7.5.
A default polarity should be removed from the study submission form.7.6.
Raise exception if LCMS metadata polarity value differs from what's parsed from the mzXML file (if it was supplied)Limitations
Affected Components
A tentative list of anticipated repository items that will be changed, labeled with "add", "delete", or "change". One item per line. (Mostly, this will be a list of files.)
DataRepo/tests/...
DataRepo/utils/accucor_data_loader.py
DataRepo/utils/lcms_metadata_parser.py
DataRepo/utils/exceptions.py
DESIGN
Interface Change description
No outward interface changes compared to what was already implemented in #774.
Code Change Description
The changes should be pretty simple, and similar to the type of changes implemented already in the
DataRepo/migrations/0027_msrun_to_msrunsample_msrunsequence.py
file in #804. It will do aget_or_create
on theMSRunSequence
andMSRunSample
, except it will load the files asArchiveFile
records (if provided) and theinstrument
.Tests
A test for each requirement