Remove unused imports

This commit is contained in:
Magnus Hagander
2018-06-29 13:38:47 +02:00
parent 9a746bd6c1
commit 0c6099e236
14 changed files with 9 additions and 29 deletions

View File

@ -1,5 +1,5 @@
from django import forms
from django.contrib.auth.forms import AuthenticationForm, PasswordResetForm
from django.contrib.auth.forms import AuthenticationForm
import re

View File

@ -5,8 +5,7 @@
#
from django.core.management.base import BaseCommand
from django.db import connection, transaction
from django.conf import settings
from django.db import transaction
import socket
import feedparser

View File

@ -5,7 +5,7 @@
#
from django.core.management.base import BaseCommand
from django.db import connection, transaction
from django.db import transaction
from django.conf import settings
from datetime import datetime

View File

@ -1,5 +1,4 @@
from django.db import models
from django.contrib.auth.models import User
from pgweb.core.models import Version
class DocPage(models.Model):

View File

@ -2,8 +2,6 @@ from django.db import models
from pgweb.core.models import Organisation
from datetime import datetime
class Category(models.Model):
catname = models.CharField(max_length=100, null=False, blank=False)

View File

@ -1,20 +1,17 @@
from django.core.urlresolvers import reverse
from django.shortcuts import render, get_object_or_404
from django.http import HttpResponse, Http404, HttpResponseRedirect
from pgweb.util.decorators import login_required
from django.views.decorators.csrf import csrf_exempt
from django.db import transaction
from django.conf import settings
import os
import urlparse
import cPickle as pickle
import json
from pgweb.util.decorators import nocache
from pgweb.util.contexts import render_pgweb
from pgweb.util.helpers import simple_form, PgXmlHelper, HttpServerError
from pgweb.util.misc import get_client_ip, varnish_purge, version_sort
from pgweb.util.misc import varnish_purge, version_sort
from pgweb.core.models import Version
from models import Category, Product, StackBuilderApp

View File

@ -1,7 +1,4 @@
from django.shortcuts import get_object_or_404
from django.http import HttpResponse, HttpResponseForbidden
from django.views.decorators.csrf import csrf_exempt
from django.conf import settings
from django.http import HttpResponse
import json

View File

@ -5,7 +5,7 @@
#
from django.core.management.base import BaseCommand, CommandError
from django.db import connection, transaction
from django.db import connection
from django.conf import settings
from datetime import datetime, timedelta

View File

@ -1,7 +1,5 @@
from django.contrib import admin
from django import forms
from django.db import models
from django.core.validators import ValidationError
from django.conf import settings
from pgweb.core.models import Version

View File

@ -4,7 +4,7 @@
#
from django.core.management.base import BaseCommand
from django.db import connection, transaction
from django.db import transaction
from django.conf import settings
from pgweb.security.models import SecurityPatch

View File

@ -1,6 +1,6 @@
from django.shortcuts import get_object_or_404
from django.http import HttpResponseRedirect
from django.db import connection, transaction
from django.db import connection
from django.template.defaultfilters import slugify
from django.views.decorators.csrf import csrf_exempt

View File

@ -1,8 +1,5 @@
from django.contrib.auth.models import User
from django.contrib.auth.backends import ModelBackend
from django.db import connection
from pgweb.core.models import UserProfile
# Special version of the authentication backend, so we can handle things like
# forced lowercasing of usernames.

View File

@ -20,8 +20,6 @@ def cache(days=0, hours=0, minutes=0, seconds=0):
return __cache
return _cache
from django.utils.decorators import available_attrs
# A wrapped version of login_required that throws an exception if it's
# used on a path that's not under /account/.
def login_required(f):

View File

@ -1,10 +1,7 @@
from django.http import HttpResponseRedirect, HttpResponse
from django.conf import settings
# Use thread local storage to pass the username down.
# http://code.djangoproject.com/wiki/CookBookThreadlocalsAndUser
try:
from threading import local, currentThread
from threading import local
except ImportError:
from django.utils._threading_local import local