Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
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
cpython
Commits
def6ee59
Kaydet (Commit)
def6ee59
authored
Kas 29, 2012
tarafından
Ezio Melotti
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
#16476: Fix json.tool to avoid including trailing whitespace.
üst
d8feba90
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
9 deletions
+12
-9
test_tool.py
Lib/json/tests/test_tool.py
+8
-8
tool.py
Lib/json/tool.py
+2
-1
NEWS
Misc/NEWS
+2
-0
No files found.
Lib/json/tests/test_tool.py
Dosyayı görüntüle @
def6ee59
...
@@ -19,19 +19,19 @@ class TestTool(unittest.TestCase):
...
@@ -19,19 +19,19 @@ class TestTool(unittest.TestCase):
[
[
[
[
"blorpie"
"blorpie"
],
],
[
[
"whoops"
"whoops"
],
],
[],
[],
"d-shtaeou",
"d-shtaeou",
"d-nthiouh",
"d-nthiouh",
"i-vhbjkhnth",
"i-vhbjkhnth",
{
{
"nifty": 87
"nifty": 87
},
},
{
{
"field": "yes",
"field": "yes",
"morefield": false
"morefield": false
}
}
]
]
...
...
Lib/json/tool.py
Dosyayı görüntüle @
def6ee59
...
@@ -31,7 +31,8 @@ def main():
...
@@ -31,7 +31,8 @@ def main():
except
ValueError
,
e
:
except
ValueError
,
e
:
raise
SystemExit
(
e
)
raise
SystemExit
(
e
)
with
outfile
:
with
outfile
:
json
.
dump
(
obj
,
outfile
,
sort_keys
=
True
,
indent
=
4
)
json
.
dump
(
obj
,
outfile
,
sort_keys
=
True
,
indent
=
4
,
separators
=
(
','
,
': '
))
outfile
.
write
(
'
\n
'
)
outfile
.
write
(
'
\n
'
)
...
...
Misc/NEWS
Dosyayı görüntüle @
def6ee59
...
@@ -154,6 +154,8 @@ Core and Builtins
...
@@ -154,6 +154,8 @@ Core and Builtins
Library
Library
-------
-------
-
Issue
#
16476
:
Fix
json
.
tool
to
avoid
including
trailing
whitespace
.
-
Issue
#
1160
:
Fix
compiling
large
regular
expressions
on
UCS2
builds
.
-
Issue
#
1160
:
Fix
compiling
large
regular
expressions
on
UCS2
builds
.
Patch
by
Serhiy
Storchaka
.
Patch
by
Serhiy
Storchaka
.
...
...
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