SACGF / SACGF/variantgrid

DataTables - refactor after new feature to get queryset, not just values arrives

Open
#1,432 2 comments 0 reactions 1 assignee Claimed by @davmlaw View on GitHub
Refactoring
Dominant language
Python
Stars
30
Forks
3
Avg merge
9h 28m
Merged PRs (30d)
42

Description

Do once James' new code hits master.

In datatables, we sometimes have to pull out objects, which means double (and row-by-row) queries. Eg:

```
@staticmethod
def render_allele(data: CellData):
if value := data.value:
allele = Allele.objects.get(pk=value)

```

I thought this happened a few times, but have only found 2:

ImportedAlleleInfoColumns.render_allele
VariantTagDetailColumns.can_write

Probably worth an audit looking for these, could speed things up a bit

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.