From 0f6e567b21b9cfbae86c7bfdff82eb0b3e673cc1 Mon Sep 17 00:00:00 2001 From: Ross Chapman Date: Tue, 5 Dec 2023 19:49:38 -0800 Subject: [PATCH] Clean up --- bookwyrm/settings.py | 4 ++-- bookwyrm/templates/shelf/shelf.html | 3 --- bookwyrm/tests/views/test_search.py | 2 +- bookwyrm/views/shelf/shelf.py | 4 ---- docker-compose.yml | 2 -- 5 files changed, 3 insertions(+), 12 deletions(-) diff --git a/bookwyrm/settings.py b/bookwyrm/settings.py index c5f5f52f4..4cecc4df6 100644 --- a/bookwyrm/settings.py +++ b/bookwyrm/settings.py @@ -140,7 +140,7 @@ TEMPLATES = [ }, ] -LOG_LEVEL = env("LOG_LEVEL", "DEBUG").upper() +LOG_LEVEL = env("LOG_LEVEL", "INFO").upper() # Override aspects of the default handler to our taste # See https://docs.djangoproject.com/en/3.2/topics/logging/#default-logging-configuration # for a reference to the defaults we're overriding @@ -194,7 +194,7 @@ LOGGING = { # Add a bookwyrm-specific logger "bookwyrm": { "handlers": ["console"], - "level": DEBUG, + "level": LOG_LEVEL, }, }, } diff --git a/bookwyrm/templates/shelf/shelf.html b/bookwyrm/templates/shelf/shelf.html index 4fb78ba6f..14b748e54 100644 --- a/bookwyrm/templates/shelf/shelf.html +++ b/bookwyrm/templates/shelf/shelf.html @@ -121,11 +121,8 @@ {% endblocktrans %} {% endif %} - {% endif %} - {% endwith %} - {% if books|length > 0 %} {% include 'shelf/search_filters.html' with user=user query=query %} diff --git a/bookwyrm/tests/views/test_search.py b/bookwyrm/tests/views/test_search.py index 021d502f0..28f8268e3 100644 --- a/bookwyrm/tests/views/test_search.py +++ b/bookwyrm/tests/views/test_search.py @@ -9,7 +9,7 @@ from django.test import TestCase from django.test.client import RequestFactory from bookwyrm import models, views -from bookwyrm.book_search import SearchResult, search +from bookwyrm.book_search import SearchResult from bookwyrm.settings import DOMAIN from bookwyrm.tests.validate_html import validate_html diff --git a/bookwyrm/views/shelf/shelf.py b/bookwyrm/views/shelf/shelf.py index be205597b..aad90da82 100644 --- a/bookwyrm/views/shelf/shelf.py +++ b/bookwyrm/views/shelf/shelf.py @@ -17,10 +17,6 @@ from bookwyrm.settings import PAGE_LENGTH from bookwyrm.views.helpers import is_api_request, get_user_from_username from bookwyrm.book_search import search -import logging -logger = logging.getLogger(__name__) - - # pylint: disable=no-self-use class Shelf(View): """shelf page""" diff --git a/docker-compose.yml b/docker-compose.yml index bb0acbdd1..4d4037681 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -21,8 +21,6 @@ services: - pgdata:/var/lib/postgresql/data networks: - main - ports: - - "5432:5432" web: build: . env_file: .env