Skip to content

Commit 16a4f7d

Browse files
authored
Merge pull request #27 from neutrons/pre-commit-ci-update-config
[pre-commit.ci] pre-commit autoupdate
2 parents 231c97a + 95e1348 commit 16a4f7d

File tree

5 files changed

+9
-5
lines changed

5 files changed

+9
-5
lines changed

.pre-commit-config.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ repos:
1111
- id: end-of-file-fixer
1212
- id: trailing-whitespace
1313
- repo: https://github.com/astral-sh/ruff-pre-commit
14-
rev: v0.5.6
14+
rev: v0.6.1
1515
hooks:
1616
- id: ruff
1717
args: [--fix, --exit-non-zero-on-fix]

src/apps/plots/admin.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1-
from apps.plots.models import DataRun, Instrument, PlotData
21
from django.contrib import admin
32

3+
from apps.plots.models import DataRun, Instrument, PlotData
4+
45

56
class PlotDataAdmin(admin.ModelAdmin):
67
readonly_fields = ("data_run",)

src/apps/plots/management/commands/purge_expired_data.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
1-
from apps.plots.models import DataRun
21
from django.core.management.base import BaseCommand
32
from django.utils import timezone
43

4+
from apps.plots.models import DataRun
5+
56

67
class Command(BaseCommand):
78
help = "Delete expired runs and related plots"

src/apps/plots/view_util.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,12 @@
88
from datetime import datetime
99
from typing import Optional
1010

11-
from apps.plots.models import DataRun, Instrument, PlotData
1211
from django.conf import settings
1312
from django.http import HttpResponse
1413
from django.utils import timezone
1514

15+
from apps.plots.models import DataRun, Instrument, PlotData
16+
1617

1718
def generate_key(instrument, run_id):
1819
"""

src/apps/plots/views.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
import logging
77
from datetime import timedelta
88

9-
from apps.plots.models import DataRun, Instrument, PlotData
109
from django.conf import settings
1110
from django.contrib.auth import authenticate, login
1211
from django.http import HttpResponse, HttpResponseNotFound, JsonResponse
@@ -15,6 +14,8 @@
1514
from django.views.decorators.cache import cache_page
1615
from django.views.decorators.csrf import csrf_exempt
1716

17+
from apps.plots.models import DataRun, Instrument, PlotData
18+
1819
from . import view_util
1920

2021

0 commit comments

Comments
 (0)