diff options
author | Christian Heimes <christian@cheimes.de> | 2008-01-12 19:39:10 (GMT) |
---|---|---|
committer | Christian Heimes <christian@cheimes.de> | 2008-01-12 19:39:10 (GMT) |
commit | a62da1daafc63075c08088f45750152a4974e7b8 (patch) | |
tree | 3b70d95989fcae7e012ff32d523863d9e6eef5a5 /Doc/library/exceptions.rst | |
parent | 25bb783c030cd1c4f13297f3e2e1b6246d3f0a0c (diff) | |
download | cpython-a62da1daafc63075c08088f45750152a4974e7b8.zip cpython-a62da1daafc63075c08088f45750152a4974e7b8.tar.gz cpython-a62da1daafc63075c08088f45750152a4974e7b8.tar.bz2 |
Merged revisions 59921-59932 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk
........
r59923 | raymond.hettinger | 2008-01-11 19:04:55 +0100 (Fri, 11 Jan 2008) | 1 line
Speed-up and simplify code urlparse's result objects.
........
r59924 | andrew.kuchling | 2008-01-11 20:33:24 +0100 (Fri, 11 Jan 2008) | 1 line
Bug #1790: update link; remove outdated paragraph
........
r59925 | thomas.heller | 2008-01-11 20:34:06 +0100 (Fri, 11 Jan 2008) | 5 lines
Raise an error instead of crashing with a segfault when a NULL
function pointer is called.
Will backport to release25-maint.
........
r59927 | thomas.heller | 2008-01-11 21:29:19 +0100 (Fri, 11 Jan 2008) | 4 lines
Fix a potential 'SystemError: NULL result without error'.
NULL may be a valid return value from PyLong_AsVoidPtr.
Will backport to release25-maint.
........
r59928 | raymond.hettinger | 2008-01-12 00:25:18 +0100 (Sat, 12 Jan 2008) | 1 line
Update the opcode docs for STORE_MAP and BUILD_MAP
........
r59929 | mark.dickinson | 2008-01-12 02:56:00 +0100 (Sat, 12 Jan 2008) | 4 lines
Issue 1780: Allow leading and trailing whitespace in Decimal constructor,
when constructing from a string. Disallow trailing newlines in
Context.create_decimal.
........
r59930 | georg.brandl | 2008-01-12 11:53:29 +0100 (Sat, 12 Jan 2008) | 3 lines
Move OSError docs to exceptions doc, remove obsolete descriptions
from os docs, rework posix docs.
........
r59931 | georg.brandl | 2008-01-12 14:47:57 +0100 (Sat, 12 Jan 2008) | 3 lines
Patch #1700288: Method cache optimization, by Armin Rigo, ported to
2.6 by Kevin Jacobs.
........
r59932 | georg.brandl | 2008-01-12 17:11:09 +0100 (Sat, 12 Jan 2008) | 2 lines
Fix editing glitch.
........
Diffstat (limited to 'Doc/library/exceptions.rst')
-rw-r--r-- | Doc/library/exceptions.rst | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/Doc/library/exceptions.rst b/Doc/library/exceptions.rst index e7721fa..9c2e3a6 100644 --- a/Doc/library/exceptions.rst +++ b/Doc/library/exceptions.rst @@ -207,9 +207,19 @@ The following exceptions are the exceptions that are actually raised. .. exception:: OSError - This class is derived from :exc:`EnvironmentError` and is used primarily as the - :mod:`os` module's ``os.error`` exception. See :exc:`EnvironmentError` above for - a description of the possible associated values. + .. index:: module: errno + + This exception is derived from :exc:`EnvironmentError`. It is raised when a + function returns a system-related error (not for illegal argument types or + other incidental errors). The :attr:`errno` attribute is a numeric error + code from :cdata:`errno`, and the :attr:`strerror` attribute is the + corresponding string, as would be printed by the C function :cfunc:`perror`. + See the module :mod:`errno`, which contains names for the error codes defined + by the underlying operating system. + + For exceptions that involve a file system path (such as :func:`chdir` or + :func:`unlink`), the exception instance will contain a third attribute, + :attr:`filename`, which is the file name passed to the function. .. exception:: OverflowError |