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
e989bf58
Kaydet (Commit)
e989bf58
authored
Eyl 05, 2015
tarafından
Terry Jan Reedy
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Sade Fark
merge from 3.4
üst
37fdcbc4
ca3f435f
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
0 deletions
+18
-0
pdb.py
Lib/pdb.py
+3
-0
test_pdb.py
Lib/test/test_pdb.py
+12
-0
NEWS
Misc/NEWS
+3
-0
No files found.
Lib/pdb.py
Dosyayı görüntüle @
e989bf58
...
@@ -1669,6 +1669,9 @@ def main():
...
@@ -1669,6 +1669,9 @@ def main():
# In most cases SystemExit does not warrant a post-mortem session.
# In most cases SystemExit does not warrant a post-mortem session.
print
(
"The program exited via sys.exit(). Exit status:"
,
end
=
' '
)
print
(
"The program exited via sys.exit(). Exit status:"
,
end
=
' '
)
print
(
sys
.
exc_info
()[
1
])
print
(
sys
.
exc_info
()[
1
])
except
SyntaxError
:
traceback
.
print_exc
()
sys
.
exit
(
1
)
except
:
except
:
traceback
.
print_exc
()
traceback
.
print_exc
()
print
(
"Uncaught exception. Entering post mortem debugging"
)
print
(
"Uncaught exception. Entering post mortem debugging"
)
...
...
Lib/test/test_pdb.py
Dosyayı görüntüle @
e989bf58
...
@@ -1043,6 +1043,18 @@ class PdbTestCase(unittest.TestCase):
...
@@ -1043,6 +1043,18 @@ class PdbTestCase(unittest.TestCase):
self
.
assertNotIn
(
'Error'
,
stdout
.
decode
(),
self
.
assertNotIn
(
'Error'
,
stdout
.
decode
(),
"Got an error running test script under PDB"
)
"Got an error running test script under PDB"
)
def
test_issue16180
(
self
):
# A syntax error in the debuggee.
script
=
"def f: pass
\n
"
commands
=
''
expected
=
"SyntaxError:"
stdout
,
stderr
=
self
.
run_pdb
(
script
,
commands
)
self
.
assertIn
(
expected
,
stdout
,
'
\n\n
Expected:
\n
{}
\n
Got:
\n
{}
\n
'
'Fail to handle a syntax error in the debuggee.'
.
format
(
expected
,
stdout
))
def
tearDown
(
self
):
def
tearDown
(
self
):
support
.
unlink
(
support
.
TESTFN
)
support
.
unlink
(
support
.
TESTFN
)
...
...
Misc/NEWS
Dosyayı görüntüle @
e989bf58
...
@@ -14,6 +14,9 @@ Core and Builtins
...
@@ -14,6 +14,9 @@ Core and Builtins
Library
Library
-------
-------
- Issue #16180: Exit pdb if file has syntax error, instead of trapping user
in an infinite loop. Patch by Xavier de Gaye.
- Issue #24891: Fix a race condition at Python startup if the file descriptor
- Issue #24891: Fix a race condition at Python startup if the file descriptor
of stdin (0), stdout (1) or stderr (2) is closed while Python is creating
of stdin (0), stdout (1) or stderr (2) is closed while Python is creating
sys.stdin, sys.stdout and sys.stderr objects. These attributes are now set
sys.stdin, sys.stdout and sys.stderr objects. These attributes are now set
...
...
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