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
428c0bbe
Kaydet (Commit)
428c0bbe
authored
Nis 21, 2014
tarafından
Aymeric Augustin
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Appeased flake8 2.1.0.
üst
df3b1a01
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
26 additions
and
28 deletions
+26
-28
__init__.py
django/contrib/auth/management/__init__.py
+3
-3
views.py
django/contrib/gis/views.py
+1
-5
collectstatic.py
.../contrib/staticfiles/management/commands/collectstatic.py
+4
-3
loaddata.py
django/core/management/commands/loaddata.py
+3
-3
base.py
django/db/models/base.py
+1
-1
expressions.py
django/db/models/expressions.py
+3
-3
__init__.py
django/db/models/fields/__init__.py
+1
-1
ipv6.py
django/utils/ipv6.py
+1
-1
setup.cfg
setup.cfg
+1
-1
tests.py
tests/cache/tests.py
+2
-2
test_writer.py
tests/migrations/test_writer.py
+1
-1
tests.py
tests/model_inheritance/tests.py
+1
-1
tests.py
tests/staticfiles_tests/tests.py
+4
-3
No files found.
django/contrib/auth/management/__init__.py
Dosyayı görüntüle @
428c0bbe
...
...
@@ -97,9 +97,9 @@ def create_permissions(app_config, verbosity=2, interactive=True, using=DEFAULT_
))
perms
=
[
Permission
(
codename
=
codename
,
name
=
name
,
content_type
=
ct
ype
)
for
ct
ype
,
(
codename
,
name
)
in
searched_perms
if
(
ct
ype
.
pk
,
codename
)
not
in
all_perms
Permission
(
codename
=
codename
,
name
=
name
,
content_type
=
ct
)
for
ct
,
(
codename
,
name
)
in
searched_perms
if
(
ct
.
pk
,
codename
)
not
in
all_perms
]
# Validate the permissions before bulk_creation to avoid cryptic
# database error when the verbose_name is longer than 50 characters
...
...
django/contrib/gis/views.py
Dosyayı görüntüle @
428c0bbe
...
...
@@ -9,11 +9,7 @@ def feed(request, url, feed_dict=None):
if
not
feed_dict
:
raise
Http404
(
_
(
"No feeds are registered."
))
try
:
slug
,
param
=
url
.
split
(
'/'
,
1
)
except
ValueError
:
slug
,
param
=
url
,
''
slug
=
url
.
partition
(
'/'
)[
0
]
try
:
f
=
feed_dict
[
slug
]
except
KeyError
:
...
...
django/contrib/staticfiles/management/commands/collectstatic.py
Dosyayı görüntüle @
428c0bbe
...
...
@@ -9,7 +9,8 @@ from django.core.management.base import CommandError, NoArgsCommand
from
django.utils.encoding
import
smart_text
from
django.utils.six.moves
import
input
from
django.contrib.staticfiles
import
finders
,
storage
from
django.contrib.staticfiles.finders
import
get_finders
from
django.contrib.staticfiles.storage
import
staticfiles_storage
class
Command
(
NoArgsCommand
):
...
...
@@ -52,7 +53,7 @@ class Command(NoArgsCommand):
self
.
symlinked_files
=
[]
self
.
unmodified_files
=
[]
self
.
post_processed_files
=
[]
self
.
storage
=
st
orage
.
st
aticfiles_storage
self
.
storage
=
staticfiles_storage
try
:
self
.
storage
.
path
(
''
)
except
NotImplementedError
:
...
...
@@ -93,7 +94,7 @@ class Command(NoArgsCommand):
handler
=
self
.
copy_file
found_files
=
OrderedDict
()
for
finder
in
finders
.
get_finders
():
for
finder
in
get_finders
():
for
path
,
storage
in
finder
.
list
(
self
.
ignore_patterns
):
# Prefix the relative path if the source storage contains it
if
getattr
(
storage
,
'prefix'
,
None
):
...
...
django/core/management/commands/loaddata.py
Dosyayı görüntüle @
428c0bbe
...
...
@@ -239,9 +239,9 @@ class Command(BaseCommand):
for
app_config
in
apps
.
get_app_configs
():
if
self
.
app_label
and
app_config
.
label
!=
self
.
app_label
:
continue
d
=
os
.
path
.
join
(
app_config
.
path
,
'fixtures'
)
if
os
.
path
.
isdir
(
d
):
dirs
.
append
(
d
)
app_dir
=
os
.
path
.
join
(
app_config
.
path
,
'fixtures'
)
if
os
.
path
.
isdir
(
app_dir
):
dirs
.
append
(
app_dir
)
dirs
.
extend
(
list
(
settings
.
FIXTURE_DIRS
))
dirs
.
append
(
''
)
dirs
=
[
upath
(
os
.
path
.
abspath
(
os
.
path
.
realpath
(
d
)))
for
d
in
dirs
]
...
...
django/db/models/base.py
Dosyayı görüntüle @
428c0bbe
...
...
@@ -1106,7 +1106,7 @@ class Model(six.with_metaclass(ModelBase)):
errors
=
[]
managers
=
cls
.
_meta
.
concrete_managers
+
cls
.
_meta
.
abstract_managers
for
(
_
,
_
,
manager
)
in
managers
:
for
__
,
__
,
manager
in
managers
:
errors
.
extend
(
manager
.
check
(
**
kwargs
))
return
errors
...
...
django/db/models/expressions.py
Dosyayı görüntüle @
428c0bbe
...
...
@@ -15,9 +15,9 @@ class ExpressionNode(tree.Node):
MUL
=
'*'
DIV
=
'/'
POW
=
'^'
MOD
=
'
%%
'
# This is a quoted % operator - it is quoted
# because it can be used in strings that also
# have parameter substitution.
# The following is a quoted % operator - it is quoted because it can be
# used in strings that also have parameter substitution.
MOD
=
'
%%
'
# Bitwise operators - note that these are generated by .bitand()
# and .bitor(), the '&' and '|' are reserved for boolean operator
...
...
django/db/models/fields/__init__.py
Dosyayı görüntüle @
428c0bbe
...
...
@@ -728,7 +728,7 @@ class Field(RegisterLookupMixin):
"""Returns choices with a default blank choices included, for use
as SelectField choices for this field."""
blank_defined
=
False
for
choice
,
_
in
self
.
choices
:
for
choice
,
_
_
in
self
.
choices
:
if
choice
in
(
''
,
None
):
blank_defined
=
True
break
...
...
django/utils/ipv6.py
Dosyayı görüntüle @
428c0bbe
...
...
@@ -239,7 +239,7 @@ def _explode_shorthand_ip_string(ip_str):
sep
=
len
(
hextet
[
0
]
.
split
(
':'
))
+
len
(
hextet
[
1
]
.
split
(
':'
))
new_ip
=
hextet
[
0
]
.
split
(
':'
)
for
_
in
xrange
(
fill_to
-
sep
):
for
_
_
in
xrange
(
fill_to
-
sep
):
new_ip
.
append
(
'0000'
)
new_ip
+=
hextet
[
1
]
.
split
(
':'
)
...
...
setup.cfg
Dosyayı görüntüle @
428c0bbe
...
...
@@ -4,7 +4,7 @@ install-script = scripts/rpm-install.sh
[flake8]
exclude=build,.git,./django/utils/dictconfig.py,./django/utils/unittest.py,./django/utils/lru_cache.py,./django/utils/six.py,./django/conf/app_template/*,./django/dispatch/weakref_backports.py
ignore=E12
8
,E501,W601
ignore=E12
3,E128,E265
,E501,W601
[metadata]
license-file = LICENSE
...
...
tests/cache/tests.py
Dosyayı görüntüle @
428c0bbe
...
...
@@ -1097,8 +1097,8 @@ class MemcachedCacheTests(BaseCacheTests, TestCase):
"cache with python-memcached library not available"
)
def
test_memcached_uses_highest_pickle_version
(
self
):
# Regression test for #19810
for
cache_key
,
cache
in
settings
.
CACHES
.
items
():
if
cache
[
'BACKEND'
]
==
'django.core.cache.backends.memcached.MemcachedCache'
:
for
cache_key
,
cache
_config
in
settings
.
CACHES
.
items
():
if
cache
_config
[
'BACKEND'
]
==
'django.core.cache.backends.memcached.MemcachedCache'
:
self
.
assertEqual
(
caches
[
cache_key
]
.
_cache
.
pickleProtocol
,
pickle
.
HIGHEST_PROTOCOL
)
...
...
tests/migrations/test_writer.py
Dosyayı görüntüle @
428c0bbe
...
...
@@ -160,7 +160,7 @@ class WriterTests(TestCase):
# In order to preserve compatibility with Python 3.2 unicode literals
# prefix shouldn't be added to strings.
tokens
=
tokenize
.
generate_tokens
(
six
.
StringIO
(
str
(
output
))
.
readline
)
for
token_type
,
token_source
,
(
srow
,
scol
),
_
,
line
in
tokens
:
for
token_type
,
token_source
,
(
srow
,
scol
),
_
_
,
line
in
tokens
:
if
token_type
==
tokenize
.
STRING
:
self
.
assertFalse
(
token_source
.
startswith
(
'u'
),
...
...
tests/model_inheritance/tests.py
Dosyayı görüntüle @
428c0bbe
...
...
@@ -6,7 +6,7 @@ from django.core.exceptions import FieldError
from
django.core.management
import
call_command
from
django.db
import
connection
from
django.test
import
TestCase
from
django.test.utils
import
CaptureQueriesContext
,
override_settings
from
django.test.utils
import
CaptureQueriesContext
from
django.utils
import
six
from
.models
import
(
...
...
tests/staticfiles_tests/tests.py
Dosyayı görüntüle @
428c0bbe
...
...
@@ -848,9 +848,10 @@ class TestDefaultStorageFinder(StaticFilesTestCase, FinderTestCase):
self
.
find_all
=
(
'media-file.txt'
,
[
test_file_path
])
@override_settings
(
STATICFILES_FINDERS
=
(
'django.contrib.staticfiles.finders.FileSystemFinder'
,),
STATICFILES_DIRS
=
[
os
.
path
.
join
(
TEST_ROOT
,
'project'
,
'documents'
)])
@override_settings
(
STATICFILES_FINDERS
=
(
'django.contrib.staticfiles.finders.FileSystemFinder'
,),
STATICFILES_DIRS
=
[
os
.
path
.
join
(
TEST_ROOT
,
'project'
,
'documents'
)],
)
class
TestMiscFinder
(
TestCase
):
"""
A few misc finder tests.
...
...
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