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
4f38317d
Kaydet (Commit)
4f38317d
authored
Ara 06, 2009
tarafından
Tarek Ziadé
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fixed #1923: make sure we don't strip meaningful whitespace in PKG-INFO Description field
üst
3513c87a
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
21 additions
and
2 deletions
+21
-2
test_dist.py
Lib/distutils/tests/test_dist.py
+16
-0
util.py
Lib/distutils/util.py
+2
-2
NEWS
Misc/NEWS
+3
-0
No files found.
Lib/distutils/tests/test_dist.py
Dosyayı görüntüle @
4f38317d
...
...
@@ -6,6 +6,7 @@ import StringIO
import
sys
import
unittest
import
warnings
import
textwrap
from
distutils.dist
import
Distribution
,
fix_help_options
from
distutils.cmd
import
Command
...
...
@@ -381,6 +382,21 @@ class MetadataTestCase(support.TempdirManager, support.EnvironGuard,
if
line
.
strip
()
!=
''
]
self
.
assertTrue
(
len
(
output
)
>
0
)
def
test_long_description
(
self
):
long_desc
=
textwrap
.
dedent
(
"""
\
example::
We start here
and continue here
and end here."""
)
attrs
=
{
"name"
:
"package"
,
"version"
:
"1.0"
,
"long_description"
:
long_desc
}
dist
=
distutils
.
dist
.
Distribution
(
attrs
)
meta
=
self
.
format_metadata
(
dist
)
meta
=
meta
.
replace
(
'
\n
'
+
8
*
' '
,
'
\n
'
)
self
.
assertTrue
(
long_desc
in
meta
)
def
test_suite
():
suite
=
unittest
.
TestSuite
()
suite
.
addTest
(
unittest
.
makeSuite
(
DistributionTestCase
))
...
...
Lib/distutils/util.py
Dosyayı görüntüle @
4f38317d
...
...
@@ -558,8 +558,8 @@ def rfc822_escape(header):
"""Return a version of the string escaped for inclusion in an
RFC-822 header, by ensuring there are 8 spaces space after each newline.
"""
lines
=
[
x
.
strip
()
for
x
in
header
.
split
(
'
\n
'
)]
sep
=
'
\n
'
+
8
*
' '
lines
=
header
.
split
(
'
\n
'
)
sep
=
'
\n
'
+
8
*
' '
return
sep
.
join
(
lines
)
_RE_VERSION
=
re
.
compile
(
'(
\
d+
\
.
\
d+(
\
.
\
d+)*)'
)
...
...
Misc/NEWS
Dosyayı görüntüle @
4f38317d
...
...
@@ -507,6 +507,9 @@ Core and Builtins
Library
-------
- Issue #1923: Fixed the removal of meaningful spaces when PKG-INFO is
generated in Distutils. Patch by Stephen Emslie.
- Issue #4120: Drop reference to CRT from manifest when building extensions with
msvc9compiler.
...
...
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