Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
django
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
django
Commits
fed25f11
Kaydet (Commit)
fed25f11
authored
Kas 24, 2014
tarafından
Tim Graham
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Removed compatibility with Python 3.2.
üst
4e65f195
Show whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
13 additions
and
40 deletions
+13
-40
message.py
django/core/mail/message.py
+0
-5
__init__.py
django/core/management/__init__.py
+0
-2
html.py
django/utils/html.py
+1
-9
html_parser.py
django/utils/html_parser.py
+1
-4
install.txt
docs/faq/install.txt
+1
-1
install.txt
docs/intro/install.txt
+3
-3
tutorial01.txt
docs/intro/tutorial01.txt
+1
-1
install.txt
docs/topics/install.txt
+2
-2
setup.py
setup.py
+0
-1
base.txt
tests/requirements/base.txt
+0
-2
py2.txt
tests/requirements/py2.txt
+1
-0
test_jinja2.py
tests/template_backends/test_jinja2.py
+3
-10
No files found.
django/core/mail/message.py
Dosyayı görüntüle @
fed25f11
...
@@ -104,12 +104,7 @@ def sanitize_address(addr, encoding):
...
@@ -104,12 +104,7 @@ def sanitize_address(addr, encoding):
if
isinstance
(
addr
,
six
.
string_types
):
if
isinstance
(
addr
,
six
.
string_types
):
addr
=
parseaddr
(
force_text
(
addr
))
addr
=
parseaddr
(
force_text
(
addr
))
nm
,
addr
=
addr
nm
,
addr
=
addr
# This try-except clause is needed on Python 3 < 3.2.4
# http://bugs.python.org/issue14291
try
:
nm
=
Header
(
nm
,
encoding
)
.
encode
()
nm
=
Header
(
nm
,
encoding
)
.
encode
()
except
UnicodeEncodeError
:
nm
=
Header
(
nm
,
'utf-8'
)
.
encode
()
try
:
try
:
addr
.
encode
(
'ascii'
)
addr
.
encode
(
'ascii'
)
except
UnicodeEncodeError
:
# IDN
except
UnicodeEncodeError
:
# IDN
...
...
django/core/management/__init__.py
Dosyayı görüntüle @
fed25f11
...
@@ -25,8 +25,6 @@ def find_commands(management_dir):
...
@@ -25,8 +25,6 @@ def find_commands(management_dir):
Returns an empty list if no commands are defined.
Returns an empty list if no commands are defined.
"""
"""
command_dir
=
os
.
path
.
join
(
management_dir
,
'commands'
)
command_dir
=
os
.
path
.
join
(
management_dir
,
'commands'
)
# Workaround for a Python 3.2 bug with pkgutil.iter_modules
sys
.
path_importer_cache
.
pop
(
command_dir
,
None
)
return
[
name
for
_
,
name
,
is_pkg
in
pkgutil
.
iter_modules
([
command_dir
])
return
[
name
for
_
,
name
,
is_pkg
in
pkgutil
.
iter_modules
([
command_dir
])
if
not
is_pkg
and
not
name
.
startswith
(
'_'
)]
if
not
is_pkg
and
not
name
.
startswith
(
'_'
)]
...
...
django/utils/html.py
Dosyayı görüntüle @
fed25f11
...
@@ -3,7 +3,6 @@
...
@@ -3,7 +3,6 @@
from
__future__
import
unicode_literals
from
__future__
import
unicode_literals
import
re
import
re
import
sys
import
warnings
import
warnings
from
django.utils.deprecation
import
RemovedInDjango20Warning
from
django.utils.deprecation
import
RemovedInDjango20Warning
...
@@ -135,11 +134,6 @@ linebreaks = allow_lazy(linebreaks, six.text_type)
...
@@ -135,11 +134,6 @@ linebreaks = allow_lazy(linebreaks, six.text_type)
class
MLStripper
(
HTMLParser
):
class
MLStripper
(
HTMLParser
):
def
__init__
(
self
):
def
__init__
(
self
):
# The strict parameter was added in Python 3.2 with a default of True.
# The default changed to False in Python 3.3 and was deprecated.
if
sys
.
version_info
[:
2
]
==
(
3
,
2
):
HTMLParser
.
__init__
(
self
,
strict
=
False
)
else
:
HTMLParser
.
__init__
(
self
)
HTMLParser
.
__init__
(
self
)
self
.
reset
()
self
.
reset
()
self
.
fed
=
[]
self
.
fed
=
[]
...
@@ -168,9 +162,7 @@ def _strip_once(value):
...
@@ -168,9 +162,7 @@ def _strip_once(value):
return
value
return
value
try
:
try
:
s
.
close
()
s
.
close
()
except
(
HTMLParseError
,
UnboundLocalError
):
except
HTMLParseError
:
# UnboundLocalError because of http://bugs.python.org/issue17802
# on Python 3.2, triggered by strict=False mode of HTMLParser
return
s
.
get_data
()
+
s
.
rawdata
return
s
.
get_data
()
+
s
.
rawdata
else
:
else
:
return
s
.
get_data
()
return
s
.
get_data
()
...
...
django/utils/html_parser.py
Dosyayı görüntüle @
fed25f11
...
@@ -4,10 +4,7 @@ import sys
...
@@ -4,10 +4,7 @@ import sys
current_version
=
sys
.
version_info
current_version
=
sys
.
version_info
use_workaround
=
(
use_workaround
=
current_version
<
(
2
,
7
,
3
)
(
current_version
<
(
2
,
7
,
3
))
or
(
current_version
>=
(
3
,
0
)
and
current_version
<
(
3
,
2
,
3
))
)
try
:
try
:
HTMLParseError
=
_html_parser
.
HTMLParseError
HTMLParseError
=
_html_parser
.
HTMLParseError
...
...
docs/faq/install.txt
Dosyayı görüntüle @
fed25f11
...
@@ -16,7 +16,7 @@ How do I get started?
...
@@ -16,7 +16,7 @@ How do I get started?
What are Django's prerequisites?
What are Django's prerequisites?
--------------------------------
--------------------------------
Django requires Python, specifically Python 2.7 or 3.
2
and above. Other Python
Django requires Python, specifically Python 2.7 or 3.
3
and above. Other Python
libraries may be required for some uses, but you'll receive an error about it
libraries may be required for some uses, but you'll receive an error about it
as they're needed.
as they're needed.
...
...
docs/intro/install.txt
Dosyayı görüntüle @
fed25f11
...
@@ -9,9 +9,9 @@ that'll work while you walk through the introduction.
...
@@ -9,9 +9,9 @@ that'll work while you walk through the introduction.
Install Python
Install Python
--------------
--------------
Being a Python Web framework, Django requires Python. It works with Python 2.7
,
Being a Python Web framework, Django requires Python. It works with Python 2.7
3.
2, 3.3, or 3.4. All these versions of Python include a lightweight database
3.
3+. All these versions of Python include a lightweight database called
called
SQLite_ so you won't need to set up a database just yet.
SQLite_ so you won't need to set up a database just yet.
.. _sqlite: http://sqlite.org/
.. _sqlite: http://sqlite.org/
...
...
docs/intro/tutorial01.txt
Dosyayı görüntüle @
fed25f11
...
@@ -22,7 +22,7 @@ tell Django is installed and which version by running the following command:
...
@@ -22,7 +22,7 @@ tell Django is installed and which version by running the following command:
If Django is installed, you should see the version of your installation. If it
If Django is installed, you should see the version of your installation. If it
isn't, you'll get an error telling "No module named django".
isn't, you'll get an error telling "No module named django".
This tutorial is written for Django |version| and Python 3.
2
or later. If the
This tutorial is written for Django |version| and Python 3.
3
or later. If the
Django version doesn't match, you can refer to the tutorial for your version
Django version doesn't match, you can refer to the tutorial for your version
of Django by using the version switcher at the bottom right corner of this
of Django by using the version switcher at the bottom right corner of this
page, or update Django to the newest version. If you are still using Python
page, or update Django to the newest version. If you are still using Python
...
...
docs/topics/install.txt
Dosyayı görüntüle @
fed25f11
...
@@ -7,8 +7,8 @@ This document will get you up and running with Django.
...
@@ -7,8 +7,8 @@ This document will get you up and running with Django.
Install Python
Install Python
==============
==============
Being a Python Web framework, Django requires Python. It works with Python 2.7
,
Being a Python Web framework, Django requires Python. It works with Python 2.7
3.2 or 3.3
.
or 3.3+
.
Get the latest version of Python at https://www.python.org/download/ or with
Get the latest version of Python at https://www.python.org/download/ or with
your operating system's package manager.
your operating system's package manager.
...
...
setup.py
Dosyayı görüntüle @
fed25f11
...
@@ -62,7 +62,6 @@ setup(
...
@@ -62,7 +62,6 @@ setup(
'Programming Language :: Python :: 2'
,
'Programming Language :: Python :: 2'
,
'Programming Language :: Python :: 2.7'
,
'Programming Language :: Python :: 2.7'
,
'Programming Language :: Python :: 3'
,
'Programming Language :: Python :: 3'
,
'Programming Language :: Python :: 3.2'
,
'Programming Language :: Python :: 3.3'
,
'Programming Language :: Python :: 3.3'
,
'Programming Language :: Python :: 3.4'
,
'Programming Language :: Python :: 3.4'
,
'Topic :: Internet :: WWW/HTTP'
,
'Topic :: Internet :: WWW/HTTP'
,
...
...
tests/requirements/base.txt
Dosyayı görüntüle @
fed25f11
bcrypt
bcrypt
docutils
docutils
jinja2
jinja2
# move to py2.txt when dropping Python 3.2
mock
numpy
numpy
Pillow
Pillow
PyYAML
PyYAML
...
...
tests/requirements/py2.txt
Dosyayı görüntüle @
fed25f11
-r base.txt
-r base.txt
python-memcached
python-memcached
mock
tests/template_backends/test_jinja2.py
Dosyayı görüntüle @
fed25f11
...
@@ -2,22 +2,15 @@
...
@@ -2,22 +2,15 @@
# silence an ImportWarning warning on Python 2.
# silence an ImportWarning warning on Python 2.
from
__future__
import
absolute_import
from
__future__
import
absolute_import
import
sys
from
unittest
import
skipIf
from
unittest
import
skipIf
# Jinja2 doesn't run on Python 3.2 because it uses u-prefixed unicode strings.
try
:
if
sys
.
version_info
[:
2
]
==
(
2
,
7
)
or
sys
.
version_info
[:
2
]
>=
(
3
,
3
):
try
:
import
jinja2
import
jinja2
except
ImportError
:
except
ImportError
:
jinja2
=
None
jinja2
=
None
Jinja2
=
None
Jinja2
=
None
else
:
from
django.template.backends.jinja2
import
Jinja2
else
:
else
:
jinja2
=
None
from
django.template.backends.jinja2
import
Jinja2
Jinja2
=
None
from
.test_dummy
import
TemplateStringsTests
from
.test_dummy
import
TemplateStringsTests
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment