Martijn Pieters
772d809a63
bpo-31161: only check for parens error for SyntaxError ( #3082 )
Subclasses such as IndentError and TabError should not have this message
applied.
8 years ago
Sanyam Khurana
3a7f03584a
bpo-30597: Show expected input in custom 'print' error message. ( #2009 )
9 years ago
Serhiy Storchaka
bf623ae884
bpo-30061: Check if PyObject_Size()/PySequence_Size()/PyMapping_Size() ( #1096 )
raised an error.
Replace them with using concrete types API that never fails if appropriate.
9 years ago
Serhiy Storchaka
b785396ab4
bpo-29998: Pickling and copying ImportError now preserves name and path ( #1010 )
attributes.
9 years ago
Louie Lu
c431854a09
bpo-29927: Remove duplicate BufferError init and unnecessary semicolons (GH-866)
9 years ago
Serhiy Storchaka
228b12edcc
Issue #28999 : Use Py_RETURN_NONE, Py_RETURN_TRUE and Py_RETURN_FALSE wherever
possible. Patch is writen with Coccinelle.
9 years ago
Serhiy Storchaka
f8d7d41507
Issue #28511 : Use the "U" format instead of "O!" in PyArg_Parse*.
9 years ago
Serhiy Storchaka
e9e44484a5
Issue #28289 : ImportError.__init__ now resets not specified attributes.
9 years ago
Serhiy Storchaka
47dee11ba7
Issue #21578 : Fixed misleading error message when ImportError called with
invalid keyword args.
9 years ago
Eric Snow
c943265ba5
Issue #15767 : Add ModuleNotFoundError.
9 years ago
Raymond Hettinger
7ea386e56e
Issue 19504: Change "customise" to "customize" American spelling.
9 years ago
Serhiy Storchaka
3766572a48
Issue #27692 : Removed unnecessary NULL checks in exceptions.c.
Patch by Xiang Zhang.
10 years ago
Berker Peksag
a787e5f31d
Issue #27652 : Expose ESHUTDOWN conditionally
ESHUTDOWN is also exposed conditionally in Modules/errnomodule.c.
Patch by Ed Schouten.
10 years ago
Martin Panter
eb9957065a
Issue #27626 : Spelling fixes in docs, comments and internal names
Based on patch by Ville Skyttä.
10 years ago
Martin Panter
e26da7c03a
Issue #27171 : Fix typos in documentation, comments, and test function names
10 years ago
Serhiy Storchaka
48842714b9
Issue #22570 : Renamed Py_SETREF to Py_XSETREF.
10 years ago
Serhiy Storchaka
576f132b98
Issue #20440 : Cleaning up the code by using Py_SETREF.
10 years ago
Serhiy Storchaka
191321d11b
Issue #20440 : More use of Py_SETREF.
This patch is manually crafted and contains changes that couldn't be handled
automatically.
10 years ago
Serhiy Storchaka
4a1e70fc31
Issue #20440 : Applied yet one patch for using Py_SETREF.
The patch is automatically generated, it replaces the code that uses Py_CLEAR.
10 years ago
Serhiy Storchaka
5a57ade58e
Issue #20440 : Massive replacing unsafe attribute setting code with special
macro Py_SETREF.
10 years ago
Martin Panter
7462b64911
Issue #25523 : Correct "a" article to "an" article
This changes the main documentation, doc strings, source code comments, and a
couple error messages in the test suite. In some cases the word was removed
or edited some other way to fix the grammar.
10 years ago
Yury Selivanov
f488fb422a
Issue #19235 : Add new RecursionError exception. Patch by Georg Brandl.
11 years ago
Yury Selivanov
7544508f02
PEP 0492 -- Coroutines with async and await syntax. Issue #24017 .
11 years ago
Serhiy Storchaka
4fdb68491e
Issue #22896 : Avoid to use PyObject_AsCharBuffer(), PyObject_AsReadBuffer()
and PyObject_AsWriteBuffer().
11 years ago
Victor Stinner
12174a5dca
Issue #22156 : Fix "comparison between signed and unsigned integers" compiler
warnings in the Objects/ subdirectory.
PyType_FromSpecWithBases() and PyType_FromSpec() now reject explicitly negative
slot identifiers.
12 years ago
Nick Coghlan
5b1fdc1e37
Issue #21669 : Special case print & exec syntax errors
12 years ago
Victor Stinner
69598d4ccf
Issue #21118 : Fix _PyUnicodeTranslateError_Create(), add missing format
character for the "end" parameter
12 years ago
Victor Stinner
d129eeb303
Issue #21118 : Fix _PyUnicodeTranslateError_Create(), add missing format
character for the "end" parameter
12 years ago
Benjamin Peterson
9b09ba1234
bail in unicode error's __str__ methods if the objects are not properly initialized ( closes #21134 )
12 years ago
Larry Hastings
8f9f0f12e8
Issue #20517 : Removed unnecessary new (short-lived) functions from PyErr.
12 years ago
Larry Hastings
b082731fbb
Issue #20517 : Functions in the os module that accept two filenames
now register both filenames in the exception on failure.
This required adding new C API functions allowing OSError exceptions
to reference two filenames instead of one.
12 years ago
Nick Coghlan
77b286b2cc
Close #20105 : set __traceback__ when chaining exceptions in C
12 years ago
Christian Heimes
af01f66817
Issue #16136 : Remove VMS support and VMS-related code
12 years ago
Nick Coghlan
f1de55fb33
Also chain codec exceptions that allow weakrefs
The zlib and hex codecs throw custom exception types with
weakref support if the input type is valid, but the data
fails validation. Make sure the exception chaining in the
codec infrastructure can wrap those as well.
12 years ago
Nick Coghlan
4b9b936429
Don't decref exc too soon
12 years ago
Victor Stinner
46ef31953e
Issue #19429 , #19437 : fix error handling in the OSError constructor
12 years ago
Benjamin Peterson
e109ee8205
fix refleaks
12 years ago
Benjamin Peterson
079c998872
adjust style
12 years ago
Christian Heimes
6a3db25c70
Issue #17828 : _PyObject_GetDictPtr() may return NULL instead of a PyObject**
CID 1128792: Dereference null return value (NULL_RETURNS)
12 years ago
Christian Heimes
507eabdf11
Issue #17828 : va_start() must be accompanied by va_end()
CID 1128793: Missing varargs init or cleanup (VARARGS)
12 years ago
Nick Coghlan
8b097b4ed7
Close #17828 : better handling of codec errors
- output type errors now redirect users to the type-neutral
convenience functions in the codecs module
- stateless errors that occur during encoding and decoding
will now be automatically wrapped in exceptions that give
the name of the codec involved
12 years ago
Serhiy Storchaka
c679227e31
Issue #1772673 : The type of `char*` arguments now changed to `const char*`.
12 years ago
Brett Cannon
679ecb565b
Issue #15767 : back out 8a0ed9f63c6e, finishing the removal of
ModuleNotFoundError.
13 years ago
Brett Cannon
b1611e2772
Issue #15767 : Introduce ModuleNotFoundError, a subclass of
ImportError.
The exception is raised by import when a module could not be found.
Technically this is defined as no viable loader could be found for the
specified module. This includes ``from ... import`` statements so that
the module usage is consistent for all situations where import
couldn't find what was requested.
This should allow for the common idiom of::
try:
import something
except ImportError:
pass
to be updated to using ModuleNotFoundError and not accidentally mask
ImportError messages that should propagate (e.g. issues with a
loader).
This work was driven by the fact that the ``from ... import``
statement needed to be able to tell the difference between an
ImportError that simply couldn't find a module (and thus silence the
exception so that ceval can raise it) and an ImportError that
represented an actual problem.
13 years ago
Antoine Pitrou
7faf70512a
Issue #17591 : Use lowercase filenames when including Windows header files.
Patch by Roumen Petrov.
13 years ago
Mark Dickinson
7cac1c25a1
Issue #16445 : Fix potential segmentation fault when deleting an exception message.
13 years ago
R David Murray
1cb0cb2fcd
#17296 : backport fix for issue 1692335, naive exception pickling.
13 years ago
Richard Oudkerk
ea62bd50a3
Issue #15784 : Modify OSError.__str__() to better distinguish between
errno error numbers and Windows error numbers.
14 years ago
Richard Oudkerk
30147710e8
Issue #15784 : Modify OSError.__str__() to better distinguish between
errno error numbers and Windows error numbers.
14 years ago
Brett Cannon
07c6e71689
Issue #15778 : Coerce ImportError.args to a string when it isn't
already one.
Patch by Dave Malcolm.
14 years ago