variantgrid-api 1.3.2__tar.gz → 1.4.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {variantgrid_api-1.3.2/src/variantgrid_api.egg-info → variantgrid_api-1.4.0}/PKG-INFO +1 -1
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/pyproject.toml +1 -1
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/src/variantgrid_api/data_models.py +12 -8
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0/src/variantgrid_api.egg-info}/PKG-INFO +1 -1
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/tests/test_api_client.py +20 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/LICENSE +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/README.md +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/setup.cfg +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/src/variantgrid_api/api_client.py +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/src/variantgrid_api/cli.py +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/src/variantgrid_api/mock_variantgrid_api.py +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/src/variantgrid_api.egg-info/SOURCES.txt +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/src/variantgrid_api.egg-info/dependency_links.txt +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/src/variantgrid_api.egg-info/entry_points.txt +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/src/variantgrid_api.egg-info/requires.txt +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/src/variantgrid_api.egg-info/top_level.txt +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/tests/test_api_client_annotation.py +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/tests/test_api_client_bulk.py +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/tests/test_api_client_validation.py +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/tests/test_cli.py +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/tests/test_data_models.py +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/tests/test_mock_variantgrid_api.py +0 -0
- {variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/tests/test_sequencer_model_from_name.py +0 -0
|
@@ -132,6 +132,14 @@ class VariantCaller:
|
|
|
132
132
|
run_params: Optional[str] = None
|
|
133
133
|
|
|
134
134
|
|
|
135
|
+
@dataclass_json
|
|
136
|
+
@dataclass
|
|
137
|
+
class SequencingSampleLookup:
|
|
138
|
+
""" Only used as arguments to find existing sequencing sample on server - not enough details to create one """
|
|
139
|
+
sample_sheet_lookup: SampleSheetLookup = field(metadata=config(field_name="sample_sheet"))
|
|
140
|
+
sample_name: str
|
|
141
|
+
|
|
142
|
+
|
|
135
143
|
@dataclass_json
|
|
136
144
|
@dataclass
|
|
137
145
|
class JointCalledVCF:
|
|
@@ -139,6 +147,10 @@ class JointCalledVCF:
|
|
|
139
147
|
path: str
|
|
140
148
|
sample_sheet_lookup: SampleSheetLookup = field(metadata=config(field_name="sample_sheet"))
|
|
141
149
|
variant_caller: VariantCaller
|
|
150
|
+
# Set for joint calls that draw samples from more than one sequencing run, eg a family trio.
|
|
151
|
+
# sample_sheet_lookup stays the owning run - the one the path sits under.
|
|
152
|
+
sequencing_samples: Optional[List[SequencingSampleLookup]] = \
|
|
153
|
+
field(default=None, metadata=config(exclude=lambda x: x is None))
|
|
142
154
|
|
|
143
155
|
|
|
144
156
|
@dataclass_json
|
|
@@ -190,14 +202,6 @@ class SequencingFile:
|
|
|
190
202
|
vcf_file: SingleSampleVCF
|
|
191
203
|
|
|
192
204
|
|
|
193
|
-
@dataclass_json
|
|
194
|
-
@dataclass
|
|
195
|
-
class SequencingSampleLookup:
|
|
196
|
-
""" Only used as arguments to find existing sequencing sample on server - not enough details to create one """
|
|
197
|
-
sample_sheet_lookup: SampleSheetLookup = field(metadata=config(field_name="sample_sheet"))
|
|
198
|
-
sample_name: str
|
|
199
|
-
|
|
200
|
-
|
|
201
205
|
@dataclass_json
|
|
202
206
|
@dataclass
|
|
203
207
|
class QC:
|
|
@@ -97,6 +97,26 @@ def test_create_joint_called_vcf_posts_json(api, server, vg_objects):
|
|
|
97
97
|
url
|
|
98
98
|
)
|
|
99
99
|
assert body["path"].endswith(".vcf.gz")
|
|
100
|
+
# A single-run joint call leaves the key off entirely, so the server keeps its existing behaviour
|
|
101
|
+
assert "sequencing_samples" not in body
|
|
102
|
+
|
|
103
|
+
|
|
104
|
+
@responses.activate
|
|
105
|
+
def test_create_joint_called_vcf_posts_cross_run_members(api, server, vg_objects):
|
|
106
|
+
url = f"{server}/seqauto/api/v1/joint_called_vcf/"
|
|
107
|
+
body = assert_post(
|
|
108
|
+
lambda: api.create_joint_called_vcf(
|
|
109
|
+
vg_objects["cross_run_joint_called_vcf"]
|
|
110
|
+
),
|
|
111
|
+
url
|
|
112
|
+
)
|
|
113
|
+
members = body["sequencing_samples"]
|
|
114
|
+
assert [m["sample_name"] for m in members] == ["fake_sample_1", "fake_sample_mum", "fake_sample_dad"]
|
|
115
|
+
# Members carry their own sample sheet, so two of them point at the run that sequenced the parents
|
|
116
|
+
runs = {m["sample_sheet"]["sequencing_run"] for m in members}
|
|
117
|
+
assert len(runs) == 2
|
|
118
|
+
# The owning sheet is still the run the path sits under
|
|
119
|
+
assert body["sample_sheet"]["sequencing_run"] == vg_objects["SEQUENCING_RUN_NAME"]
|
|
100
120
|
|
|
101
121
|
|
|
102
122
|
@responses.activate
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/src/variantgrid_api.egg-info/dependency_links.txt
RENAMED
|
File without changes
|
{variantgrid_api-1.3.2 → variantgrid_api-1.4.0}/src/variantgrid_api.egg-info/entry_points.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|