-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #238 from wtsi-npg/devel
Release 2.3.0
- Loading branch information
Showing
33 changed files
with
1,143 additions
and
244 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"name": "npg-longue-vue", | ||
"version": "2.2.0", | ||
"version": "2.3.0", | ||
"description": "UI for LangQC", | ||
"author": "Kieron Taylor <[email protected]>", | ||
"license": "GPL-3.0-or-later", | ||
|
@@ -10,9 +10,9 @@ | |
}, | ||
"type": "module", | ||
"scripts": { | ||
"dev": "vite --port 3000", | ||
"dev": "vite --port 80 --mode development", | ||
"build": "vite build", | ||
"preview": "vite preview --port 3000", | ||
"preview": "vite preview --port 80", | ||
"test": "vitest run", | ||
"coverage": "vitest run --coverage", | ||
"test:e2e:ci": "start-server-and-test preview http://localhost:3000/ 'cypress run --e2e'", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
<script setup> | ||
import { ref } from "vue"; | ||
import { ElTooltip, ElCollapse, ElCollapseItem } from "element-plus"; | ||
const props = defineProps({ | ||
pool: Object, | ||
}) | ||
const active = ref([]) | ||
</script> | ||
|
||
<template> | ||
<el-collapse v-model="active" accordion> | ||
<el-collapse-item name="1"> | ||
<template #title><slot>Pool composition</slot></template> | ||
<el-tooltip content="Caution, this value is of low signficance when the pool size is small"> | ||
<p>Coefficient of Variance: {{ props.pool.pool_coeff_of_variance }}</p> | ||
</el-tooltip> | ||
<table> | ||
<tr> | ||
<th>Sample</th> | ||
<th>Tag 1</th> | ||
<th>Tag 2</th> | ||
<th>Deplexing barcode ID</th> | ||
<th>HiFi bases (Gb)</th> | ||
<th>HiFi reads</th> | ||
<th>HiFi mean read length</th> | ||
<th>Percentage of HiFi bases</th> | ||
<th>Percentage of total reads</th> | ||
</tr> | ||
<tr :key="library.id_product" v-for="library in props.pool.products"> | ||
<td>{{ library.sample_name }}</td> | ||
<td>{{ library.tag1_name }}</td> | ||
<td>{{ library.tag2_name }}</td> | ||
<td>{{ library.deplexing_barcode }}</td> | ||
<td>{{ library.hifi_read_bases }}</td> | ||
<td>{{ library.hifi_num_reads }}</td> | ||
<td>{{ library.hifi_read_length_mean }}</td> | ||
<td>{{ library.hifi_bases_percent }}</td> | ||
<td class="MetricYellow">{{ library.percentage_total_reads }}</td> | ||
</tr> | ||
</table> | ||
</el-collapse-item> | ||
</el-collapse> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
import { describe, expect, test } from 'vitest' | ||
import { mount } from '@vue/test-utils' | ||
import ElementPlus from 'element-plus' | ||
|
||
import PoolStats from '../PoolStats.vue' | ||
|
||
const wrapper = mount(PoolStats, { | ||
global: { | ||
plugins: [ElementPlus], | ||
}, | ||
props: { | ||
pool: { | ||
pool_coeff_of_variance: 47.2, | ||
products: [{ | ||
id_product: 'A'.repeat(64), | ||
sample_name: 'allthets', | ||
tag1_name: 'TTTTTTTT', | ||
tag2_name: null, | ||
deplexing_barcode: 'bc10--bc10', | ||
hifi_read_bases: 900, | ||
hifi_num_reads: 20, | ||
hifi_read_length_mean: 45, | ||
hifi_bases_percent: 90.001, | ||
percentage_total_reads: 66.6 | ||
},{ | ||
id_product: 'B'.repeat(64), | ||
sample_name: null, | ||
tag1_name: 'GGGGGGGG', | ||
tag2_name: null, | ||
deplexing_barcode: 'bc11--bc11', | ||
hifi_read_bases: 100, | ||
hifi_num_reads: 10, | ||
hifi_read_length_mean: 10, | ||
hifi_bases_percent: 100, | ||
percentage_total_reads: 33.3 | ||
}] | ||
} | ||
} | ||
}) | ||
|
||
describe('Create poolstats table with good data', () => { | ||
test('Component is "folded" by default', () => { | ||
expect(wrapper.getComponent('transition-stub').attributes()['appear']).toEqual('false') | ||
}) | ||
|
||
test('Coefficient of variance showing', async () => { | ||
let topStat = wrapper.find('p') | ||
await topStat.trigger('focus') | ||
expect(topStat.classes('el-tooltip__trigger')).toBeTruthy() | ||
|
||
expect(topStat.text()).toEqual('Coefficient of Variance: 47.2') | ||
}) | ||
|
||
test('Table looks about right', () => { | ||
let rows = wrapper.findAll('tr') | ||
expect(rows.length).toEqual(3) | ||
|
||
// Check tag 1 has been set | ||
expect(rows[1].findAll('td')[1].text()).toEqual('TTTTTTTT') | ||
expect(rows[2].findAll('td')[1].text()).toEqual('GGGGGGGG') | ||
|
||
// Sample name column set appropriately | ||
expect(rows[1].find('td').text()).toEqual('allthets') | ||
expect(rows[2].find('td').text()).toEqual('') | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
__version__ = "2.2.0" | ||
__version__ = "2.3.0" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# Copyright (c) 2022, 2023 Genome Research Ltd. | ||
# Copyright (c) 2022, 2023, 2024 Genome Research Ltd. | ||
# | ||
# Authors: | ||
# Marina Gourtovaia <[email protected]> | ||
|
@@ -38,6 +38,7 @@ | |
from lang_qc.models.qc_flow_status import QcFlowStatusEnum | ||
from lang_qc.models.qc_state import QcState as QcStateModel | ||
from lang_qc.util.errors import EmptyListOfRunNamesError, RunNotFoundError | ||
from lang_qc.util.type_checksum import PacBioWellSHA256 | ||
|
||
""" | ||
This package is using an undocumented feature of Pydantic, type | ||
|
@@ -64,7 +65,7 @@ class WellWh(BaseModel): | |
# The TestClient seems to be keeping these instances alive and changing them. | ||
|
||
def get_mlwh_well_by_product_id( | ||
self, id_product: str | ||
self, id_product: PacBioWellSHA256 | ||
) -> PacBioRunWellMetrics | None: | ||
""" | ||
Returns a well row record from the well metrics table or | ||
|
Oops, something went wrong.