diff --git a/galerie/autocomplete_light_registry.py b/galerie/autocomplete_light_registry.py index 38afde0c..dcedfc1a 100644 --- a/galerie/autocomplete_light_registry.py +++ b/galerie/autocomplete_light_registry.py @@ -1,7 +1,5 @@ # -*- coding: utf-8 -*- -from __future__ import unicode_literals - from autocomplete_light import shortcuts as autocomplete_light from .models import Obrazek, Galerie diff --git a/korektury/models.py b/korektury/models.py index 534677ed..6e5fed8a 100644 --- a/korektury/models.py +++ b/korektury/models.py @@ -3,7 +3,6 @@ import os from django.db import models from django.utils import timezone from django.conf import settings -from django.utils.encoding import python_2_unicode_compatible from django.utils.encoding import force_text from django.core.exceptions import ObjectDoesNotExist from django.utils.text import get_valid_filename @@ -29,7 +28,6 @@ def generate_filename(self, filename): #@reversion.register(ignore_duplicates=True) -#@python_2_unicode_compatible class KorekturovanePDF(models.Model): class Meta: ordering = ['-cas'] @@ -112,7 +110,6 @@ class KorekturovanePDF(models.Model): self.convert() @reversion.register(ignore_duplicates=True) -@python_2_unicode_compatible class Oprava(models.Model): class Meta: db_table = 'opravy' @@ -159,7 +156,6 @@ class Oprava(models.Model): @reversion.register(ignore_duplicates=True) -@python_2_unicode_compatible class Komentar(models.Model): class Meta: db_table = 'komentare' diff --git a/korektury/views.py b/korektury/views.py index 6a46b42c..c3f22569 100644 --- a/korektury/views.py +++ b/korektury/views.py @@ -13,7 +13,6 @@ from .forms import OpravaForm import subprocess import shutil import os -import unicodedata class KorekturyHelpView(generic.TemplateView): template_name = 'korektury/help.html' diff --git a/prednasky/models.py b/prednasky/models.py index 9ae9c63e..50c71984 100644 --- a/prednasky/models.py +++ b/prednasky/models.py @@ -1,7 +1,6 @@ # -*- coding: utf-8 -*- from django.db import models -from django.utils.encoding import python_2_unicode_compatible from django.utils.encoding import force_text from seminar.models import Organizator, Soustredeni diff --git a/seminar/tools.py b/seminar/tools.py index 2f8f8666..a13bdfd9 100644 --- a/seminar/tools.py +++ b/seminar/tools.py @@ -19,7 +19,7 @@ def merge_props(r1, r2, prop, pretend=True, smaller=False, equal=True): r1.__setattr__(prop, a2) elif a2: if equal and a1 != a2: - log.warn(u"merge: Ruzna %s: %s VS %s", prop, a1, a2) + log.warn("merge: Ruzna %s: %s VS %s", prop, a1, a2) if smaller: if not pretend: r1.__setattr__(prop, min(a1, a2)) @@ -33,16 +33,16 @@ def merge_Resitel(rbase, rmerge, pretend=True): # Ma relace: skola # Je v relaci: user, reseni, soustredeni_ucastnici, vysledky_base(VIEW) - log.info(u"merge: %s <- %s", unicode(rbase), unicode(rmerge)) + log.info("merge: %s <- %s", unicode(rbase), unicode(rmerge)) assert not rbase.user assert not rmerge.user assert rbase != rmerge if (rbase.jmeno != rmerge.jmeno) or (rbase.prijmeni != rmerge.prijmeni): - log.error(u"merge: Ruzna jmena: %s VS %s", rbase, rmerge) + log.error("merge: Ruzna jmena: %s VS %s", rbase, rmerge) if rbase.rok_maturity != rmerge.rok_maturity: - log.error(u"merge: Ruzne roky maturity: %s VS %s", rbase.rok_maturity, rmerge.rok_maturity) + log.error("merge: Ruzne roky maturity: %s VS %s", rbase.rok_maturity, rmerge.rok_maturity) with reversion.create_revision(): reversion.set_comment('Merge duplicitnich Resitelu: %r <- %r' % (rbase.pk, rmerge.pk))