Skip to content

Add support for Python 3 #373

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 34 commits into from
Closed
Changes from 1 commit
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
eb0d02d
Add python 3.3 and 3.2 as allow_failures
graingert Apr 8, 2013
eb53791
add <1.6 to tests_require
graingert Apr 8, 2013
005ca0b
use sqlparse from pypi
graingert Apr 8, 2013
c73c77a
remove support for django <1.4.2
graingert Apr 8, 2013
c58094b
use new style exception in __init__.py
graingert Apr 8, 2013
e749ab1
port imports to py3k in middleware.py
graingert Apr 8, 2013
f6aad29
support new style exceptions in loader.py
graingert Apr 8, 2013
f1d5de5
port imports to py3k in utils/__init__.py
graingert Apr 8, 2013
61d1286
support new style exceptions in utils/tracking/__init__.py
graingert Apr 8, 2013
e4e8388
use force_text instead of force_unicode
graingert Apr 8, 2013
e3723e3
remove use of deprecated sqlparse.filters.Filters
graingert Apr 8, 2013
bab0aee
use thread from six.moves in tests/tests.py
graingert Apr 8, 2013
417c852
use assertEqual instead of assertEquals in tests
graingert Apr 8, 2013
3929d60
use iteritems from six, or items in templates
graingert Apr 8, 2013
068a6c1
use string_types from six instead of basestring
graingert Apr 8, 2013
7cb3cb0
use iterkeys and itervalues from six, or .keys and .values in templates
graingert Apr 8, 2013
c2485f5
deprecate functions unusable on Python3
graingert Apr 9, 2013
61bbd7f
use more simpler, more portable monkey_patch_call func in tracking
graingert Apr 9, 2013
cdfa803
use map from six
graingert Apr 9, 2013
494f421
force more things to bytes before hashing
graingert Apr 9, 2013
a30c83f
use text_type instead of unicode
graingert Apr 9, 2013
6e50c9f
add DJANGO_VERSION=1.5 to allow_failures
graingert Apr 9, 2013
47ea676
fix print function
w-diesel Apr 14, 2013
76a8159
Update profiling.py, attr. "func_closure" ( py2.6)
w-diesel Apr 14, 2013
f5d4cde
remove u'' prefix, import __future__ unicode_lit..
w-diesel Apr 14, 2013
0e6983a
use force_bytes to encode before hashing
graingert Apr 14, 2013
a088ed0
list expected
w-diesel Apr 14, 2013
3aa8c4c
Update middleware.py
w-diesel Apr 14, 2013
7a21c54
cache.py, fix python3.2 support
w-diesel Apr 15, 2013
fa40aa1
Masterbranch can pass all original tests on 1.5ver
w-diesel Apr 16, 2013
ee44437
Update .travis.yml
w-diesel Apr 16, 2013
fd2bb66
use unittest.skipIf to skip tests invalid on PY3
graingert Apr 23, 2013
09203c6
bump django version requirements to 1.4.5
graingert Apr 25, 2013
9a924cd
remove spaces from print functions
graingert Apr 25, 2013
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
use text_type instead of unicode
  • Loading branch information
graingert committed Apr 9, 2013
commit a30c83f20e9c57d9f533c07afa462f91b6b896cf
3 changes: 2 additions & 1 deletion debug_toolbar/utils/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
from django.views.debug import linebreak_iter
from django.utils import six
from django.utils.six.moves import socketserver, map
from django.utils.six import text_type
from django.utils.html import escape
from django.utils.safestring import mark_safe

Expand Down Expand Up @@ -59,7 +60,7 @@ def render_stacktrace(trace):
stacktrace = []
for frame in trace:
params = map(escape, frame[0].rsplit(os.path.sep, 1) + list(frame[1:]))
params_dict = dict((unicode(idx), v) for idx, v in enumerate(params))
params_dict = dict((text_type(idx), v) for idx, v in enumerate(params))
try:
stacktrace.append(u'<span class="path">%(0)s/</span>'
u'<span class="file">%(1)s</span>'
Expand Down