mirror of
https://github.com/python/cpython.git
synced 2024-11-28 04:15:11 +08:00
#5287: Add exception handling around findCaller() call to help out IronPython.
This commit is contained in:
parent
2d0c2568d5
commit
b672b6dea6
@ -1,4 +1,4 @@
|
||||
# Copyright 2001-2008 by Vinay Sajip. All Rights Reserved.
|
||||
# Copyright 2001-2009 by Vinay Sajip. All Rights Reserved.
|
||||
#
|
||||
# Permission to use, copy, modify, and distribute this software and its
|
||||
# documentation for any purpose and without fee is hereby granted,
|
||||
@ -1127,7 +1127,12 @@ class Logger(Filterer):
|
||||
all the handlers of this logger to handle the record.
|
||||
"""
|
||||
if _srcfile:
|
||||
fn, lno, func = self.findCaller()
|
||||
#IronPython doesn't track Python frames, so findCaller throws an
|
||||
#exception. We trap it here so that IronPython can use logging.
|
||||
try:
|
||||
fn, lno, func = self.findCaller()
|
||||
except ValueError:
|
||||
fn, lno, func = "(unknown file)", 0, "(unknown function)"
|
||||
else:
|
||||
fn, lno, func = "(unknown file)", 0, "(unknown function)"
|
||||
if exc_info:
|
||||
|
13
Misc/NEWS
13
Misc/NEWS
@ -169,15 +169,18 @@ Core and Builtins
|
||||
Library
|
||||
-------
|
||||
|
||||
- Issue #5287: Add exception handling around findCaller() call to help out
|
||||
IronPython.
|
||||
|
||||
- Issue #5282: Fixed mmap resize on 32bit windows and unix. When offset > 0,
|
||||
The file was resized to wrong size.
|
||||
|
||||
- Issue #5292: Fixed mmap crash on its boundary access m[len(m)].
|
||||
|
||||
- Issue #2279: distutils.sdist.add_defaults now add files
|
||||
- Issue #2279: distutils.sdist.add_defaults now add files
|
||||
from the package_data and the data_files metadata.
|
||||
|
||||
- Issue #5257: refactored all tests in distutils, so they use
|
||||
- Issue #5257: refactored all tests in distutils, so they use
|
||||
support.TempdirManager, to avoid writing in the tests directory.
|
||||
|
||||
- Issue #4524: distutils build_script command failed with --with-suffix=3.
|
||||
@ -227,13 +230,13 @@ Library
|
||||
- Issue #4285: Change sys.version_info to be a named tuple. Patch by
|
||||
Ross Light.
|
||||
|
||||
- Issue #1520877: Now distutils.sysconfig reads $AR from the
|
||||
- Issue #1520877: Now distutils.sysconfig reads $AR from the
|
||||
environment/Makefile. Patch by Douglas Greiman.
|
||||
|
||||
- Issue #1276768: The verbose option was not used in the code of
|
||||
distutils.file_util and distutils.dir_util.
|
||||
|
||||
- Issue #5132: Fixed trouble building extensions under Solaris with
|
||||
- Issue #5132: Fixed trouble building extensions under Solaris with
|
||||
--enabled-shared activated. Initial patch by Dave Peterson.
|
||||
|
||||
- Issue #1581476: Always use the Tcl global namespace when calling into Tcl.
|
||||
@ -283,7 +286,7 @@ Library
|
||||
- Issue #4710: Extract directories properly in the zipfile module;
|
||||
allow adding directories to a zipfile.
|
||||
|
||||
- Issue #3807: _multiprocessing build fails when configure is passed
|
||||
- Issue #3807: _multiprocessing build fails when configure is passed
|
||||
--without-threads argument. When this occurs, _multiprocessing will
|
||||
be disabled, and not compiled.
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user