1
0
mirror of https://github.com/django/django.git synced 2025-10-26 07:06:08 +00:00

Fixed a number of lint warnings, particularly around unused variables.

This commit is contained in:
Alex Gaynor
2013-08-04 09:17:10 -07:00
parent ebb3e50243
commit 3e0eb2d788
18 changed files with 39 additions and 52 deletions

View File

@@ -1,10 +1,12 @@
import os
from django.conf import settings
from django.core.cache import get_cache
from django.core.cache.backends.db import BaseDatabaseCache
from django.core.exceptions import ImproperlyConfigured
from django.db.backends.sqlite3.creation import DatabaseCreation
class SpatiaLiteCreation(DatabaseCreation):
def create_test_db(self, verbosity=1, autoclobber=False):
@@ -53,8 +55,6 @@ class SpatiaLiteCreation(DatabaseCreation):
interactive=False,
database=self.connection.alias)
from django.core.cache import get_cache
from django.core.cache.backends.db import BaseDatabaseCache
for cache_alias in settings.CACHES:
cache = get_cache(cache_alias)
if isinstance(cache, BaseDatabaseCache):
@@ -62,7 +62,7 @@ class SpatiaLiteCreation(DatabaseCreation):
# Get a cursor (even though we don't need one yet). This has
# the side effect of initializing the test database.
cursor = self.connection.cursor()
self.connection.cursor()
return test_database_name