Fixes issue #67 - settings imports unicode_literals from __future__

This commit is contained in:
Marco Bonetti 2013-03-04 18:24:36 +01:00
parent e077f19b54
commit f1a332bf90
4 changed files with 14 additions and 7 deletions

View file

@ -1,3 +1,7 @@
Version 0.7.2
-------------
* Fix for when settings imports unicode_literals for some reason (Issue #67)
Version 0.7.1
-------------
* Fix: value missing in context

View file

@ -1,4 +1,4 @@
VERSION = (0, 7, 1)
VERSION = (0, 7, 2)
def get_version(svn=False, limit=3):

View file

@ -1,9 +1,10 @@
import os
import django
from django.conf import settings
from rosetta.conf import settings as rosetta_settings
from django.core.cache import cache
from datetime import datetime
from django.conf import settings
from django.core.cache import cache
from rosetta.conf import settings as rosetta_settings
import django
import os
import six
try:
from django.utils import timezone
except:
@ -73,7 +74,7 @@ def find_pos(lang, project_apps=True, django_apps=False, third_party_apps=False)
continue
p = appname.rfind('.')
if p >= 0:
app = getattr(__import__(appname[:p], {}, {}, [appname[p + 1:]]), appname[p + 1:])
app = getattr(__import__(appname[:p], {}, {}, [str(appname[p + 1:])]), appname[p + 1:])
else:
app = __import__(appname, {}, {}, [])

View file

@ -1,8 +1,10 @@
# -*- coding: utf-8 -*-
#from __future__ import unicode_literals
import django
import os
import sys
SITE_ID = 1
PROJECT_PATH = os.path.abspath(os.path.dirname(__file__))