Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Dec 2, 2024
1 parent 610f9ff commit 48046e7
Showing 1 changed file with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
from cl.lib.command_utils import VerboseCommand,logger
from django.db import connection

from cl.lib.command_utils import VerboseCommand, logger


class Command(VerboseCommand):
help = """Refreshes the `scrapers_mv_latest_opinion` materialized view.
Check the cl.scrapers.admin.py file for more info about the view
"""

def handle(self, *args, **options):
query = "REFRESH MATERIALIZED VIEW scrapers_mv_latest_opinion;"
with connection.cursor() as cursor:
cursor.execute(query)

logger.info("View refresh completed successfully")

0 comments on commit 48046e7

Please sign in to comment.