From b53a07955567cd7baf9afd857cca84d728311b16 Mon Sep 17 00:00:00 2001 From: ian-whaling Date: Fri, 21 Feb 2025 14:25:23 -0800 Subject: [PATCH 01/10] adjusted audit --- src/igvfd/audit/construct_library_set.py | 32 +++++++++++--- .../tests/test_audit_construct_library_set.py | 42 ++++++++++++++++++- 2 files changed, 67 insertions(+), 7 deletions(-) diff --git a/src/igvfd/audit/construct_library_set.py b/src/igvfd/audit/construct_library_set.py index 3171e15d8f..3e5a301f36 100644 --- a/src/igvfd/audit/construct_library_set.py +++ b/src/igvfd/audit/construct_library_set.py @@ -9,6 +9,19 @@ ) +def get_assay_terms(value, system): + assay_terms = set() + for sample in value.get('applied_to_samples', []): + sample_object = system.get('request').embed( + sample + '@@object_with_select_calculated_properties?field=file_sets') + file_sets = sample_object.get('file_sets', []) + for file_set in file_sets: + if file_set.startswith('/measurement-sets/'): + input_file_set_object = system.get('request').embed(input_file_set + '@@object?skip_calculated=true') + assay_terms.add(input_file_set_object.get('assay_term')) + return list(assay_terms) + + @audit_checker('ConstructLibrarySet', frame='object') def audit_construct_library_set_associated_phenotypes(value, system): ''' @@ -97,12 +110,12 @@ def audit_integrated_content_files(value, system): ''' [ { - "audit_description": "Guide libraries are expected to link to an integrated content file of guide RNA sequences.", + "audit_description": "Guide libraries used in CRISPR assays are expected to link to an integrated content file of guide RNA sequences.", "audit_category": "missing guide RNA sequences", "audit_level": "NOT_COMPLIANT" }, { - "audit_description": "Reporter libraries are expected to link to an integrated content file of MPRA sequence designs.", + "audit_description": "Reporter libraries used in MPRA assays are expected to link to an integrated content file of MPRA sequence designs.", "audit_category": "missing MPRA sequence designs", "audit_level": "NOT_COMPLIANT" } @@ -110,13 +123,22 @@ def audit_integrated_content_files(value, system): ''' audit_message_guide = get_audit_message(audit_integrated_content_files, index=0) audit_message_reporter = get_audit_message(audit_integrated_content_files, index=1) + assay_terms = get_assay_terms(value, system) + CRISPR_assays = [ + '/assay-terms/OBI_0003659/' # in vitro CRISPR screen assay + '/assay-terms/OBI_0003660/' # in vitro CRISPR screen using single-cell RNA-seq + '/assay-terms/OBI_0003661/' # in vitro CRISPR screen using flow cytometry + ] + MPRA_assays = [ + '/assay-terms/OBI_0002675/' # massively parallel reporter assay + ] library_expectation = { - 'guide library': ('guide RNA sequences', audit_message_guide), - 'reporter library': ('MPRA sequence designs', audit_message_reporter), + 'guide library': ('guide RNA sequences', audit_message_guide, CRISPR_assays), + 'reporter library': ('MPRA sequence designs', audit_message_reporter, MPRA_assays), } integrated_content_files = value.get('integrated_content_files', '') library_type = value.get('file_set_type', '') - if library_type in library_expectation: + if library_type in library_expectation and any(assay_term in library_expectation[library_type][2] for assay_term in assay_terms): file_expectation = library_expectation[library_type][0] audit_message = library_expectation[library_type][1] if integrated_content_files: diff --git a/src/igvfd/tests/test_audit_construct_library_set.py b/src/igvfd/tests/test_audit_construct_library_set.py index 7e4c4883e8..854a5c2b00 100644 --- a/src/igvfd/tests/test_audit_construct_library_set.py +++ b/src/igvfd/tests/test_audit_construct_library_set.py @@ -184,8 +184,20 @@ def test_audit_construct_library_set_with_invalid_chroms( def test_audit_construct_library_set_guide_library_guide_rna_sequences( testapp, construct_library_set_genome_wide, - tabular_file + tabular_file, + assay_term_crispr, + measurement_set, + tissue ): + testapp.patch_json( + measurement_set['@id'], + {'assay_term': assay_term_crispr['@id'], + 'samples': tissue['@id']} + ) + testapp.patch_json( + tissue['@id'], + {'construct_library_sets': construct_library_set_genome_wide['@id']} + ) res = testapp.get(construct_library_set_genome_wide['@id'] + '@@audit') assert any( error['category'] == 'missing guide RNA sequences' @@ -213,8 +225,21 @@ def test_audit_construct_library_set_guide_library_guide_rna_sequences( def test_audit_construct_library_set_mpra_sequence_designs( testapp, construct_library_set_reporter, - tabular_file + tabular_file, + assay_term_mpra, + measurement_set, + tissue, + assay_term_starr ): + testapp.patch_json( + measurement_set['@id'], + {'assay_term': assay_term_mpra['@id'], + 'samples': tissue['@id']} + ) + testapp.patch_json( + tissue['@id'], + {'construct_library_sets': construct_library_set_reporter['@id']} + ) res = testapp.get(construct_library_set_reporter['@id'] + '@@audit') assert any( error['category'] == 'missing MPRA sequence designs' @@ -229,6 +254,19 @@ def test_audit_construct_library_set_mpra_sequence_designs( error['category'] == 'missing MPRA sequence designs' for error in res.json['audit'].get('NOT_COMPLIANT', []) ) + testapp.patch_json( + measurement_set['@id'], + {'assay_term': assay_term_starr['@id']} + ) + res = testapp.get(construct_library_set_reporter['@id'] + '@@audit') + assert all( + error['category'] != 'missing MPRA sequence designs' + for error in res.json['audit'].get('NOT_COMPLIANT', []) + ) + testapp.patch_json( + measurement_set['@id'], + {'assay_term': assay_term_mpra['@id']} + ) testapp.patch_json( tabular_file['@id'], {'content_type': 'MPRA sequence designs'} From 8225ae640a3dc1608c8e23c0529100436555593e Mon Sep 17 00:00:00 2001 From: ian-whaling Date: Fri, 21 Feb 2025 16:30:49 -0800 Subject: [PATCH 02/10] mappings --- src/igvfd/mappings/construct_library_set.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/igvfd/mappings/construct_library_set.json b/src/igvfd/mappings/construct_library_set.json index 2a3a0bf33c..e97b910dcd 100644 --- a/src/igvfd/mappings/construct_library_set.json +++ b/src/igvfd/mappings/construct_library_set.json @@ -1,6 +1,6 @@ { - "hash": "57e1e31b2b9efad29507e894d9483c27", - "index_name": "construct_library_set_57e1e31b", + "hash": "7223b2ab84906de8a0957f61c4239b76", + "index_name": "construct_library_set_7223b2ab", "item_type": "construct_library_set", "mapping": { "dynamic_templates": [ From 1492c4a9744eefe63773fdd4bae4b5e99d828bb4 Mon Sep 17 00:00:00 2001 From: ian-whaling Date: Fri, 21 Feb 2025 16:46:51 -0800 Subject: [PATCH 03/10] audit fixed --- src/igvfd/audit/construct_library_set.py | 6 +++--- src/igvfd/mappings/construct_library_set.json | 4 ++-- src/igvfd/tests/test_audit_construct_library_set.py | 8 ++++---- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/igvfd/audit/construct_library_set.py b/src/igvfd/audit/construct_library_set.py index 3e5a301f36..b94add1150 100644 --- a/src/igvfd/audit/construct_library_set.py +++ b/src/igvfd/audit/construct_library_set.py @@ -17,7 +17,7 @@ def get_assay_terms(value, system): file_sets = sample_object.get('file_sets', []) for file_set in file_sets: if file_set.startswith('/measurement-sets/'): - input_file_set_object = system.get('request').embed(input_file_set + '@@object?skip_calculated=true') + input_file_set_object = system.get('request').embed(file_set + '@@object?skip_calculated=true') assay_terms.add(input_file_set_object.get('assay_term')) return list(assay_terms) @@ -125,8 +125,8 @@ def audit_integrated_content_files(value, system): audit_message_reporter = get_audit_message(audit_integrated_content_files, index=1) assay_terms = get_assay_terms(value, system) CRISPR_assays = [ - '/assay-terms/OBI_0003659/' # in vitro CRISPR screen assay - '/assay-terms/OBI_0003660/' # in vitro CRISPR screen using single-cell RNA-seq + '/assay-terms/OBI_0003659/', # in vitro CRISPR screen assay + '/assay-terms/OBI_0003660/', # in vitro CRISPR screen using single-cell RNA-seq '/assay-terms/OBI_0003661/' # in vitro CRISPR screen using flow cytometry ] MPRA_assays = [ diff --git a/src/igvfd/mappings/construct_library_set.json b/src/igvfd/mappings/construct_library_set.json index e97b910dcd..9754f25d91 100644 --- a/src/igvfd/mappings/construct_library_set.json +++ b/src/igvfd/mappings/construct_library_set.json @@ -1,6 +1,6 @@ { - "hash": "7223b2ab84906de8a0957f61c4239b76", - "index_name": "construct_library_set_7223b2ab", + "hash": "6aedb30a9960e4ac9f08e080d9c028d6", + "index_name": "construct_library_set_6aedb30a", "item_type": "construct_library_set", "mapping": { "dynamic_templates": [ diff --git a/src/igvfd/tests/test_audit_construct_library_set.py b/src/igvfd/tests/test_audit_construct_library_set.py index 854a5c2b00..43e9108dd6 100644 --- a/src/igvfd/tests/test_audit_construct_library_set.py +++ b/src/igvfd/tests/test_audit_construct_library_set.py @@ -192,11 +192,11 @@ def test_audit_construct_library_set_guide_library_guide_rna_sequences( testapp.patch_json( measurement_set['@id'], {'assay_term': assay_term_crispr['@id'], - 'samples': tissue['@id']} + 'samples': [tissue['@id']]} ) testapp.patch_json( tissue['@id'], - {'construct_library_sets': construct_library_set_genome_wide['@id']} + {'construct_library_sets': [construct_library_set_genome_wide['@id']]} ) res = testapp.get(construct_library_set_genome_wide['@id'] + '@@audit') assert any( @@ -234,11 +234,11 @@ def test_audit_construct_library_set_mpra_sequence_designs( testapp.patch_json( measurement_set['@id'], {'assay_term': assay_term_mpra['@id'], - 'samples': tissue['@id']} + 'samples': [tissue['@id']]} ) testapp.patch_json( tissue['@id'], - {'construct_library_sets': construct_library_set_reporter['@id']} + {'construct_library_sets': [construct_library_set_reporter['@id']]} ) res = testapp.get(construct_library_set_reporter['@id'] + '@@audit') assert any( From 38550e542f0e395f0bddd08f4e47894e927315c7 Mon Sep 17 00:00:00 2001 From: ian-whaling Date: Fri, 21 Feb 2025 17:43:30 -0800 Subject: [PATCH 04/10] adjusted definition and dependency --- src/igvfd/schemas/in_vitro_system.json | 39 +++++++++++++++---- .../tests/test_schema_in_vitro_system.py | 17 +++++++- 2 files changed, 47 insertions(+), 9 deletions(-) diff --git a/src/igvfd/schemas/in_vitro_system.json b/src/igvfd/schemas/in_vitro_system.json index 58be428fba..7958bb9a45 100644 --- a/src/igvfd/schemas/in_vitro_system.json +++ b/src/igvfd/schemas/in_vitro_system.json @@ -112,15 +112,26 @@ }, { "if": { - "properties": { - "classifications": { - "contains": { - "enum": [ - "cell line" + "allOf": [ + { + "properties": { + "classifications": { + "contains": { + "enum": [ + "cell line" + ] + } + } + } + }, + { + "not": { + "required": [ + "modifications" ] } } - } + ] }, "then": { "not": { @@ -401,6 +412,12 @@ "time_post_change_units", "cell_fate_change_protocol" ] + }, + { + "required": [ + "time_post_change_units", + "modifications" + ] } ] }, @@ -418,6 +435,12 @@ "time_post_change", "cell_fate_change_protocol" ] + }, + { + "required": [ + "time_post_change", + "modifications" + ] } ] }, @@ -478,7 +501,7 @@ }, "time_post_change": { "title": "Time Post Change", - "description": "The time that elapsed past the time-point when the cell fate change treatments were introduced.", + "description": "The time that elapsed past the time-point when the cell fate change treatments or genetic modifications were introduced.", "type": "number", "submissionExample": { "appscript": 27, @@ -487,7 +510,7 @@ }, "time_post_change_units": { "title": "Time Post Change Units", - "description": "The units of time that elapsed past the point when the cell fate change treatments were introduced.", + "description": "The units of time that elapsed past the point when the cell fate change treatments or genetic modifications were introduced.", "type": "string", "enum": [ "minute", diff --git a/src/igvfd/tests/test_schema_in_vitro_system.py b/src/igvfd/tests/test_schema_in_vitro_system.py index 543cefb3e0..54ffac40be 100644 --- a/src/igvfd/tests/test_schema_in_vitro_system.py +++ b/src/igvfd/tests/test_schema_in_vitro_system.py @@ -12,7 +12,7 @@ def test_passage_number_dependency(in_vitro_cell_line, testapp): assert res.status_code == 422 -def test_time_post_factors_dependency(in_vitro_cell_line, treatment_chemical, sample_term_endothelial_cell, testapp): +def test_time_post_change_dependency(testapp, in_vitro_cell_line, treatment_chemical, sample_term_endothelial_cell): res = testapp.patch_json( in_vitro_cell_line['@id'], { @@ -31,6 +31,21 @@ def test_time_post_factors_dependency(in_vitro_cell_line, treatment_chemical, sa assert res.status_code == 200 +def test_time_post_change_dependency_modified_cell_line(testapp, in_vitro_cell_line, experimental_protocol_document, crispr_modification): + res = testapp.patch_json( + in_vitro_cell_line['@id'], + {'time_post_change': 3, 'time_post_change_units': 'day'}, expect_errors=True) + assert res.status_code == 422 + res = testapp.patch_json( + in_vitro_cell_line['@id'], + {'time_post_change': 3, 'time_post_change_units': 'day', 'cell_fate_change_protocol': experimental_protocol_document['@id']}, expect_errors=True) + assert res.status_code == 422 + res = testapp.patch_json( + in_vitro_cell_line['@id'], + {'time_post_change': 3, 'time_post_change_units': 'day', 'modifications': [crispr_modification['@id']]}) + assert res.status_code == 200 + + def test_sorted_from(testapp, in_vitro_organoid, in_vitro_differentiated_cell): res = testapp.patch_json( in_vitro_differentiated_cell['@id'], From 857ab7683c836c224690ff2de5a2828b1003770a Mon Sep 17 00:00:00 2001 From: ian-whaling Date: Fri, 21 Feb 2025 17:48:21 -0800 Subject: [PATCH 05/10] added enum to nucleic_acid_delivery --- src/igvfd/schemas/changelogs/biosample.md | 1 + src/igvfd/schemas/changelogs/in_vitro_system.md | 1 + src/igvfd/schemas/changelogs/multiplexed_sample.md | 1 + src/igvfd/schemas/changelogs/primary_cell.md | 1 + src/igvfd/schemas/changelogs/sample.md | 1 + src/igvfd/schemas/changelogs/technical_sample.md | 1 + src/igvfd/schemas/changelogs/tissue.md | 1 + src/igvfd/schemas/changelogs/whole_organism.md | 1 + src/igvfd/schemas/sample.json | 3 ++- src/igvfd/tests/data/inserts/whole_organism.json | 6 +++++- 10 files changed, 15 insertions(+), 2 deletions(-) diff --git a/src/igvfd/schemas/changelogs/biosample.md b/src/igvfd/schemas/changelogs/biosample.md index 0ba5324d23..946527961c 100644 --- a/src/igvfd/schemas/changelogs/biosample.md +++ b/src/igvfd/schemas/changelogs/biosample.md @@ -1,5 +1,6 @@ ## Changelog for *`biosample.json`* +* Extend `nucleic_acid_delivery` enum list to include `nucleofection`. (02/27/2025) * Extend `status` enum list to include `preview`. (11/22/2024) * Add `publication_identifiers`. (07/31/2024) * Restrict `publication_identifiers` to submission by admins only. (07/17/2024) diff --git a/src/igvfd/schemas/changelogs/in_vitro_system.md b/src/igvfd/schemas/changelogs/in_vitro_system.md index 38a07b5947..07a89935b3 100644 --- a/src/igvfd/schemas/changelogs/in_vitro_system.md +++ b/src/igvfd/schemas/changelogs/in_vitro_system.md @@ -2,6 +2,7 @@ ### Minor changes since schema version 25 +* Extend `nucleic_acid_delivery` enum list to include `nucleofection`. * Extend `collections` enum list to include `ACMG73`. * Extend `collections` enum list to include `Morphic`. * Extend `collections` enum list to include `StanfordFCC`. diff --git a/src/igvfd/schemas/changelogs/multiplexed_sample.md b/src/igvfd/schemas/changelogs/multiplexed_sample.md index 37c76a30e8..db2bb6b512 100644 --- a/src/igvfd/schemas/changelogs/multiplexed_sample.md +++ b/src/igvfd/schemas/changelogs/multiplexed_sample.md @@ -2,6 +2,7 @@ ### Minor changes since schema version 10 +* Extend `nucleic_acid_delivery` enum list to include `nucleofection`. * Extend `collections` enum list to include `ACMG73`. * Extend `collections` enum list to include `Morphic`. * Extend `collections` enum list to include `StanfordFCC`. diff --git a/src/igvfd/schemas/changelogs/primary_cell.md b/src/igvfd/schemas/changelogs/primary_cell.md index 2cd73eafbe..a451071d33 100644 --- a/src/igvfd/schemas/changelogs/primary_cell.md +++ b/src/igvfd/schemas/changelogs/primary_cell.md @@ -2,6 +2,7 @@ ### Minor changes since schema version 22 +* Extend `nucleic_acid_delivery` enum list to include `nucleofection`. * Extend `collections` enum list to include `ACMG73`. * Extend `collections` enum list to include `Morphic`. * Extend `collections` enum list to include `StanfordFCC`. diff --git a/src/igvfd/schemas/changelogs/sample.md b/src/igvfd/schemas/changelogs/sample.md index c50bbcaddf..24a0a584a3 100644 --- a/src/igvfd/schemas/changelogs/sample.md +++ b/src/igvfd/schemas/changelogs/sample.md @@ -1,5 +1,6 @@ ## Changelog for *`sample.json`* +* Extend `nucleic_acid_delivery` enum list to include `nucleofection`. (02/27/2025) * Extend `nucleic_acid_delivery` enum list to include `lipofectamine` and `electroporation`. (02/03/2025) * Extend `status` enum list to include `preview`. (11/22/2024) * Remove `publication_identifiers`. (07/31/2024) diff --git a/src/igvfd/schemas/changelogs/technical_sample.md b/src/igvfd/schemas/changelogs/technical_sample.md index 9f5cbb1e6b..e6e088949b 100644 --- a/src/igvfd/schemas/changelogs/technical_sample.md +++ b/src/igvfd/schemas/changelogs/technical_sample.md @@ -2,6 +2,7 @@ ### Minor changes since schema version 14 +* Extend `nucleic_acid_delivery` enum list to include `nucleofection`. * Extend `collections` enum list to include `ACMG73`. * Extend `collections` enum list to include `Morphic`. * Extend `collections` enum list to include `StanfordFCC`. diff --git a/src/igvfd/schemas/changelogs/tissue.md b/src/igvfd/schemas/changelogs/tissue.md index 5332be6f49..0963fda6a4 100644 --- a/src/igvfd/schemas/changelogs/tissue.md +++ b/src/igvfd/schemas/changelogs/tissue.md @@ -2,6 +2,7 @@ ### Minor changes since schema version 21 +* Extend `nucleic_acid_delivery` enum list to include `nucleofection`. * Extend `collections` enum list to include `ACMG73`. * Extend `collections` enum list to include `Morphic`. * Extend `collections` enum list to include `StanfordFCC`. diff --git a/src/igvfd/schemas/changelogs/whole_organism.md b/src/igvfd/schemas/changelogs/whole_organism.md index 30e56fef7a..2c26dcfa25 100644 --- a/src/igvfd/schemas/changelogs/whole_organism.md +++ b/src/igvfd/schemas/changelogs/whole_organism.md @@ -2,6 +2,7 @@ ### Minor changes since schema version 24 +* Extend `nucleic_acid_delivery` enum list to include `nucleofection`. * Extend `collections` enum list to include `ACMG73`. * Extend `collections` enum list to include `Morphic`. * Extend `collections` enum list to include `StanfordFCC`. diff --git a/src/igvfd/schemas/sample.json b/src/igvfd/schemas/sample.json index f50b69cc6a..451bb6af09 100644 --- a/src/igvfd/schemas/sample.json +++ b/src/igvfd/schemas/sample.json @@ -221,7 +221,8 @@ "lipofectamine", "electroporation", "lentiviral transduction", - "transfection" + "transfection", + "nucleofection" ], "submissionExample": { "appscript": "transfection", diff --git a/src/igvfd/tests/data/inserts/whole_organism.json b/src/igvfd/tests/data/inserts/whole_organism.json index 219c9a22b8..e4b0043ad0 100644 --- a/src/igvfd/tests/data/inserts/whole_organism.json +++ b/src/igvfd/tests/data/inserts/whole_organism.json @@ -25,7 +25,11 @@ "virtual": false, "protocols": [ "https://www.protocols.io/test-protocols-url-12345" - ] + ], + "construct_library_sets": [ + "igvf:basic_construct_library_set_1" + ], + "nucleic_acid_delviery": "nucleofection" }, { "uuid": "d4c46526-0307-11ed-b939-0242ac120002", From dfd26da84b8e7d98992e78cb9d6201eb3f9c10ec Mon Sep 17 00:00:00 2001 From: ian-whaling Date: Fri, 21 Feb 2025 17:52:10 -0800 Subject: [PATCH 06/10] content type added for differential peak quantifications --- src/igvfd/schemas/tabular_file.json | 2 ++ src/igvfd/tests/data/inserts/tabular_file.json | 18 ++++++++++++++++++ 2 files changed, 20 insertions(+) diff --git a/src/igvfd/schemas/tabular_file.json b/src/igvfd/schemas/tabular_file.json index af1098fd5c..faecd49116 100644 --- a/src/igvfd/schemas/tabular_file.json +++ b/src/igvfd/schemas/tabular_file.json @@ -124,6 +124,7 @@ "differential chromatin contact quantifications", "differential element quantifications", "differential gene expression quantifications", + "differential peak quantifications", "differential transcript expression quantifications", "DNA footprint scores", "editing templates", @@ -173,6 +174,7 @@ "differential chromatin contact quantifications": "Details differences in chromatin interactions between experimental conditions.", "differential element quantifications": "A file that details the change in effect sizes for a specific non-coding element between two experimental conditions.", "differential gene expression quantifications": "The quantified changes in gene expression levels between different conditions or groups.", + "differential peak quantifications": "The quantified changes in peaks detected between experimental conditions.", "differential transcript expression quantifications": "The quantified changes in expression levels of transcripts between conditions or groups.", "DNA footprint scores": "A file containing DNA footprint scores, which represents the binding sites between DNA and proteins called from assays like ATAC-seq data.", "editing templates": "The homology-directed DNA repair (HDR) templates containing SNVs in the library of saturation genome editing assays.", diff --git a/src/igvfd/tests/data/inserts/tabular_file.json b/src/igvfd/tests/data/inserts/tabular_file.json index 5627224708..b35ada475b 100644 --- a/src/igvfd/tests/data/inserts/tabular_file.json +++ b/src/igvfd/tests/data/inserts/tabular_file.json @@ -483,5 +483,23 @@ "upload_status": "validated", "file_set": "j-michael-cherry:barcodes_curated_set", "controlled_access": false + }, + { + "uuid": "858449fd-5f24-4a51-a4ab-e8aba826b94f", + "lab": "j-michael-cherry", + "award": "HG012012", + "aliases": [ + "igvf:differential_peak_quantifications" + ], + "status": "released", + "release_timestamp": "2025-02-01T21:29:45Z", + "md5sum": "08dc4cb2eee35c7a2c7cb200cb17282a", + "file_format": "tsv", + "content_type": "differential peak quantifications", + "submitted_file_name": "/Users/igvf/igvf_files/differential_peak_quantifications.tsv.gz", + "file_size": 145360919, + "upload_status": "validated", + "file_set": "igvf:analysis_set_with_input", + "controlled_access": false } ] From b6a2d7bfdbb155a2172f3b1a9cacc10970a0615a Mon Sep 17 00:00:00 2001 From: ian-whaling Date: Fri, 21 Feb 2025 18:00:19 -0800 Subject: [PATCH 07/10] changelog for tabular file --- src/igvfd/schemas/changelogs/analysis_step.md | 2 ++ src/igvfd/schemas/changelogs/tabular_file.md | 1 + 2 files changed, 3 insertions(+) diff --git a/src/igvfd/schemas/changelogs/analysis_step.md b/src/igvfd/schemas/changelogs/analysis_step.md index a3ebc92553..741b2379dc 100644 --- a/src/igvfd/schemas/changelogs/analysis_step.md +++ b/src/igvfd/schemas/changelogs/analysis_step.md @@ -2,6 +2,8 @@ ### Minor changes since schema version 5 +* Extend `input_content_types` enum list to include `differential peak quantifications`. +* Extend `output_content_types` enum list to include `differential peak quantifications`. * Extend `input_content_types` enum list to include `protein language model`. * Extend `output_content_types` enum list to include `protein language model`. * Extend `input_content_types` enum list to include `genome index`. diff --git a/src/igvfd/schemas/changelogs/tabular_file.md b/src/igvfd/schemas/changelogs/tabular_file.md index 839bd17ebd..9b8102a3c1 100644 --- a/src/igvfd/schemas/changelogs/tabular_file.md +++ b/src/igvfd/schemas/changelogs/tabular_file.md @@ -2,6 +2,7 @@ ### Minor changes since schema version 13 +* Extend `content_type` enum list to include `differential peak quantifications`. * Extend `transcriptome_annotation` enum list to include `GENCODE 22`. * Extend `collections` enum list to include `ACMG73`. * Extend `collections` enum list to include `Morphic`. From 23abe2e9d955ab292e36f91824bda4c8d2d6c7f0 Mon Sep 17 00:00:00 2001 From: ian-whaling Date: Sun, 23 Feb 2025 21:53:30 -0800 Subject: [PATCH 08/10] revert changes to in vitro system schema --- src/igvfd/schemas/in_vitro_system.json | 39 ++++--------------- .../tests/test_schema_in_vitro_system.py | 15 ------- 2 files changed, 8 insertions(+), 46 deletions(-) diff --git a/src/igvfd/schemas/in_vitro_system.json b/src/igvfd/schemas/in_vitro_system.json index 7958bb9a45..58be428fba 100644 --- a/src/igvfd/schemas/in_vitro_system.json +++ b/src/igvfd/schemas/in_vitro_system.json @@ -112,26 +112,15 @@ }, { "if": { - "allOf": [ - { - "properties": { - "classifications": { - "contains": { - "enum": [ - "cell line" - ] - } - } - } - }, - { - "not": { - "required": [ - "modifications" + "properties": { + "classifications": { + "contains": { + "enum": [ + "cell line" ] } } - ] + } }, "then": { "not": { @@ -412,12 +401,6 @@ "time_post_change_units", "cell_fate_change_protocol" ] - }, - { - "required": [ - "time_post_change_units", - "modifications" - ] } ] }, @@ -435,12 +418,6 @@ "time_post_change", "cell_fate_change_protocol" ] - }, - { - "required": [ - "time_post_change", - "modifications" - ] } ] }, @@ -501,7 +478,7 @@ }, "time_post_change": { "title": "Time Post Change", - "description": "The time that elapsed past the time-point when the cell fate change treatments or genetic modifications were introduced.", + "description": "The time that elapsed past the time-point when the cell fate change treatments were introduced.", "type": "number", "submissionExample": { "appscript": 27, @@ -510,7 +487,7 @@ }, "time_post_change_units": { "title": "Time Post Change Units", - "description": "The units of time that elapsed past the point when the cell fate change treatments or genetic modifications were introduced.", + "description": "The units of time that elapsed past the point when the cell fate change treatments were introduced.", "type": "string", "enum": [ "minute", diff --git a/src/igvfd/tests/test_schema_in_vitro_system.py b/src/igvfd/tests/test_schema_in_vitro_system.py index 54ffac40be..019628daae 100644 --- a/src/igvfd/tests/test_schema_in_vitro_system.py +++ b/src/igvfd/tests/test_schema_in_vitro_system.py @@ -31,21 +31,6 @@ def test_time_post_change_dependency(testapp, in_vitro_cell_line, treatment_chem assert res.status_code == 200 -def test_time_post_change_dependency_modified_cell_line(testapp, in_vitro_cell_line, experimental_protocol_document, crispr_modification): - res = testapp.patch_json( - in_vitro_cell_line['@id'], - {'time_post_change': 3, 'time_post_change_units': 'day'}, expect_errors=True) - assert res.status_code == 422 - res = testapp.patch_json( - in_vitro_cell_line['@id'], - {'time_post_change': 3, 'time_post_change_units': 'day', 'cell_fate_change_protocol': experimental_protocol_document['@id']}, expect_errors=True) - assert res.status_code == 422 - res = testapp.patch_json( - in_vitro_cell_line['@id'], - {'time_post_change': 3, 'time_post_change_units': 'day', 'modifications': [crispr_modification['@id']]}) - assert res.status_code == 200 - - def test_sorted_from(testapp, in_vitro_organoid, in_vitro_differentiated_cell): res = testapp.patch_json( in_vitro_differentiated_cell['@id'], From 7b5e6f18381b7a20d19543d7119c78c564be3057 Mon Sep 17 00:00:00 2001 From: ian-whaling Date: Sun, 23 Feb 2025 21:56:31 -0800 Subject: [PATCH 09/10] revert another change --- src/igvfd/tests/test_schema_in_vitro_system.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/igvfd/tests/test_schema_in_vitro_system.py b/src/igvfd/tests/test_schema_in_vitro_system.py index 019628daae..543cefb3e0 100644 --- a/src/igvfd/tests/test_schema_in_vitro_system.py +++ b/src/igvfd/tests/test_schema_in_vitro_system.py @@ -12,7 +12,7 @@ def test_passage_number_dependency(in_vitro_cell_line, testapp): assert res.status_code == 422 -def test_time_post_change_dependency(testapp, in_vitro_cell_line, treatment_chemical, sample_term_endothelial_cell): +def test_time_post_factors_dependency(in_vitro_cell_line, treatment_chemical, sample_term_endothelial_cell, testapp): res = testapp.patch_json( in_vitro_cell_line['@id'], { From b88e37abe3d265fc7d132fb16dcceac154b88bc1 Mon Sep 17 00:00:00 2001 From: ian-whaling Date: Sun, 23 Feb 2025 22:12:14 -0800 Subject: [PATCH 10/10] Typo --- src/igvfd/tests/data/inserts/whole_organism.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/igvfd/tests/data/inserts/whole_organism.json b/src/igvfd/tests/data/inserts/whole_organism.json index e4b0043ad0..e12cd7e895 100644 --- a/src/igvfd/tests/data/inserts/whole_organism.json +++ b/src/igvfd/tests/data/inserts/whole_organism.json @@ -29,7 +29,7 @@ "construct_library_sets": [ "igvf:basic_construct_library_set_1" ], - "nucleic_acid_delviery": "nucleofection" + "nucleic_acid_delivery": "nucleofection" }, { "uuid": "d4c46526-0307-11ed-b939-0242ac120002",