Skip to content

Commit

Permalink
style: linter suggestions (#20)
Browse files Browse the repository at this point in the history
remove unused imports, minor tweaks
  • Loading branch information
alubbock authored Aug 8, 2024
1 parent 424ccbb commit 8e41bf5
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion thunorweb/apps.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from django.apps import AppConfig
from django.conf import settings
from django.db.models.signals import post_save
from django.db.utils import ProgrammingError, OperationalError, DatabaseError
from django.db.utils import ProgrammingError, OperationalError


class ThunorConfig(AppConfig):
Expand Down
2 changes: 1 addition & 1 deletion thunorweb/tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,7 @@ def _dataset_groupings(dataset, regenerate_cache=False):
missing_combos = []
for cl in cell_line_ids:
for dr in drug_ids:
if not (cl, dr) in combos:
if (cl, dr) not in combos:
missing_combos.append((str(cl), (str(dr), )))

if has_drug_combos:
Expand Down
2 changes: 1 addition & 1 deletion thunorweb/views/dataset_downloads.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
from django.conf import settings
import os
from thunorweb.serve_file import serve_file
from thunorweb.views.datasets import license_accepted, LICENSE_UNSIGNED
from thunorweb.views.datasets import license_accepted
from django.views.decorators.clickjacking import xframe_options_sameorigin
from thunorweb.views import login_required_unless_public, _assert_has_perm

Expand Down
2 changes: 1 addition & 1 deletion thunorweb/views/plate_mapper.py
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ def ajax_save_plate(request):
wells_to_insert = []
for plate in plate_ids:
for well_num, cell_line_id in enumerate(cell_line_ids):
if not (plate, well_num) in existing_wells:
if (plate, well_num) not in existing_wells:
wells_to_insert.append(Well(
well_num=well_num,
plate_id=plate,
Expand Down
2 changes: 1 addition & 1 deletion thunorweb/views/plots.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from django.shortcuts import render, Http404
from django.http import JsonResponse, HttpResponse
from django.http import HttpResponse
from django.utils.html import strip_tags
from django.views.decorators.csrf import ensure_csrf_cookie
from django.core.cache import cache
Expand Down
2 changes: 1 addition & 1 deletion thunorweb/views/tags.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from django.db import transaction
from django.db.models import Q
from thunorweb.models import CellLine, Drug, CellLineTag, DrugTag
from thunorweb.views import login_required_unless_public, login_required
from thunorweb.views import login_required_unless_public
import logging
import pandas as pd
from django.db.utils import IntegrityError
Expand Down

0 comments on commit 8e41bf5

Please sign in to comment.